CODModernWarfare2019.asl 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. /*
  2. Because of the frequence of the game being updates this is now a stump until either warzone dies, or the game has a campaign only mode.
  3. */
  4. state("ModernWarfare")
  5. {
  6. string100 map : 0xDE83FA1;
  7. int loading1 : 0xEDD51C4;
  8. }
  9. startup
  10. {
  11. settings.Add("act0", true, "all Acts");
  12. settings.Add("act1", true, "Act 1", "act0");
  13. settings.Add("act2", true, "Act 2", "act0");
  14. settings.Add("act3", true, "Act 3", "act0");
  15. vars.missions = new Dictionary<string,string>
  16. {
  17. {"piccadilly","Piccadilly"},
  18. {"safehouse","embedded"},
  19. {"ouse_finale","Proxy War"},
  20. {"townhoused","Clean House"},
  21. {"marines","Hunting Party"},
  22. {"embassy","Embassy"},
  23. };
  24. foreach (var Tag in vars.missions)
  25. {
  26. settings.Add(Tag.Key, true, Tag.Value, "act1");
  27. };
  28. vars.missions2 = new Dictionary<string,string>
  29. {
  30. {"highway","Highway of Death"},
  31. {"hometown","Hometown"},
  32. {"tunnels","The Wolf's Den"},
  33. {"captive","Captive"},
  34. };
  35. foreach (var Tag in vars.missions2)
  36. {
  37. settings.Add(Tag.Key, true, Tag.Value, "act2");
  38. };
  39. vars.missions3 = new Dictionary<string,string>
  40. {
  41. {"stpetersburg","Old Comrads"},
  42. {"estate","Going Dark"},
  43. {"lab","Into the Furnace"},
  44. };
  45. foreach (var Tag in vars.missions3)
  46. {
  47. settings.Add(Tag.Key, true, Tag.Value, "act3");
  48. };
  49. vars.onStart = (EventHandler)((s, e) => // thanks gelly for this, it's basically making sure it always clears the vars no matter how livesplit starts
  50. {
  51. vars.doneMaps.Clear();
  52. });
  53. timer.OnStart += vars.onStart;
  54. if (timer.CurrentTimingMethod == TimingMethod.RealTime) // stolen from dude simulator 3, basically asks the runner to set their livesplit to game time
  55. {
  56. var timingMessage = MessageBox.Show (
  57. "This game uses Time without Loads (Game Time) as the main timing method.\n"+
  58. "LiveSplit is currently set to show Real Time (RTA).\n"+
  59. "Would you like to set the timing method to Game Time? This will make verification easier",
  60. "LiveSplit | Call of Duty: Modern Warfare 2019",
  61. MessageBoxButtons.YesNo,MessageBoxIcon.Question
  62. );
  63. if (timingMessage == DialogResult.Yes)
  64. {
  65. timer.CurrentTimingMethod = TimingMethod.GameTime;
  66. }
  67. }
  68. }
  69. init
  70. {
  71. vars.doneMaps = new List<string>(); // You can accidently enter a previous level so adding this just in case someone gets kicked to the menu
  72. }
  73. split
  74. {
  75. if ((current.map != old.map) && (settings[(current.map)]) && (!vars.doneMaps.Contains(current.map)))
  76. {
  77. vars.doneMaps.Add(current.map);
  78. return true;
  79. }
  80. }
  81. start
  82. {
  83. if ((current.map == "proxywar") && (current.loading1 == 1118989) && ((old.loading1 != 1118989)))
  84. {
  85. vars.doneMaps.Clear();
  86. return true;
  87. }
  88. }
  89. isLoading
  90. {
  91. return ((current.loading1 == 1118988));
  92. }
  93. exit
  94. {
  95. timer.OnStart -= vars.onStart;
  96. }