fix zapper movie savestate bugs

This commit is contained in:
zeromus 2008-06-28 20:20:40 +00:00
parent 832f346fc8
commit d6d2cea7cd
2 changed files with 3 additions and 3 deletions

View File

@ -213,7 +213,7 @@ bool MovieRecord::parseBinary(MovieData* md, std::istream* is)
zappers[port].y = (uint8)is->get(); zappers[port].y = (uint8)is->get();
zappers[port].b = (uint8)is->get(); zappers[port].b = (uint8)is->get();
zappers[port].bogo = (uint8)is->get(); zappers[port].bogo = (uint8)is->get();
zappers[port].zaphit = uint64DecFromIstream(is); read64le(&zappers[port].zaphit,is);
} }
} }
} }
@ -431,7 +431,7 @@ static void LoadFM2_binarychunk(MovieData& movieData, std::istream* fp, int size
switch(movieData.ports[i]) switch(movieData.ports[i])
{ {
case SI_GAMEPAD: recordsize++; break; case SI_GAMEPAD: recordsize++; break;
case SI_ZAPPER: recordsize+=10; break; case SI_ZAPPER: recordsize+=12; break;
} }
} }
} }

View File

@ -90,7 +90,7 @@ int write64le(uint64 b, std::ostream* os)
s[6]=b>>48; s[6]=b>>48;
s[7]=b>>56; s[7]=b>>56;
os->write((char*)&s,8); os->write((char*)&s,8);
return 4; return 8;
} }