DDWORD ParticleSystem::EngineMessageFn(DDWORD messageID, void *pData, DFLOAT fData) { switch(messageID) { case MID_PRECREATE: { if (fData == 1.0f || fData == 2.0f) { ReadProp((ObjectCreateStruct *)pData); } break; } case MID_INITIALUPDATE: { InitialUpdate((DVector *)pData); break; } case MID_UPDATE: { CServerDE* pServerDE = GetServerDE(); if (pServerDE) { pServerDE->RemoveObject(m_hObject); } break; } default : break; } return CClientSFX::EngineMessageFn(messageID, pData, fData); }
DDWORD MadScientistAI::EngineMessageFn(DDWORD messageID, void *pData, DFLOAT fData) { switch(messageID) { case MID_PRECREATE: { // Need to call base class to have the object name read in before // we call PostPropRead() DDWORD dwRet = AI_Mgr::EngineMessageFn(messageID, pData, fData); if(fData != PRECREATE_SAVEGAME) PostPropRead((ObjectCreateStruct*)pData); return dwRet; } break; case MID_INITIALUPDATE: { InitialUpdate((DVector *)pData); CacheFiles(); break; } default : break; } return AI_Mgr::EngineMessageFn(messageID, pData, fData); }
DDWORD B2BaseClass::EngineMessageFn(DDWORD messageID, void *pData, DFLOAT fData) { if (!g_pServerDE) return 0; // Set object type... switch (messageID) { case MID_PRECREATE: { if (fData == PRECREATE_WORLDFILE || fData == PRECREATE_STRINGPROP) ReadProp((ObjectCreateStruct*)pData); } break; case MID_INITIALUPDATE: { if (fData == INITIALUPDATE_WORLDFILE) { DBOOL bResult = InitialUpdate(); if (!bResult) g_pServerDE->RemoveObject(m_hObject); } } break; } return BaseClass::EngineMessageFn(messageID, pData, fData); }
uint32 ScatterVolume::EngineMessageFn( uint32 messageID, void* pData, LTFLOAT fData ) { switch( messageID ) { case MID_PRECREATE: { ObjectCreateStruct* pOCS = (ObjectCreateStruct*)pData; if( !pOCS ) break; if( fData == PRECREATE_WORLDFILE ) { ReadProp( pOCS ); // make sure this object is always in the visible object list pOCS->m_Flags |= FLAG_FORCECLIENTUPDATE; } } break; case MID_INITIALUPDATE: InitialUpdate(); break; } return VolumeEffect::EngineMessageFn( messageID, pData, fData ); }
uint32 PlayerTrigger::EngineMessageFn( uint32 messageID, void *pData, LTFLOAT fData ) { switch(messageID) { case MID_PRECREATE: { ObjectCreateStruct *pStruct = (ObjectCreateStruct *)pData; if (!pStruct) return 0; if (fData == PRECREATE_WORLDFILE) { ReadProps(pStruct); } } break; case MID_INITIALUPDATE: { if( fData != INITIALUPDATE_SAVEGAME ) { InitialUpdate(); } } break; default : break; } return Trigger::EngineMessageFn( messageID, pData, fData ); }
uint32 Key::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_PRECREATE: { if (fData == PRECREATE_WORLDFILE) { ReadProp((ObjectCreateStruct*)pData); } break; } case MID_INITIALUPDATE: { InitialUpdate((LTVector *)pData); break; } default : break; } return BaseClass::EngineMessageFn(messageID, pData, fData); }
uint32 VolumeBrush::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { uint32 dwRet; switch(messageID) { case MID_UPDATE: { Update(); break; } case MID_AFFECTPHYSICS: { UpdatePhysics((ContainerPhysics*)pData); break; } case MID_PRECREATE: { dwRet = GameBase::EngineMessageFn(messageID, pData, fData); if (fData == PRECREATE_WORLDFILE) { ReadProp((ObjectCreateStruct*)pData); } PostPropRead((ObjectCreateStruct*)pData); return dwRet; break; } case MID_INITIALUPDATE: { if (fData != INITIALUPDATE_SAVEGAME) { InitialUpdate(); } CacheFiles(); break; } case MID_SAVEOBJECT: { Save((HMESSAGEWRITE)pData, (uint32)fData); } break; case MID_LOADOBJECT: { Load((HMESSAGEREAD)pData, (uint32)fData); } break; default : break; } return GameBase::EngineMessageFn(messageID, pData, fData); }
uint32 WeaponItem::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_UPDATE: { uint32 dwRet = PickupItem::EngineMessageFn(messageID, pData, fData); g_pLTServer->SetNextUpdate(m_hObject, 0.0f); return dwRet; } break; case MID_PRECREATE: { uint32 dwRet = PickupItem::EngineMessageFn(messageID, pData, fData); if (fData == PRECREATE_WORLDFILE || fData == PRECREATE_STRINGPROP) { ReadProp((ObjectCreateStruct*)pData); } if (fData != PRECREATE_SAVEGAME) { PostPropRead((ObjectCreateStruct*)pData); } return dwRet; } break; case MID_INITIALUPDATE: { uint32 dwRet = PickupItem::EngineMessageFn(messageID, pData, fData); if (fData != INITIALUPDATE_SAVEGAME) { InitialUpdate(); } return dwRet; } case MID_SAVEOBJECT: { Save((HMESSAGEWRITE)pData, (uint32)fData); } break; case MID_LOADOBJECT: { Load((HMESSAGEREAD)pData, (uint32)fData); } break; default : break; } return PickupItem::EngineMessageFn(messageID, pData, fData); }
uint32 LightGroup::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_PRECREATE: { ObjectCreateStruct *pOCS = (ObjectCreateStruct*)pData; if (!pOCS) break; if( fData == PRECREATE_WORLDFILE ) { ReadProp(pOCS); } PostReadProp(pOCS); } break; case MID_INITIALUPDATE: { if( fData != INITIALUPDATE_SAVEGAME ) { InitialUpdate(); } } break; case MID_SAVEOBJECT: { Save((ILTMessage_Write*)pData, (uint32)fData); } break; case MID_LOADOBJECT: { Load((ILTMessage_Read*)pData, (uint32)fData); } break; case MID_UPDATE: { // Send a new update if we were waiting for the client to do something if (m_bClientNeedsUpdate) { UpdateClients(); // Turn back off SetNextUpdate(m_hObject, UPDATE_NEVER); } } break; default : break; } return Engine_LightGroup::EngineMessageFn(messageID, pData, fData); }
DDWORD ClientLightFX::EngineMessageFn(DDWORD messageID, void *pData, DFLOAT fData) { switch(messageID) { case MID_PRECREATE: { DDWORD dwRet = B2BaseClass::EngineMessageFn(messageID, pData, fData); if (fData == PRECREATE_WORLDFILE || fData == PRECREATE_STRINGPROP) { m_bDynamic = DFALSE; ReadProp((ObjectCreateStruct*)pData); } PostPropRead((ObjectCreateStruct*)pData); return dwRet; } break; case MID_INITIALUPDATE: { if (fData != INITIALUPDATE_SAVEGAME) { InitialUpdate((DVector *)pData); } CacheFiles(); break; } case MID_UPDATE: { if (!Update()) { CServerDE* pServerDE = BaseClass::GetServerDE(); if (pServerDE) pServerDE->RemoveObject(m_hObject); } } break; case MID_SAVEOBJECT: { Save((HMESSAGEWRITE)pData, (DDWORD)fData); } break; case MID_LOADOBJECT: { Load((HMESSAGEREAD)pData, (DDWORD)fData); } break; default : break; } return B2BaseClass::EngineMessageFn(messageID, pData, fData); }
uint32 DoomsDayDevice::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_PRECREATE: { uint32 dwRet = PropType::EngineMessageFn(messageID, pData, fData); if (fData == PRECREATE_WORLDFILE || fData == PRECREATE_STRINGPROP) { if( !ReadProp(( ObjectCreateStruct* )pData )) return 0; // Always start out with the base proptype. m_sPropType = "Doomsday_base"; } return dwRet; } break; case MID_INITIALUPDATE: { uint32 dwRet = PropType::EngineMessageFn(messageID, pData, fData); if (fData != INITIALUPDATE_SAVEGAME) { InitialUpdate(); } return dwRet; } break; case MID_UPDATE: { Update(); } break; case MID_SAVEOBJECT: { Save((ILTMessage_Write*)pData, (uint32)fData); } break; case MID_LOADOBJECT: { Load((ILTMessage_Read*)pData, (uint32)fData); } break; default : break; } return PropType::EngineMessageFn(messageID, pData, fData); }
uint32 SoundFX::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_PRECREATE: { uint32 dwRet = BaseClass::EngineMessageFn(messageID, pData, fData); if (fData == PRECREATE_WORLDFILE || fData == PRECREATE_STRINGPROP) { ReadProp((ObjectCreateStruct*)pData); } PostPropRead((ObjectCreateStruct*)pData); return dwRet; } break; case MID_INITIALUPDATE: { if (fData != INITIALUPDATE_SAVEGAME) { InitialUpdate(); } CacheFiles(); } break; case MID_UPDATE: { if (m_hsndSound) { g_pLTServer->KillSound(m_hsndSound); m_hsndSound = NULL; } } break; case MID_SAVEOBJECT: { Save((HMESSAGEWRITE)pData, (uint32)fData); } break; case MID_LOADOBJECT: { Load((HMESSAGEREAD)pData, (uint32)fData); } break; default : break; } return BaseClass::EngineMessageFn(messageID, pData, fData); }
uint32 SecurityCamera::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_UPDATE: { Update(); } break; case MID_PRECREATE: { uint32 dwRet = CScanner::EngineMessageFn(messageID, pData, fData); if (fData == PRECREATE_WORLDFILE || fData == PRECREATE_STRINGPROP) { ReadProp((ObjectCreateStruct*)pData); } PostPropRead((ObjectCreateStruct*)pData); return dwRet; } break; case MID_INITIALUPDATE: { uint32 dwRet = CScanner::EngineMessageFn(messageID, pData, fData); if (fData != INITIALUPDATE_SAVEGAME) { InitialUpdate(); } CacheFiles(); return dwRet; } break; case MID_SAVEOBJECT: { Save((HMESSAGEWRITE)pData); } break; case MID_LOADOBJECT: { Load((HMESSAGEREAD)pData); } break; default : break; } return CScanner::EngineMessageFn(messageID, pData, fData); }
uint32 GunMount::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_PRECREATE: { uint32 dwRet = GameBase::EngineMessageFn(messageID, pData, fData); if (fData == PRECREATE_WORLDFILE || fData == PRECREATE_STRINGPROP) { if( !ReadProp(&(( ObjectCreateStruct* )pData )->m_cProperties )) return 0; } return dwRet; } break; case MID_INITIALUPDATE: { uint32 dwRet = GameBase::EngineMessageFn(messageID, pData, fData); if (fData != INITIALUPDATE_SAVEGAME) { InitialUpdate(); } return dwRet; } break; case MID_SAVEOBJECT: { Save((ILTMessage_Write*)pData, (uint32)fData); } break; case MID_LOADOBJECT: { Load((ILTMessage_Read*)pData, (uint32)fData); } break; case MID_UPDATE: { Update( ); } break; default : break; } return GameBase::EngineMessageFn(messageID, pData, fData); }
uint32 DisplayTimer::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_UPDATE: { Update(); } break; case MID_PRECREATE: { if (fData == PRECREATE_WORLDFILE || fData == PRECREATE_STRINGPROP) { ReadProp((ObjectCreateStruct*)pData); } } break; case MID_INITIALUPDATE: { if (fData != INITIALUPDATE_SAVEGAME) { InitialUpdate(); } } break; case MID_SAVEOBJECT: { Save((ILTMessage_Write*)pData); } break; case MID_LOADOBJECT: { Load((ILTMessage_Read*)pData); uint32 dwRet = BaseClass::EngineMessageFn(messageID, pData, fData); // We need to reset our sfx message since values // could have changed across save versions. UpdateClients( ); return dwRet; } break; default : break; } return BaseClass::EngineMessageFn(messageID, pData, fData); }
uint32 ClientLightFX::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_PRECREATE: { uint32 dwRet = GameBase::EngineMessageFn(messageID, pData, fData); if (fData == PRECREATE_WORLDFILE || fData == PRECREATE_STRINGPROP) { m_bDynamic = LTFALSE; ReadProp((ObjectCreateStruct*)pData); PostPropRead((ObjectCreateStruct*)pData); } return dwRet; } break; case MID_INITIALUPDATE: { if (fData != INITIALUPDATE_SAVEGAME) { InitialUpdate((LTVector *)pData); } CacheFiles(); break; } case MID_UPDATE: { if (!Update()) { g_pLTServer->RemoveObject(m_hObject); } } break; case MID_SAVEOBJECT: { Save((HMESSAGEWRITE)pData, (uint32)fData); } break; case MID_LOADOBJECT: { Load((HMESSAGEREAD)pData, (uint32)fData); } break; default : break; } return GameBase::EngineMessageFn(messageID, pData, fData); }
uint32 PlayerVehicle::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_UPDATE: { Update(); } break; case MID_PRECREATE: { uint32 dwRet = Prop::EngineMessageFn(messageID, pData, fData); if (fData == PRECREATE_WORLDFILE || fData == PRECREATE_STRINGPROP) { ReadProp((ObjectCreateStruct*)pData); PostPropRead((ObjectCreateStruct*)pData); } return dwRet; } break; case MID_INITIALUPDATE: { uint32 dwRet = Prop::EngineMessageFn(messageID, pData, fData); if (fData != INITIALUPDATE_SAVEGAME) { InitialUpdate(); } return dwRet; } break; case MID_SAVEOBJECT: { Save((ILTMessage_Write*)pData); } break; case MID_LOADOBJECT: { Load((ILTMessage_Read*)pData); } break; default : break; } return Prop::EngineMessageFn(messageID, pData, fData); }
// ----------------------------------------------------------------------- // // // ROUTINE: SkeletonObject::EngineMessageFn // // PURPOSE: Handle engine messages // // ----------------------------------------------------------------------- // uint32 SkeletonObject::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_PRECREATE: { // First we call down to the base class. // This isn't currently done in all objects, but // it really is good practice to do it this way. LTRESULT ret = GameBase::EngineMessageFn(messageID, pData, fData); if((fData == PRECREATE_WORLDFILE) || (fData == PRECREATE_STRINGPROP)) { ReadProp((ObjectCreateStruct*)pData); } // Passing this message to the base class first insures that all the props // will be read in when we get here PostPropRead((ObjectCreateStruct*)pData); return ret; } case MID_INITIALUPDATE: { // Initial update InitialUpdate(); break; } case MID_UPDATE: { // Main update function Update(); break; } case MID_SAVEOBJECT: { Save((ILTMessage_Write*)pData, (uint32)fData); break; } case MID_LOADOBJECT: { Load((ILTMessage_Read*)pData, (uint32)fData); break; } default: break; } return(GameBase::EngineMessageFn(messageID, pData, fData)); }
uint32 AINavMeshLinkAbstract::EngineMessageFn(uint32 messageID, void *pv, float fData) { switch(messageID) { case MID_PRECREATE: { uint32 dwRet = BaseClass::EngineMessageFn(messageID, pv, fData); if ( (int)fData == PRECREATE_WORLDFILE || (int)fData == PRECREATE_STRINGPROP ) { ObjectCreateStruct* pocs = (ObjectCreateStruct*)pv; ReadProp(&pocs->m_cProperties); // Ensure the object will never be sent to the client. pocs->m_Flags = FLAG_NOTINWORLDTREE; } return dwRet; } break; case MID_SAVEOBJECT: { Save((ILTMessage_Write*)pv); } break; case MID_LOADOBJECT: { Load((ILTMessage_Read*)pv); } break; case MID_INITIALUPDATE: { if( g_pAINavMesh ) { g_pAINavMesh->AddAINavMeshLink( this ); } SetNextUpdate( UPDATE_NEVER ); } break; case MID_ALLOBJECTSCREATED: { InitialUpdate(); } break; } return BaseClass::EngineMessageFn(messageID, pv, fData); }
void CWndControl::Create(int ID, const QRect& rect, int flags, CWndControl* parent) { m_ID = ID; m_flags |= flags; m_parent = parent; m_enabled = true; m_mustFocus = this; SetRect(rect, false); if (parent) parent->AddControl(this); InitialUpdate(); Resize(m_clientRect.size()); }
uint32 DecisionObject::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_UPDATE: { Update(); } break; case MID_PRECREATE: { ObjectCreateStruct* pStruct = (ObjectCreateStruct*)pData; if (pStruct) { pStruct->m_Flags |= FLAG_FORCECLIENTUPDATE; } if (fData == PRECREATE_WORLDFILE || fData == PRECREATE_STRINGPROP) { ReadProp((ObjectCreateStruct*)pData); } } break; case MID_INITIALUPDATE: { if (fData != INITIALUPDATE_SAVEGAME) { InitialUpdate(); } } break; case MID_SAVEOBJECT: { Save((ILTMessage_Write*)pData); } break; case MID_LOADOBJECT: { Load((ILTMessage_Read*)pData); } break; default : break; } return BaseClass::EngineMessageFn(messageID, pData, fData); }
// ----------------------------------------------------------------------- // // // ROUTINE: CoreDump::EngineMessageFn // // PURPOSE: Handle engine messages // // ----------------------------------------------------------------------- // uint32 CoreDump::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_PRECREATE: { LTRESULT ret = GameBase::EngineMessageFn(messageID, pData, fData); return ret; } case MID_SAVEOBJECT: { // NOTE: If you want to save the base class first, // just switch the following two lines of code. Save((ILTMessage_Write*)pData, (uint32)fData); LTRESULT ret = GameBase::EngineMessageFn(messageID, pData, fData); return ret; } case MID_LOADOBJECT: { // NOTE: If you want to load the base class first, // just switch the following two lines of code. Load((ILTMessage_Read*)pData, (uint32)fData); LTRESULT ret = GameBase::EngineMessageFn(messageID, pData, fData); return ret; } case MID_UPDATE: { // Let our function determine whether or not we call the base class if(Update()) return LT_OK; return(GameBase::EngineMessageFn(messageID, pData, fData)); } case MID_INITIALUPDATE: { // Initial update InitialUpdate(); return LT_OK; } default: break; } return LT_OK; }
uint32 SpecialMove::EngineMessageFn(uint32 messageID, void *pData, float fData) { switch (messageID) { case MID_PRECREATE: { uint32 nRes = GameBase::EngineMessageFn(messageID, pData, fData); ObjectCreateStruct *pOCS = (ObjectCreateStruct*)pData; ReadProp(&pOCS->m_cProperties); PostReadProp(pOCS); return nRes; } break; case MID_OBJECTCREATED: { if( OBJECTCREATED_SAVEGAME != fData ) { // Link up the activation handler m_ActivateTypeHandler.Init( m_hObject ); } uint32 nRes = GameBase::EngineMessageFn(messageID, pData, fData); int nInfo = (int)fData; if (nInfo != INITIALUPDATE_SAVEGAME) { InitialUpdate(); } return nRes; } break; case MID_SAVEOBJECT: { Save( ( ILTMessage_Write* )pData, ( uint32 )fData ); break; } case MID_LOADOBJECT: { Load( ( ILTMessage_Read* )pData, ( uint32 )fData ); break; } } return GameBase::EngineMessageFn(messageID, pData, fData); }
uint32 RotatingDoor::EngineMessageFn(uint32 messageID, void *pData, float fData) { switch (messageID) { case MID_PRECREATE: { // Need to call base class to have the object name read in before // we call PostPropRead() uint32 dwRet = Door::EngineMessageFn(messageID, pData, fData); if (fData == 1.0f) { ReadProp((ObjectCreateStruct*)pData); } // Convert speeds from degrees to radians m_fSpeed = MATH_DEGREES_TO_RADIANS(m_fSpeed); m_fClosingSpeed = MATH_DEGREES_TO_RADIANS(m_fClosingSpeed); return dwRet; } case MID_INITIALUPDATE: { if (fData != INITIALUPDATE_SAVEGAME) { InitialUpdate(); } break; } case MID_SAVEOBJECT: { Save((HMESSAGEWRITE)pData, (uint8)fData); } break; case MID_LOADOBJECT: { Load((HMESSAGEREAD)pData, (uint8)fData); } break; default : break; } return Door::EngineMessageFn(messageID, pData, fData); }
uint32 Camera::EngineMessageFn(uint32 messageID, void *pData, float fData) { switch(messageID) { case MID_UPDATE: { Update(); } break; case MID_PRECREATE: { ObjectCreateStruct* pStruct = (ObjectCreateStruct*)pData; if (pStruct) { pStruct->m_Flags |= FLAG_GOTHRUWORLD | FLAG_FORCECLIENTUPDATE | FLAG_FULLPOSITIONRES; } if (fData == PRECREATE_WORLDFILE || fData == PRECREATE_STRINGPROP) { ReadProps(&pStruct->m_cProperties, false); } } break; case MID_INITIALUPDATE: { InitialUpdate((int)fData); } break; case MID_SAVEOBJECT: { Save((ILTMessage_Write*)pData, (uint32)fData); } break; case MID_LOADOBJECT: { Load((ILTMessage_Read*)pData, (uint32)fData); } break; default : break; } return BaseClass::EngineMessageFn(messageID, pData, fData); }
DDWORD DefenseGlobeLegs::EngineMessageFn(DDWORD messageID, void *pData, DFLOAT fData) { switch(messageID) { case MID_UPDATE: { if (!Update((DVector *)pData) ) { CServerDE* pServerDE = GetServerDE(); if (!pServerDE) break; pServerDE->RemoveObject(m_hObject); } } break; case MID_TOUCHNOTIFY: { ObjectTouch((HOBJECT)pData); } break; case MID_PRECREATE: { // Need to call base class to have the object name read in before // we call PostPropRead() DDWORD dwRet = B2BaseClass::EngineMessageFn(messageID, pData, fData); PostPropRead((ObjectCreateStruct*)pData); return dwRet; } case MID_INITIALUPDATE: { InitialUpdate((DVector *)pData); } break; default : break; } return B2BaseClass::EngineMessageFn(messageID, pData, fData); }
uint32 Alarm::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_PRECREATE: { if (fData == PRECREATE_WORLDFILE || fData == PRECREATE_STRINGPROP) { ReadProp((ObjectCreateStruct*)pData); } PostPropRead((ObjectCreateStruct*)pData); break; } case MID_INITIALUPDATE: { if (fData != INITIALUPDATE_SAVEGAME) { InitialUpdate(); } break; } case MID_ALLOBJECTSCREATED: { CreateRegionLists(); break; } case MID_SAVEOBJECT: { Save((ILTMessage_Write*)pData); } break; case MID_LOADOBJECT: { Load((ILTMessage_Read*)pData); } break; default : break; } return Prop::EngineMessageFn(messageID, pData, fData); }
DDWORD CivilianAI::EngineMessageFn(DDWORD messageID, void *pData, DFLOAT fData) { switch(messageID) { case MID_PRECREATE: { // Need to call base class to have the object name read in before // we call PostPropRead() DDWORD dwRet = AI_Mgr::EngineMessageFn(messageID, pData, fData); if (fData == 1.0) { GetServerDE()->GetPropBool("Male", &m_bMale); GetServerDE()->GetPropBool("LabTech", &m_bLabTech); GetServerDE()->GetPropBool("Scared", &m_bScared); GetServerDE()->GetPropBool("SororitySkin", &m_bSororitySkin); } if(fData != PRECREATE_SAVEGAME) PostPropRead((ObjectCreateStruct*)pData); return dwRet; } break; case MID_INITIALUPDATE: { InitialUpdate((DVector *)pData); CacheFiles(); break; } case MID_SAVEOBJECT: Save((HMESSAGEWRITE)pData, (DDWORD)fData); break; case MID_LOADOBJECT: Load((HMESSAGEREAD)pData, (DDWORD)fData); break; default : break; } return AI_Mgr::EngineMessageFn(messageID, pData, fData); }
DDWORD FireFX::EngineMessageFn(DDWORD messageID, void *pData, DFLOAT fData) { switch(messageID) { case MID_UPDATE: { if (!Update((DVector *)pData)) { CServerDE* pServerDE = BaseClass::GetServerDE(); if (!pServerDE) return 0; pServerDE->RemoveObject(m_hObject); } break; } case MID_PRECREATE: { if (fData == 1.0f) { ReadProp((ObjectCreateStruct*)pData); } break; } case MID_INITIALUPDATE: { InitialUpdate((DVector *)pData); break; } // If we created a link to the target, this will tell us that it no longer exists case MID_LINKBROKEN: { HOBJECT hObj = (HOBJECT)pData; if (m_hLinkObject == hObj) { m_hLinkObject = DNULL; } } break; default : break; } return B2BaseClass::EngineMessageFn(messageID, pData, fData); }
uint32 ScreenShake::EngineMessageFn(uint32 messageID, void *pData, LTFLOAT fData) { switch(messageID) { case MID_UPDATE: { Update(); } break; case MID_PRECREATE: { if (fData == PRECREATE_WORLDFILE) { ReadProp((ObjectCreateStruct*)pData); } } break; case MID_INITIALUPDATE: { if (fData != INITIALUPDATE_SAVEGAME) { InitialUpdate(); } CacheFiles(); } break; case MID_SAVEOBJECT: { Save((HMESSAGEWRITE)pData, (uint32)fData); } break; case MID_LOADOBJECT: { Load((HMESSAGEREAD)pData, (uint32)fData); } break; default : break; } return BaseClass::EngineMessageFn(messageID, pData, fData); }