コード例 #1
0
 public void Deserialize(BinaryReader reader)
 {
     Type = (VMCommandType)reader.ReadByte();
     Type cmdType = CmdMap[Type];
     Command = (VMNetCommandBodyAbstract)Activator.CreateInstance(cmdType);
     Command.Deserialize(reader);
 }
コード例 #2
0
 public void SetCommand(VMNetCommandBodyAbstract cmd)
 {
     Type = ReverseMap[cmd.GetType()];
     Command = cmd;
 }