#4095 closed enhancement (fixed)
[PATCH] Rename CNetTurnManager to CTurnManager
Reported by: | elexis | Owned by: | echotangoecho |
---|---|---|---|
Priority: | Nice to Have | Milestone: | Alpha 22 |
Component: | Core engine | Keywords: | patch |
Cc: | Patch: |
Description
The class CNetTurnManager
is inherited for classes that simulate without being networked, for example CNetReplayTurnManager
and CNetLocalTurnManager
.
/** * Implementation of CNetTurnManager for offline games. */ class CNetLocalTurnManager : public CNetTurnManager
The name of the class suggests that networking code is involved, while it isn't necessarily.
The comment at the top of the file will have to be updated a bit, perhaps moved (but not degraded).
Attachments (10)
Change History (20)
comment:1 by , 8 years ago
Component: | UI & Simulation → Core engine |
---|
by , 8 years ago
Attachment: | rename_CNetTurnManager.patch added |
---|
comment:2 by , 8 years ago
Keywords: | rfc patch added |
---|---|
Milestone: | Backlog → Alpha 21 |
Summary: | Rename CNetTurnManager to CTurnManager → [PATCH] Rename CNetTurnManager to CTurnManager |
comment:3 by , 8 years ago
The filepath source/network/CNetTurnManager.*
seems questionable too.
Should the classes be split across several files?
Should the networked turnmanager be moved to NetClient.cpp
and NetServer.cpp
or moved to individual files inside network/
, while moving the offline and parent class to source/ps
, source/simulation2
? (Or would it better to keep it all in one file? (likely not))
comment:4 by , 8 years ago
Owner: | set to |
---|---|
Status: | new → assigned |
by , 8 years ago
Attachment: | rename.patch added |
---|
Split the turnmanagers across files as suggested by elexis, remove the virtual functions OnSyncError and DisplayOOSError from the CTurnManager.
by , 8 years ago
Attachment: | movehexify.patch added |
---|
Moves the function Hexify which occurs in multiple source files to ps/Util.h and removes the useless extern keyword from function declarations in that file.
by , 8 years ago
Attachment: | movehexify2.patch added |
---|
Change the previous patch to make the Hexify function use a range-based for loop.
by , 8 years ago
Attachment: | movehexify3.patch added |
---|
change for (char c : s) to for (const char& c : s).
comment:6 by , 8 years ago
Keywords: | simple removed |
---|
WIP for some big rewrite https://github.com/echotangoecho/0ad/tree/turnmanager
by , 7 years ago
Attachment: | split.patch added |
---|
by , 7 years ago
Attachment: | split.3.patch added |
---|
by , 7 years ago
Attachment: | split.4.patch added |
---|
comment:10 by , 7 years ago
Keywords: | rfc removed |
---|---|
Milestone: | Work In Progress → Alpha 22 |
Thanks for the branch, going through the revisions and updating the CPPSupport wiki page!
Not exactly sure how to reword the comment.