예제 #1
0
 public override void PostDeSpawn(Map map)
 {
     if (map != null)
     {
         MapRoomUpdater mapComp = map.GetComponent <MapRoomUpdater>();
         if (mapComp != null)
         {
             mapComp.RemoveObjectFromMap(this.parent);
         }
     }
 }
예제 #2
0
 public override void PostDestroy(DestroyMode mode, Map previousMap)
 {
     if (previousMap != null)
     {
         MapRoomUpdater mapComp = previousMap.GetComponent <MapRoomUpdater>();
         if (mapComp != null)
         {
             mapComp.RemoveObjectFromMap(this.parent);
         }
     }
 }
예제 #3
0
 public override void PostSpawnSetup(bool respawningAfterLoad)
 {
     if (this.parent.Map != null)
     {
         MapRoomUpdater mapComp = this.parent.Map.GetComponent <MapRoomUpdater>();
         if (mapComp != null)
         {
             mapComp.AddObjectToMap(this.parent);
         }
     }
 }