コード例 #1
0
ファイル: Snapshot.cs プロジェクト: niqqq25/MultiJuice
    public void Deserialize(INetBuffer reader)
    {
        Tick = reader.GetInt();
        int playerStateCount = reader.GetInt();

        PlayerStates = new PlayerState[playerStateCount];
        PlayerState playerState = new PlayerState();

        for (int i = 0; i < playerStateCount; i++)
        {
            playerState.Deserialize(reader);
            PlayerStates[i] = playerState;
        }
    }
コード例 #2
0
ファイル: Snapshot.cs プロジェクト: niqqq25/MultiJuice
 public void Deserialize(INetBuffer reader)
 {
     PlayerId = reader.GetInt();
     Position = reader.GetVector3(true);
     Rotation = reader.GetQuaternion(true);
 }