Fix possible sync loss bug.

git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@3491 8092fc87-c524-0410-9efc-e669fe64eaf9
This commit is contained in:
Meep-Eep
2009-12-29 20:18:34 +00:00
parent 3fd65530d7
commit 3e079bc324
+7 -1
View File
@@ -504,6 +504,8 @@ pkunk_preprocess (ELEMENT *ElementPtr)
}
}
static COUNT LastSound = 0;
static void
pkunk_postprocess (ELEMENT *ElementPtr)
{
@@ -517,7 +519,6 @@ pkunk_postprocess (ELEMENT *ElementPtr)
StarShipPtr->RaceDescPtr->ship_info.max_energy)
{
COUNT CurSound;
static COUNT LastSound = 0;
do
{
@@ -548,6 +549,11 @@ init_pkunk (void)
RaceDescPtr = &pkunk_desc;
LastSound = 0;
// We need to reinitialise it at least each battle, to ensure
// that NetPlay is synchronised if one player played another
// game before playing against a networked opponent.
return (RaceDescPtr);
}