You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

CommandLineArgs.cs 1.6 kB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. using System;
  2. using System.Collections.Generic;
  3. using CommandLine;
  4. namespace Client
  5. {
  6. static class DefaultArgumentOptions
  7. {
  8. public static string FileName = "CLGG!@#$%^&*()_+"; // An impossible name of the playback file to indicate -f is not sepcified.
  9. }
  10. public class ArgumentOptions
  11. {
  12. [Option('u', "cl", Required = false, HelpText = "Whether to use command line")]
  13. public bool cl { get; set; } = false;
  14. [Option('i', "ip", Required = false, HelpText = "Client connected ip")]
  15. public string Ip { get; set; } = "127.0.0.1";
  16. [Option('p', "port", Required = false, HelpText = "Client listening port")]
  17. public string Port { get; set; } = "8888";
  18. [Option('t', "teamID", Required = false, HelpText = "Client teamID")]
  19. public string TeamID { get; set; } = "0";
  20. [Option('c', "characterID", Required = false, HelpText = "Client playerID")]
  21. public string PlayerID { get; set; } = "0";
  22. [Option('y', "type", Required = false, HelpText = "Client playerType")]
  23. public string PlayerType { get; set; } = "0";
  24. [Option('o', "occupation", Required = false, HelpText = "Client occupation")]
  25. public string Occupation { get; set; } = "0";
  26. [Option('f', "playbackFile", Required = false, HelpText = "The playback file name.")]
  27. public string PlaybackFile { get; set; } = DefaultArgumentOptions.FileName;
  28. [Option("playbackSpeed", Required = false, HelpText = "The speed of the playback, between 0.25 and 4.0")]
  29. public double PlaybackSpeed { get; set; } = 1.0;
  30. }
  31. }