public override string VisitMine(MineCommand command) { string json = " \"command\": {\n"; json += " \"player\": \"" + command.GetPlayerName() + "\",\n"; json += " \"type\": \"set mine\",\n"; json += " \"x\": " + command.Point.X + ",\n"; json += " \"y\": " + command.Point.Y + ",\n"; json += " },\n"; return(json); }
public override string VisitMine(MineCommand command) { string xml = "<command>\n"; xml += " <player>" + command.GetPlayerName() + "</player>\n"; xml += " <type>Set mine</type>\n"; xml += " <x>" + command.Point.X + "</x>\n"; xml += " <y>" + command.Point.Y + "</y>\n"; xml += "</command>\n"; return(xml); }
public override string VisitMine(MineCommand command) { return("Player " + command.GetPlayerName() + " set a mine at " + command.Point + ".\n"); }