land_buoy.c 978 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. class Land_Buoy extends House
  2. {
  3. protected BuoyLight m_Light;
  4. override void DeferredInit()
  5. {
  6. super.DeferredInit();
  7. if (!GetGame().IsDedicatedServer())
  8. {
  9. m_Light = BuoyLight.Cast(ScriptedLightBase.CreateLightAtObjMemoryPoint(BuoyLight, this, "light_01"));
  10. m_Light.SetSelectionID(GetHiddenSelectionIndex("Glass"));
  11. m_Light.UpdateLightSourceMaterial(BuoyLight.LIGHT_MAT_ON);
  12. }
  13. }
  14. void ~Land_Buoy()
  15. {
  16. if (m_Light)
  17. m_Light.Destroy();
  18. }
  19. }
  20. class Land_MooringBuoy extends House
  21. {
  22. protected MooringBuoyLight m_Light;
  23. override void DeferredInit()
  24. {
  25. super.DeferredInit();
  26. if (!GetGame().IsDedicatedServer())
  27. {
  28. m_Light = MooringBuoyLight.Cast(ScriptedLightBase.CreateLightAtObjMemoryPoint(MooringBuoyLight, this, "light_01"));
  29. m_Light.SetSelectionID(GetHiddenSelectionIndex("Glass"));
  30. m_Light.UpdateLightSourceMaterial(MooringBuoyLight.LIGHT_MAT_ON);
  31. }
  32. }
  33. void ~Land_MooringBuoy()
  34. {
  35. if (m_Light)
  36. m_Light.Destroy();
  37. }
  38. }