Ejemplo n.º 1
0
 public override void OnEvent(PerformRepairBuilding evnt)
 {
     if (evnt.Building)
     {
         evnt.Building.GetComponentInChildren <BuildingHealth>().RespawnBuilding();
     }
 }
Ejemplo n.º 2
0
 public override void OnEvent(PerformRepairBuilding evnt)
 {
     if (!this.ValidateSender(evnt, SenderTypes.Any))
     {
         return;
     }
     if (evnt.Building)
     {
         evnt.Building.GetComponentInChildren <BuildingHealth>().RespawnBuilding();
     }
 }
Ejemplo n.º 3
0
 public void Repair()
 {
     this.RepairMaterialActual = 0;
     this._repairLogsActual    = 0;
     this._collapsedLogs       = 0;
     if (this._repairTrigger)
     {
         UnityEngine.Object.Destroy(this._repairTrigger.gameObject);
         this._repairTrigger = null;
     }
     this.HpActual = this._maxHP;
     if (BoltNetwork.isServer)
     {
         PerformRepairBuilding performRepairBuilding = PerformRepairBuilding.Create(GlobalTargets.AllClients);
         performRepairBuilding.Building = base.entity;
         performRepairBuilding.Send();
     }
     this.RespawnBuilding();
 }
Ejemplo n.º 4
0
 public override void OnEvent(PerformRepairBuilding evnt)
 {
     if (evnt.Building)
     {
         evnt.Building.GetComponentInChildren<BuildingHealth>().RespawnBuilding();
     }
 }