private void checkIfCollected(RespawnResponse respawnResponse) { switch (respawnResponse.State) { case RespawnState.READY_FOR_PICKUP: break; case RespawnState.NOT_AVAILABLE: pickup(sendPickupEvent: false); break; case RespawnState.WAITING_TO_RESPAWN: pickup(sendPickupEvent: false); break; } }
private void checkIfCollected(RespawnResponse respawnResponse) { switch (respawnResponse.State) { case RespawnState.NOT_AVAILABLE: SetState(ClamState.NOT_AVAILABLE); break; case RespawnState.READY_FOR_PICKUP: SetState(ClamState.READY_FOR_PICKUP); break; case RespawnState.WAITING_TO_RESPAWN: registerToRespawn(respawnResponse.Time); SetState(ClamState.WAITING_TO_RESPAWN); break; } }
private void checkIfCollected(RespawnResponse respawnResponse) { switch (respawnResponse.State) { case RespawnState.NOT_AVAILABLE: setNotAvailable(); break; case RespawnState.READY_FOR_PICKUP: setAvailable(); break; case RespawnState.WAITING_TO_RESPAWN: registerToRespawn(respawnResponse.Time); setNotAvailable(); break; } }
public override void StartCollectible(RespawnResponse respawnResponse) { isInitialized = true; checkIfCollected(respawnResponse); }
public virtual void StartCollectible(RespawnResponse respawnResponse) { Log.LogError(this, $"You shouldn't see this message. Method 'startCollectible' must be overidden in the extended class"); }
private void setCollectibleState(Collectible scriptObj) { RespawnResponse respawnState = getRespawnState(scriptObj); scriptObj.StartCollectible(respawnState); }