virtual void Serialize(SActivationInfo *pActInfo, TSerialize ser) { uint32 val = m_state; ser.Value("m_state", val ); m_state = EState(val); if (ser.IsReading() && m_state==ES_WaitForSaveDone) { m_state = ES_Notify; // because we are not going to receive any event notification from CryAction, and we still want to notify the Done output. } if (m_state==ES_WaitForPlayerNotInAir) // even just in saving mode, we dont want this to keep running if there was already another save triggered. { m_state = ES_Idle; pActInfo->pGraph->SetRegularlyUpdated(pActInfo->myID, false); } }
void CPhantom::load(IReader &input_packet) { SwitchToState (EState(input_packet.r_s32())); }