SniperElite5.asl 7.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233
  1. // Thanks Kuno for the help much <3
  2. state("sniper5_dx12", "Steam 2.31")
  3. {
  4. string110 CurCutscene : 0x02689EE8, 0x38, 0x248, 0x0, 0x0;
  5. string14 CurMap : 0x30591CE;
  6. int start : 0x273264C; // main menu 5, in game 13, loading 3, second cutscene is 8, first 5. E8E3EC
  7. }
  8. state("sniper5_dx12", "Steam 2.30")
  9. {
  10. string110 CurCutscene : 0x02688EE8, 0x38, 0x248, 0x0, 0x0;
  11. string14 CurMap : 0x30581DE;
  12. int start : 0x273164C; // main menu 5, in game 13, loading 3, second cutscene is 8, first 5. E8E3EC
  13. }
  14. state("sniper5_dx12", "Steam 2.21")
  15. {
  16. string110 CurCutscene : 0x02688EE8, 0x38, 0x248, 0x0, 0x0;
  17. string14 CurMap : 0x30581EE;
  18. int start : 0x273164C; // main menu 5, in game 13, loading 3, second cutscene is 8, first 5. E8E3EC
  19. }
  20. state("sniper5_dx12", "Steam 1.6")
  21. {
  22. //string110 CurCutscene : 0x02673020, 0x8, 0x248, 0x0, 0x0;
  23. string110 CurCutscene : 0x0267BE30, 0x38, 0x248, 0x0, 0x0;
  24. string14 CurMap : 0x303EEAE;
  25. //int start : 0xE8A080; // main menu 6, in game 13, loading 3, second cutscene is 8, first 5. E8C3EC
  26. int start : 0xE8E3EC; // main menu 6, in game 13, loading 3, second cutscene is 8, first 5. E8E3EC
  27. }
  28. state("sniper5_dx12", "Steam 1.5")
  29. {
  30. //string110 CurCutscene : 0x02673020, 0x8, 0x248, 0x0, 0x0;
  31. string110 CurCutscene : 0x02673010, 0x38, 0x248, 0x0, 0x0;
  32. string14 CurMap : 0x303EEAE;
  33. //int start : 0xE8A080; // main menu 6, in game 13, loading 3, second cutscene is 8, first 5. E8C3EC
  34. int start : 0xE8E3EC; // main menu 6, in game 13, loading 3, second cutscene is 8, first 5. E8E3EC
  35. }
  36. state("sniper5_dx12", "Steam 1.3")
  37. {
  38. //string110 CurCutscene : 0x026FDE68, 0x20, 0x248, 0x0, 0x0;
  39. string110 CurCutscene : 0x02670900, 0x8, 0x248, 0x0, 0x0;
  40. string14 CurMap : 0x303C74E;
  41. int start : 0xE88080; // main menu 6, in game 13, loading 3, second cutscene is 8, first 5. E8C3EC
  42. }
  43. state("sniper5_dx12", "Steam 1.2")
  44. {
  45. string110 CurCutscene : 0x02663370, 0x38, 0x248, 0x0, 0x0;
  46. string14 CurMap : 0x302E3FE;
  47. int start : 0xE7E2FC; // main menu 6, in game 13, loading 3, second cutscene is 8, first 5
  48. }
  49. state("sniper5_dx12", "Steam 1.1")
  50. {
  51. string110 CurCutscene : 0x02637348, 0x8, 0x248, 0x0, 0x0;
  52. string14 CurMap : 0x2FFFB1E;
  53. int start : 0xE642FC; // main menu 6, in game 12, loading 3, second cutscene is 8
  54. }
  55. state("sniper5_dx12", "Xbox Game Pass 1.0.0")
  56. {
  57. string15 CurMap : 0x30866BE;
  58. int start : 0xEF9E9C;
  59. }
  60. state("sniper5_dx12", "Xbox Game Pass 1.1")
  61. {
  62. string110 CurCutscene : 0x026E7570, 0x8, 0x248, 0x0, 0x0;
  63. string15 CurMap : 0x30AAF8E;
  64. int start : 0xF0AC00;
  65. }
  66. init
  67. {
  68. switch(modules.First().ModuleMemorySize)
  69. {
  70. case 376324096 :
  71. version = "Xbox Game Pass 1.0.0";
  72. break;
  73. case 379846656 :
  74. version = "Xbox Game Pass 1.1";
  75. break;
  76. case 414150656 :
  77. version = "Steam 1.0.0";
  78. break;
  79. case 416047104 :
  80. version = "Steam 1.1";
  81. break;
  82. case 417222656 :
  83. version = "Steam 1.2";
  84. break;
  85. case 406196224 :
  86. version = "Steam 1.3";
  87. break;
  88. case 410013696 :
  89. version = "Steam 1.5";
  90. break;
  91. case 425156608 :
  92. version = "Steam 1.6";
  93. break;
  94. case 426545152 :
  95. version = "Steam 2.21";
  96. break;
  97. case 397815808 :
  98. version = "Steam 2.30";
  99. break;
  100. case 405721088 :
  101. version = "Steam 2.31";
  102. break;
  103. }
  104. vars.doneMaps = new List<string>(); // You get kicked to the main menu, so adding this just in case
  105. timer.Run.Offset = TimeSpan.FromMilliseconds(-480);
  106. }
  107. startup
  108. {
  109. var result = MessageBox.Show(timer.Form, // EAC Warning made by xZeKo :O
  110. "Please make sure Easy Anti-Cheat is disabled.\n"
  111. + "If you run the autosplit with Easy Anti-Cheat on, there is a possibility you could be banned.\n"
  112. + "\n \n Click Yes if Easy Anti-Cheat is disabled."
  113. + "\n \n Click No to find out how to disable Easy Anti-Cheat.",
  114. "Sniper Elite 5",
  115. MessageBoxButtons.YesNo,
  116. MessageBoxIcon.Information);
  117. if (result == DialogResult.No)
  118. {
  119. Process.Start("https://github.com/xZeko-SRC/SE5disableEAC/blob/main/README.md");
  120. }
  121. settings.Add("ils", true, "Individual Levels");
  122. settings.SetToolTip("ils", "Enable splits for ILs. Please uncheck Missions.");
  123. settings.Add("survival", false, "Survival");
  124. settings.SetToolTip("ils", "Enable splits for Survival. Please uncheck Missions and ILs.");
  125. settings.Add("missions", false, "Missions");
  126. settings.SetToolTip("missions", "Enable splits for Full Game. Please uncheck Individual Levels. \n Uncheck The Atlantic Wall or it will double split for Occupied Residence");
  127. vars.missions = new Dictionary<string,string>
  128. {
  129. //Coast.asr level 1
  130. {"Coast.asr", "The Atlantic Wall"},
  131. {"Chateau.asr", "Occupied Residence"},
  132. {"Island.asr", "Spy Academy"},
  133. {"Factory.asr", "War Factory"},
  134. {"Guernsey.asr", "Festung Guernesey"},
  135. {"Villages.asr", "Libération"},
  136. {"ResearchBase.a", "Secret Weapons"},
  137. {"StNazaire.asr", "Rubble And Ruin"},
  138. {"Chateau_Epilog", "Loose Ends"},
  139. {"DLC_KillHitler", "Wolf Mountain: DLC"},
  140. {"DLC01_Dragoon.", "Landing Force"},
  141. {"DLC03_Overlord", "Conqueror"},
  142. {"DLC02_Marathon", "Rough Landing"},
  143. {"DLC04_Poseidon", "Kraken Awakes"},
  144. };
  145. foreach (var Tag in vars.missions)
  146. {
  147. settings.Add(Tag.Key, true, Tag.Value, "missions");
  148. };
  149. vars.cutscenes = new List<string>
  150. {
  151. @"sounds\cutscenes\m01_coast\cs_m01_exfiltrate_sfx.wav",
  152. @"sounds\cutscenes\m02_chateau\cs_m02_exfiltrate_sfx.wav",
  153. @"sounds\cutscenes\m03_island\cs_m03_exfiltrate_sfx.wav",
  154. @"sounds\cutscenes\m03_island\cs_m03_exfiltrate_sfx.wav",
  155. @"sounds\cutscenes\m04_factory\cs_m04_exfiltrate_sfx.wav",
  156. @"sounds\cutscenes\m05_guernsey\cs_m05_exfiltrate_sfx.wav",
  157. @"sounds\cutscenes\m06_villages\cs_m06_exfiltrate_sfx.wav",
  158. @"sounds\cutscenes\m07_research_base\cs_m07_exfiltrate_sfx.wav",
  159. @"sounds\cutscenes\m08_st_nazaire\cs_m08_sub_pen_explosion_sfx.wav",
  160. @"sounds\cutscenes\m09_epilogue\cs_m09_mollerdead_sfx.wav",
  161. @"sounds\cutscenes\m10_killhitler\cs_m10_exf_sfx.wav",
  162. @"sounds\cutscenes\intros_outros\cs_dlc01_outro_sfx.wav",
  163. @"sounds\cutscenes\intros_outros\cs_dlc03_outro_sfx.wav", // Conqueror
  164. @"sounds\cutscenes\dlc04_poseidon\cs_dlc04_outro_sfx.wav" //Kraken Awakes
  165. };
  166. if (timer.CurrentTimingMethod == TimingMethod.RealTime) // stolen from dude simulator 3, basically asks the runner to set their livesplit to game time
  167. {
  168. var timingMessage = MessageBox.Show
  169. (
  170. "This game uses Time without Loads (Game Time) as the main timing method.\n"+
  171. "LiveSplit is currently set to show Real Time (RTA).\n"+
  172. "Would you like to set the timing method to Game Time? This will make verification easier",
  173. "LiveSplit | Sniper Elite 5",
  174. MessageBoxButtons.YesNo,MessageBoxIcon.Question
  175. );
  176. if (timingMessage == DialogResult.Yes)
  177. {
  178. timer.CurrentTimingMethod = TimingMethod.GameTime;
  179. }
  180. }
  181. }
  182. start
  183. {
  184. return ((current.start == 13) && (settings[current.CurMap]) || (settings["ils"] && (current.start == 13)) || (settings["survival"] && (current.start == 13)));
  185. }
  186. onStart
  187. {
  188. vars.doneMaps.Add(current.CurMap);
  189. }
  190. split
  191. {
  192. if ((current.CurMap != old.CurMap) && (settings[current.CurMap]) && (!vars.doneMaps.Contains(current.CurMap)) || (vars.cutscenes.Contains(current.CurCutscene) && (old.CurCutscene == null) && (settings["ils"])) || (settings["survival"]) && (old.start == 13) && (current.start == 8) || (current.CurMap == "Chateau_Epilog") && (old.start == 13) && (current.start == 8) || (current.CurMap == "DLC02_Marathon") && (old.start == 13) && (current.start == 8))
  193. {
  194. vars.doneMaps.Add(current.CurMap);
  195. return true;
  196. }
  197. }
  198. reset
  199. {
  200. return (settings["ils"] && (current.start == 3));
  201. }
  202. onReset
  203. {
  204. vars.doneMaps.Clear();
  205. }
  206. isLoading
  207. {
  208. return (settings["missions"] && current.start == 3);
  209. }