public void SpawnBombCommand(string aJson) { if ((m_playerPlane.IsServerBot && !IsServer) && (!IsLocalPlayer || !_hasAuthority)) { return; } BombInfo bombInfo = BombInfo.GetBombInfo(aJson); m_gMan.CmdSpawnBomb(bombInfo.m_startPosition, bombInfo.m_startDirection, bombInfo.m_startVelocity, bombInfo.m_shooter); }
public void SetBombInfo(BombInfo aBombInfo) { m_bombInfo = aBombInfo; m_bombInfo.gameObject = this.gameObject; /* * string teamBombPath = ""; * * if (BombersPlayerController.GetPlayer(m_bombInfo.m_shooter).m_team == 1) * { * teamBombPath = "Bomb01"; * } * else * { * teamBombPath = "Bomb02"; * } */ //GameObject graphic = (GameObject)Instantiate((GameObject)Resources.Load(teamBombPath), transform.position, transform.rotation); //graphic.transform.parent = transform; }
public void DeleteBombCommand(BombController aBombController, int aID) { BombInfo aBombInfo = aBombController.BombInfo; m_gMan.CmdDeleteBomb(aBombInfo.GetJson(), aID); }