mirror of
https://github.com/GTAmodding/re3.git
synced 2025-07-14 03:54:10 +00:00
changed saving compatibility
This commit is contained in:
parent
5a916c16b7
commit
f372ce156d
18 changed files with 567 additions and 612 deletions
|
@ -51,6 +51,13 @@ RwObject *GetCurrentAtomicObjectCB(RwObject *object, void *data);
|
|||
|
||||
bool CAutomobile::m_sAllTaxiLights;
|
||||
|
||||
const uint32 CAutomobile::nSaveStructSize =
|
||||
#ifdef COMPATIBLE_SAVES
|
||||
1448;
|
||||
#else
|
||||
sizeof(CAutomobile);
|
||||
#endif
|
||||
|
||||
CAutomobile::CAutomobile(int32 id, uint8 CreatedBy)
|
||||
: CVehicle(CreatedBy)
|
||||
{
|
||||
|
@ -4580,3 +4587,22 @@ CAutomobile::SetAllTaxiLights(bool set)
|
|||
{
|
||||
m_sAllTaxiLights = set;
|
||||
}
|
||||
|
||||
#ifdef COMPATIBLE_SAVES
|
||||
void
|
||||
CAutomobile::Save(uint8*& buf)
|
||||
{
|
||||
CVehicle::Save(buf);
|
||||
WriteSaveBuf<CDamageManager>(buf, Damage);
|
||||
SkipSaveBuf(buf, 800 - sizeof(CDamageManager));
|
||||
}
|
||||
|
||||
void
|
||||
CAutomobile::Load(uint8*& buf)
|
||||
{
|
||||
CVehicle::Load(buf);
|
||||
Damage = ReadSaveBuf<CDamageManager>(buf);
|
||||
SkipSaveBuf(buf, 800 - sizeof(CDamageManager));
|
||||
SetupDamageAfterLoad();
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue