// serialize the object into BUFFER (which is BUFSIZE bytes) // return number of bytes used int CCGUIObject::Serialize(const char *address, char *buffer, int bufsize) { GUIObject *guio = (GUIObject*)address; StartSerialize(buffer); SerializeInt(guio->guin); SerializeInt(guio->objn); return EndSerialize(); }
int ScriptOverlay::Serialize(const char *address, char *buffer, int bufsize) { StartSerialize(buffer); SerializeInt(overlayId); SerializeInt(borderWidth); SerializeInt(borderHeight); SerializeInt(isBackgroundSpeech); return EndSerialize(); }
int ScriptDateTime::Serialize(const char *address, char *buffer, int bufsize) { StartSerialize(buffer); SerializeInt(year); SerializeInt(month); SerializeInt(day); SerializeInt(hour); SerializeInt(minute); SerializeInt(second); SerializeInt(rawUnixTime); return EndSerialize(); }
int ScriptDrawingSurface::Serialize(const char *address, char *buffer, int bufsize) { StartSerialize(buffer); SerializeInt(roomBackgroundNumber); SerializeInt(dynamicSpriteNumber); SerializeInt(dynamicSurfaceNumber); SerializeInt(currentColour); SerializeInt(currentColourScript); SerializeInt(highResCoordinates); SerializeInt(modified); SerializeInt(hasAlphaChannel); SerializeInt(isLinkedBitmapOnly ? 1 : 0); return EndSerialize(); }
// serialize the object into BUFFER (which is BUFSIZE bytes) // return number of bytes used int CCCharacter::Serialize(const char *address, char *buffer, int bufsize) { CharacterInfo *chaa = (CharacterInfo*)address; StartSerialize(buffer); SerializeInt(chaa->index_id); return EndSerialize(); }
// serialize the object into BUFFER (which is BUFSIZE bytes) // return number of bytes used int CCHotspot::Serialize(const char *address, char *buffer, int bufsize) { ScriptHotspot *shh = (ScriptHotspot*)address; StartSerialize(buffer); SerializeInt(shh->id); return EndSerialize(); }
int CCAudioChannel::Serialize(const char *address, char *buffer, int bufsize) { ScriptAudioChannel *ach = (ScriptAudioChannel*)address; StartSerialize(buffer); SerializeInt(ach->id); return EndSerialize(); }
// serialize the object into BUFFER (which is BUFSIZE bytes) // return number of bytes used int CCRegion::Serialize(const char *address, char *buffer, int bufsize) { ScriptRegion *shh = (ScriptRegion*)address; StartSerialize(buffer); SerializeInt(shh->id); return EndSerialize(); }