mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-29 21:24:53 +00:00
AVALANCHE: Fix variable initialization in Nim
This commit is contained in:
parent
408f1b3aa3
commit
ee34fcef43
@ -35,11 +35,27 @@ const char * const Nim::kNames[2] = {"Avalot", "Dogfood"};
|
||||
Nim::Nim(AvalancheEngine *vm) {
|
||||
_vm = vm;
|
||||
|
||||
_playedNim = 0;
|
||||
resetVariables();
|
||||
}
|
||||
|
||||
void Nim::resetVariables() {
|
||||
_playedNim = 0;
|
||||
_turns = 0;
|
||||
_dogfoodsTurn = false;
|
||||
_stonesLeft = 0;
|
||||
_clicked = false;
|
||||
_row = 0;
|
||||
_number = 0;
|
||||
_squeak = false;
|
||||
_mNum = 0;
|
||||
_mRow = 0;
|
||||
|
||||
for (int i = 0; i < 3; i++) {
|
||||
_old[i] = 0;
|
||||
_stones[i] = 0;
|
||||
}
|
||||
|
||||
memset(_stonePic, 0, 4 * 23 * 7);
|
||||
}
|
||||
|
||||
void Nim::synchronize(Common::Serializer &sz) {
|
||||
|
Loading…
Reference in New Issue
Block a user