コード例 #1
0
    private void CmdPlayCard(GameObject card, GameObject targetZone)
    {
        PooledNetworkWriter writer = NetworkWriterPool.GetWriter();

        writer.WriteGameObject(card);
        writer.WriteGameObject(targetZone);
        this.SendCommandInternal(typeof(PlayerManager), nameof(CmdPlayCard), (NetworkWriter)writer, 0);
        NetworkWriterPool.Recycle(writer);
    }
コード例 #2
0
    private void RpcShowCard(GameObject card, string type, GameObject destination)
    {
        PooledNetworkWriter writer = NetworkWriterPool.GetWriter();

        writer.WriteGameObject(card);
        writer.WriteString(type);
        writer.WriteGameObject(destination);
        this.SendRPCInternal(typeof(PlayerManager), nameof(RpcShowCard), (NetworkWriter)writer, 0, false);
        NetworkWriterPool.Recycle(writer);
    }