ObjectSMCHelper.cpp 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. /*
  2. ** Command & Conquer Generals Zero Hour(tm)
  3. ** Copyright 2025 Electronic Arts Inc.
  4. **
  5. ** This program is free software: you can redistribute it and/or modify
  6. ** it under the terms of the GNU General Public License as published by
  7. ** the Free Software Foundation, either version 3 of the License, or
  8. ** (at your option) any later version.
  9. **
  10. ** This program is distributed in the hope that it will be useful,
  11. ** but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. ** GNU General Public License for more details.
  14. **
  15. ** You should have received a copy of the GNU General Public License
  16. ** along with this program. If not, see <http://www.gnu.org/licenses/>.
  17. */
  18. ////////////////////////////////////////////////////////////////////////////////
  19. // //
  20. // (c) 2001-2003 Electronic Arts Inc. //
  21. // //
  22. ////////////////////////////////////////////////////////////////////////////////
  23. // FILE: ObjectSMCHelper.cpp //////////////////////////////////////////////////////////////////////
  24. // Author: Colin Day, Steven Johnson, September 2002
  25. // Desc: SMC helper
  26. ///////////////////////////////////////////////////////////////////////////////////////////////////
  27. // INCLUDES ///////////////////////////////////////////////////////////////////////////////////////
  28. #include "PreRTS.h"
  29. #include "Common/Xfer.h"
  30. #include "GameLogic/Object.h"
  31. #include "GameLogic/Module/ObjectSMCHelper.h"
  32. // ------------------------------------------------------------------------------------------------
  33. // ------------------------------------------------------------------------------------------------
  34. ObjectSMCHelper::~ObjectSMCHelper( void )
  35. {
  36. }
  37. // ------------------------------------------------------------------------------------------------
  38. // ------------------------------------------------------------------------------------------------
  39. UpdateSleepTime ObjectSMCHelper::update()
  40. {
  41. // if we ever get here, stop this.
  42. getObject()->clearSpecialModelConditionStates();
  43. // then go back to sleep until we are forcibly awakened.
  44. return UPDATE_SLEEP_FOREVER;
  45. }
  46. // ------------------------------------------------------------------------------------------------
  47. /** CRC */
  48. // ------------------------------------------------------------------------------------------------
  49. void ObjectSMCHelper::crc( Xfer *xfer )
  50. {
  51. // object helper crc
  52. ObjectHelper::crc( xfer );
  53. } // end crc
  54. // ------------------------------------------------------------------------------------------------
  55. /** Xfer method
  56. * Version Info;
  57. * 1: Initial version */
  58. // ------------------------------------------------------------------------------------------------
  59. void ObjectSMCHelper::xfer( Xfer *xfer )
  60. {
  61. // version
  62. XferVersion currentVersion = 1;
  63. XferVersion version = currentVersion;
  64. xfer->xferVersion( &version, currentVersion );
  65. // object helper base class
  66. ObjectHelper::xfer( xfer );
  67. } // end xfer
  68. // ------------------------------------------------------------------------------------------------
  69. /** Load post process */
  70. // ------------------------------------------------------------------------------------------------
  71. void ObjectSMCHelper::loadPostProcess( void )
  72. {
  73. // object helper base class
  74. ObjectHelper::loadPostProcess();
  75. } // end loadPostProcess