public void fire() { if (player.isLocalPlayer) { player.CmdFire(); } }
public void Shoot() { if (Time.time >= timeToFire) { myPlayer.CmdFire(); timeToFire = Time.time + 1 / firerate; } }