Beispiel #1
0
    public void CmdPlayerShot(string _playerID, int _damage)
    {
        Debug.Log(_playerID + "has been shot");
        Player _player = GameManager1.GetPlayer(_playerID);

        _player.RpcTakeDamage(_damage);
    }
    public void CmdPlayerShot(string _playerID, float _damage)
    {
        UnityEngine.Debug.Log(_playerID + " has been shot");
        Player _player = GameManager1.GetPlayer(_playerID);

        _player.RpcTakeDamage(_damage);

        Destroy(this.gameObject);
    }
Beispiel #3
0
    void CmdPlayerShot(string playerId, int damage, GameObject p)
    {
        Debug.Log(playerId + "has been shot");
        Player player = GameManager1.GetPlayer(playerId);



        player.RpcTakeDamage(damage, p);



        //NetworkServer.Destroy(p);


        // NetworkTransformChild.Destroy(p);
        //  player.RpcTakeDamage(damage);
    }