1
0
forked from mirrors/0ad

# Basic experimental multiplayer integration with new simulation system.

Add new turn manager that should be more correct and potentially more
efficient.
Remove evil CNetServer/CNetClient multiple inheritance of CTurnManager.
Add multiplayer autostart.
Various minor cleanups.

This was SVN commit r7551.
This commit is contained in:
Ykkrosh
2010-05-20 00:59:01 +00:00
parent 8c1a3f7c8a
commit c684c211a2
41 changed files with 1330 additions and 463 deletions
+1 -8
View File
@@ -103,16 +103,9 @@ void PostNetworkCommand(void* cbdata, CScriptVal cmd)
if (queue.null())
return;
int player = -1;
if (g_Game && g_Game->GetLocalPlayer())
player = g_Game->GetLocalPlayer()->GetPlayerID();
jsval cmd2 = sim->GetScriptInterface().CloneValueFromOtherContext(guiManager->GetScriptInterface(), cmd.get());
queue->PushClientCommand(player, cmd2);
// TODO: This shouldn't call Push, it should send the message to the network layer
// (which should propagate it across the network and eventually call Push on the
// appropriate turn)
queue->PostNetworkCommand(cmd2);
}
std::vector<entity_id_t> PickEntitiesAtPoint(void* UNUSED(cbdata), int x, int y)