public static void writePawn(this IValueWriter writer, PawnRef pawn) { writer.WriteInt32(pawn.empire); writer.WriteInt32((int)pawn.type); writer.WriteInt32(pawn.level); writer.writePosition(pawn.pos); writer.WriteInt32(pawn.lastMove); }
private Subtexture pickTexture(PawnRef pawnRef) { return(pawnSubtexes[(int)pawnRef.type]); }
public override void ReadPayload(ISerializationContext context, IValueReader reader) { pawn = reader.readPawn(); dest = reader.readPosition(); }