Advertisement
ThoraldGM

HH Map Script 20171214

Dec 14th, 2017
213
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 49.56 KB | None | 0 0
  1. Scriptname HH_MapScript extends ObjectReference
  2. { It just works. }
  3.  
  4. ; Fallout 4 Papyrus script by ThoraldGM | http://thoraldgm.com | Updated 20171214
  5. ; Hitchhiker mod: (url pending)
  6.  
  7. ; SCRIPT SECTIONS:
  8.  
  9. ; LINE : PROPERTIES
  10. ; LINE : ON READ
  11. ; LINE : HH SHOW MAIN MENU
  12. ; LINE : HH SHOW THE ANY MENU
  13. ; LINE : HH SHOW THE SPECIFIC MENU
  14. ; LINE : HH SHOW MENU BUS SHELTERS
  15. ; LINE : HH SHOW MENU DINERS 1
  16. ; LINE : HH SHOW MENU DINERS 2
  17. ; LINE : HH SHOW MENU DINERS 3
  18. ; LINE : HH SHOW MENU DIVES
  19. ; LINE : HH SHOW MENU DRIVE INS
  20. ; LINE : HH SHOW MENU FACTORIES
  21. ; LINE : HH SHOW MENU FARMS
  22. ; LINE : HH SHOW MENU JUNKYARDS 1
  23. ; LINE : HH SHOW MENU JUNKYARDS 2
  24. ; LINE : HH SHOW MENU MILITARY BASES 1
  25. ; LINE : HH SHOW MENU MILITARY BASES 2
  26. ; LINE : HH SHOW MENU MONUMENTS 1
  27. ; LINE : HH SHOW MENU MONUMENTS 2
  28. ; LINE : HH SHOW MENU MONUMENTS 3
  29. ; LINE : HH SHOW MENU POWER LIFTS 1
  30. ; LINE : HH SHOW MENU POWER LIFTS 2
  31. ; LINE : HH SHOW MENU RED ROCKET 1
  32. ; LINE : HH SHOW MENU RED ROCKET 2
  33. ; LINE : HH SHOW MENU VAULTS
  34. ; LINE : HH SHOW DLC OPTIONS
  35. ; LINE : HH SHOW CAMERA OPTIONS
  36. ; LINE : HH SHOW SET MAX
  37. ; LINE : HH SHOW SET MIN
  38. ; LINE : HH SHOW SET DURATION
  39. ; LINE : HH SHOW TELEPORT OPTIONS
  40. ; LINE : HH SHOW SET TIME
  41. ; LINE : HH SHOW SET WEATHER
  42. ; LINE : HH SHOW ADVANCED OPTIONS
  43. ; LINE : HH SHOW SET X
  44. ; LINE : HH SHOW SET Y
  45. ; LINE : HH SHOW SET Z
  46. ; LINE : HH SET MENU DEFAULTS
  47.  
  48. ; ------------------------------------------------------------------------------------------------------------
  49. ; PROPERTIES
  50. ; ------------------------------------------------------------------------------------------------------------
  51.  
  52. ; ************************************************************************************************************
  53. ; Player menu options (21 total):
  54. ; ************************************************************************************************************
  55. GlobalVariable Property HH_OptionCamMaxDistance Auto Mandatory ; Max camera distance (default: 200, vanilla: 150)
  56. GlobalVariable Property HH_OptionCamMinDistance Auto Mandatory ; Min camera distance (default: 100, vanilla: 0)
  57. GlobalVariable Property HH_OptionDevTracking Auto Mandatory ; Does player want dev messages? (default: no)
  58. GlobalVariable Property HH_OptionExcludeDLC Auto Mandatory ; Turn all DLC on/off in available destinations (default: on if installed)
  59. GlobalVariable Property HH_OptionExcludeFH Auto Mandatory ; Turn Far Harbor DLC on/off in destinations (default: on if installed)
  60. GlobalVariable Property HH_OptionExcludeNW Auto Mandatory ; Turn Nuka-World DLC on/off in destinations (default: on if installed)
  61. GlobalVariable Property HH_OptionExcludeVT Auto Mandatory ; Turn Vault-Tec DLC on/off in destinations (default: on if installed)
  62. GlobalVariable Property HH_OptionFastTravel Auto Mandatory ; Does player want loading screens? (default: yes)
  63. GlobalVariable Property HH_OptionHeal Auto Mandatory ; Does player want to heal after teleport? (default: no)
  64. GlobalVariable Property HH_OptionOffsetX Auto Mandatory ; Player can choose X offset (default: 250)
  65. GlobalVariable Property HH_OptionOffsetY Auto Mandatory ; Player can choose Y offset (default: 250)
  66. GlobalVariable Property HH_OptionOffsetZ Auto Mandatory ; Player can choose Z offset (default: 500)
  67. GlobalVariable Property HH_OptionSetTime Auto Mandatory ; Change time after teleport? (default: no)
  68. GlobalVariable Property HH_OptionSetTimePreference Auto Mandatory ; Preferred game hour (player sets in menu)
  69. GlobalVariable Property HH_OptionSetWeather Auto Mandatory ; Change weather after teleport? (default: no)
  70. GlobalVariable Property HH_OptionSetWeatherPreference Auto Mandatory ; Preferred game weather (player sets in menu)
  71. GlobalVariable Property HH_OptionSitFurniture Auto Mandatory ; If destination is furniture, choose whether to use it (default: yes)
  72. GlobalVariable Property HH_OptionSpinCamera Auto Mandatory ; Does player want teleport to spin camera? (default: yes)
  73. GlobalVariable Property HH_OptionSpinDuration Auto Mandatory ; How long should camera spin? (default: 20 seconds)
  74. GlobalVariable Property HH_OptionSpinGhost Auto Mandatory ; Does player want invulnerable spin? (default: yes)
  75. GlobalVariable Property HH_OptionTeleportSound Auto Mandatory ; Does player want teleport sound? (default: yes)
  76.  
  77. ; ************************************************************************************************************
  78. ; Menus:
  79. ; ************************************************************************************************************
  80. Message Property HH_MenuMessage Auto Const Mandatory ; Main menu
  81. Message Property HH_DestMessageAny Auto Const Mandatory ; Any menu
  82.  
  83. Message Property HH_DestMessageSpecific Auto Const Mandatory ; Specific menu
  84. Message Property HH_DestMessageSpecificBusShelters Auto Const Mandatory ; Specific: Bus Shelters
  85. Message Property HH_DestMessageSpecificDiners1 Auto Const Mandatory ; Specific: Diners 1
  86. Message Property HH_DestMessageSpecificDiners2 Auto Const Mandatory ; Specific: Diners 2
  87. Message Property HH_DestMessageSpecificDiners3 Auto Const Mandatory ; Specific: Diners 3
  88. Message Property HH_DestMessageSpecificDives Auto Const Mandatory ; Specific: Dives
  89. Message Property HH_DestMessageSpecificDriveIns Auto Const Mandatory ; Specific: Drive-Ins
  90. Message Property HH_DestMessageSpecificFactories Auto Const Mandatory ; Specific: Factories
  91. Message Property HH_DestMessageSpecificFarms Auto Const Mandatory ; Specific: Farms
  92. Message Property HH_DestMessageSpecificJunkyards1 Auto Const Mandatory ; Specific: Junkyards 1
  93. Message Property HH_DestMessageSpecificJunkyards2 Auto Const Mandatory ; Specific: Junkyards 2
  94. Message Property HH_DestMessageSpecificMilitaryBases1 Auto Const Mandatory ; Specific: Military Bases 1
  95. Message Property HH_DestMessageSpecificMilitaryBases2 Auto Const Mandatory ; Specific: Military Bases 2
  96. Message Property HH_DestMessageSpecificMonuments1 Auto Const Mandatory ; Specific: Monuments 1
  97. Message Property HH_DestMessageSpecificMonuments2 Auto Const Mandatory ; Specific: Monuments 2
  98. Message Property HH_DestMessageSpecificMonuments3 Auto Const Mandatory ; Specific: Monuments 3
  99. Message Property HH_DestMessageSpecificPowerLifts1 Auto Const Mandatory ; Specific: Power Lifts 1
  100. Message Property HH_DestMessageSpecificPowerLifts2 Auto Const Mandatory ; Specific: Power Lifts 2
  101. Message Property HH_DestMessageSpecificRedRocket1 Auto Const Mandatory ; Specific: Red Rockets 1
  102. Message Property HH_DestMessageSpecificRedRocket2 Auto Const Mandatory ; Specific: Red Rockets 2
  103. Message Property HH_DestMessageSpecificVaults Auto Const Mandatory ; Specific: Vaults
  104.  
  105. Message Property HH_MenuMessageDLCOptions Auto Const Mandatory ; DLCOptions menu
  106.  
  107. Message Property HH_MenuMessageCameraOptions Auto Const Mandatory ; CameraOptions menu
  108. Message Property HH_MenuMessageSetMax Auto Const Mandatory ; Camera: Set Max Distance
  109. Message Property HH_MenuMessageSetMin Auto Const Mandatory ; Camera: Set Min Distance
  110. Message Property HH_MenuMessageSetDuration Auto Const Mandatory ; Camera: Set Spin Duration
  111.  
  112. Message Property HH_MenuMessageTeleportOptions Auto Const Mandatory ; TeleportOptions menu
  113. Message Property HH_MenuMessageSetTime Auto Const Mandatory ; SetTime menu
  114. Message Property HH_MenuMessageSetWeather Auto Const Mandatory ; SetWeather menu
  115.  
  116. Message Property HH_MenuMessageAdvancedOptions Auto Const Mandatory ; AdvancedOptions menu
  117. Message Property HH_MenuMessageSetX Auto Const Mandatory ; SetX menu
  118. Message Property HH_MenuMessageSetY Auto Const Mandatory ; SetY menu
  119. Message Property HH_MenuMessageSetZ Auto Const Mandatory ; SetZ menu
  120.  
  121. ; ************************************************************************************************************
  122. ; Ref quests to avoid persistence / bloat:
  123. ; ************************************************************************************************************
  124. Quest Property QuestRefBusShelters Auto Const Mandatory ; Quest stores Bus Shelters ref aliases
  125. Quest Property QuestRefDiners Auto Const Mandatory ; Quest stores Diners ref aliases
  126. Quest Property QuestRefDives Auto Const Mandatory ; Quest stores Dives ref aliases
  127. Quest Property QuestRefDriveIns Auto Const Mandatory ; Quest stores Drive-Ins ref aliases
  128. Quest Property QuestRefFactories Auto Const Mandatory ; Quest stores Factories ref aliases
  129. Quest Property QuestRefFarms Auto Const Mandatory ; Quest stores Farms ref aliases
  130. Quest Property QuestRefJunkyards Auto Const Mandatory ; Quest stores Junkyards ref aliases
  131. Quest Property QuestRefMilitaryBases Auto Const Mandatory ; Quest stores Military Bases ref aliases
  132. Quest Property QuestRefMonuments Auto Const Mandatory ; Quest stores Monuments ref aliases
  133. Quest Property QuestRefPowerLifts Auto Const Mandatory ; Quest stores Power Lifts ref aliases
  134. Quest Property QuestRefRedRocket Auto Const Mandatory ; Quest stores Red Rocket ref aliases
  135. Quest Property QuestRefVaults Auto Const Mandatory ; Quest stores Vaults ref aliases
  136. Quest Property HH_Quest Auto Const Mandatory ; Hitchhiker main quest
  137. HH_QuestScript Property HHQuestScript Auto ; Hitchhiker main quest script
  138.  
  139. ; ************************************************************************************************************
  140. ; Everything else:
  141. ; ************************************************************************************************************
  142. Actor Player ; Player actor
  143. GlobalVariable Property HH_IsSpinning Auto Mandatory ; Is the camera currently spinning?
  144. GlobalVariable Property HH_PlayerHasFH Auto Mandatory ; Does player have Far Harbor DLC?
  145. GlobalVariable Property HH_PlayerHasNW Auto Mandatory ; Does player have Nuka-World DLC?
  146. GlobalVariable Property HH_PlayerHasVT Auto Mandatory ; Does player have Vault-Tec DLC?
  147. GlobalVariable Property HH_RefAliasID Auto Mandatory ; Which specific location did player select?
  148. GlobalVariable Property HH_ShowMenu Auto Mandatory ; Don't show menu when map not in inventory
  149. GlobalVariable Property HH_Version Auto Mandatory ; The current version of Hitchhiker (for map menu)
  150. Float CurrentStatus ; Placeholder for current global values (for map menu)
  151.  
  152. ; ------------------------------------------------------------------------------------------------------------
  153. ; EVENT: ON READ
  154. ; ------------------------------------------------------------------------------------------------------------
  155.  
  156. Event OnRead()
  157. Player = Game.GetPlayer() ; Player actor
  158. Bool FarHarborInstalled = Game.IsPluginInstalled("DLCCoast.esm") ; Does player have Far Harbor DLC?
  159. Bool NukaWorldInstalled = Game.IsPluginInstalled("DLCNukaWorld.esm") ; Does player have Nuka-World DLC?
  160. Bool VaultTecInstalled = Game.IsPluginInstalled("DLCworkshop03.esm") ; Does player have Vault-Tec DLC?
  161.  
  162. Utility.WaitMenuMode(0.1) ; Wait a moment before using DLC checks
  163.  
  164. If FarHarborInstalled ; If Far Harbor DLC installed,
  165. HH_PlayerHasFH.SetValue(1) ; unlock FH destinations
  166. EndIf
  167.  
  168. If NukaWorldInstalled ; If Nuka-World DLC installed,
  169. HH_PlayerHasNW.SetValue(1) ; unlock NW destinations
  170. EndIf
  171.  
  172. If VaultTecInstalled ; If Vault-Tec DLC installed,
  173. HH_PlayerHasVT.SetValue(1) ; unlock VT destination
  174. EndIf
  175.  
  176. Utility.WaitMenuMode(0.1) ; Wait a moment before using actor
  177.  
  178. If GetContainer() != Player ; If hitchhiker map is not in inventory (on ground, etc)
  179. HH_ShowMenu.SetValue(0) ; do not show the menu
  180. EndIf
  181.  
  182. If HH_ShowMenu.GetValue() as Int == 1 ; Default value is zero so "awesome" message plays on add
  183. Utility.WaitMenuMode(2) ; Give magazine a chance to fill menu background
  184. HH_ShowMainMenu() ; then show the main menu
  185. Else
  186. HH_ShowMenu.SetValue(1) ; Added to inventory, so show menu from now on
  187. EndIf
  188. EndEvent
  189.  
  190. ; ------------------------------------------------------------------------------------------------------------
  191. ; CUSTOM FUNCTION: HH SHOW MAIN MENU
  192. ; ------------------------------------------------------------------------------------------------------------
  193.  
  194. Function HH_ShowMainMenu()
  195. CurrentStatus = HH_Version.GetValue() ; Grab the current version number
  196. Int MainButtonPressed = HH_MenuMessage.Show(CurrentStatus) ; MAIN menu shows and waits for player response
  197.  
  198. If MainButtonPressed == 0 ; Main: Choose Random Location
  199. HH_ShowTheAnyMenu()
  200. ElseIf MainButtonPressed == 1 ; Main: Choose Specific Location
  201. HH_ShowTheSpecificMenu()
  202. ElseIf MainButtonPressed == 2 ; Main: DLC Destination Options
  203. HH_ShowDLCOptions()
  204. ElseIf MainButtonPressed == 3 ; Main: Force Time Now
  205. Int PrefTime = HH_OptionSetTimePreference.GetValue() as Int
  206. HHQuestScript.HH_ForceTime(PrefTime)
  207. ElseIf MainButtonPressed == 4 ; Main: Force Weather Now
  208. Int PrefWeather = HH_OptionSetWeatherPreference.GetValue() as Int
  209. HHQuestScript.HH_ForceWeather(PrefWeather)
  210. ElseIf MainButtonPressed == 5 ; Main: Spin Idle Camera Now
  211. HHQuestScript.HH_SpinCamera()
  212. ElseIf MainButtonPressed == 6 ; Main: Stop Idle Camera Now
  213. HHQuestScript.HH_StopSpinning()
  214. ElseIf MainButtonPressed == 7 ; Main: Camera Options
  215. HH_ShowCameraOptions()
  216. ElseIf MainButtonPressed == 8 ; Main: Teleport Options
  217. HH_ShowTeleportOptions()
  218. ElseIf MainButtonPressed == 9 ; Main: Enable Developer Messages
  219. HH_OptionDevTracking.SetValue(1)
  220. HH_ShowMainMenu()
  221. ElseIf MainButtonPressed == 10 ; Main: Disable Developer Messages
  222. HH_OptionDevTracking.SetValue(0)
  223. HH_ShowMainMenu()
  224. ElseIf MainButtonPressed == 11 ; Main: Restore Defaults
  225. HH_SetMenuDefaults()
  226. HH_ShowMainMenu()
  227. ElseIf MainButtonPressed == 12 ; Main: Exit Menu
  228. ; Exit Menu
  229. EndIf
  230. EndFunction
  231.  
  232. ; ------------------------------------------------------------------------------------------------------------
  233. ; CUSTOM FUNCTION: HH SHOW THE ANY MENU
  234. ; ------------------------------------------------------------------------------------------------------------
  235.  
  236. Function HH_ShowTheAnyMenu()
  237. Int Selected = HH_DestMessageAny.Show() ; ANY menu shows and waits for player response
  238.  
  239. If Selected == 0 ; If anywhere,
  240. Selected = Utility.RandomInt(1, 12) ; roll a category for player
  241. EndIf
  242.  
  243. If HH_OptionDevTracking.GetValue() as Int == 1
  244. Debug.TraceAndBox("Hitchhiker: Selected is " + Selected + ".")
  245. EndIf
  246.  
  247. If Selected > 0 && Selected <= 12
  248. HHQuestScript.HH_SetRandomDestination(Selected)
  249. Utility.WaitMenuMode(0.1)
  250. HHQuestScript.HH_StartHitching()
  251. Else
  252. HH_ShowMainMenu()
  253. EndIf
  254. EndFunction
  255.  
  256. ; ------------------------------------------------------------------------------------------------------------
  257. ; CUSTOM FUNCTION: HH SHOW THE SPECIFIC MENU
  258. ; ------------------------------------------------------------------------------------------------------------
  259.  
  260. Function HH_ShowTheSpecificMenu()
  261. Int SpecButtonPressed = HH_DestMessageSpecific.Show() ; SPEC menu shows and waits for player response
  262.  
  263. If SpecButtonPressed == 0
  264. HH_ShowMenuBusShelters()
  265. ElseIf SpecButtonPressed == 1
  266. HH_ShowMenuDiners1()
  267. ElseIf SpecButtonPressed == 2
  268. HH_ShowMenuDriveIns()
  269. ElseIf SpecButtonPressed == 3
  270. HH_ShowMenuDives()
  271. ElseIf SpecButtonPressed == 4
  272. HH_ShowMenuFactories()
  273. ElseIf SpecButtonPressed == 5
  274. HH_ShowMenuFarms()
  275. ElseIf SpecButtonPressed == 6
  276. HH_ShowMenuJunkyards1()
  277. ElseIf SpecButtonPressed == 7
  278. HH_ShowMenuMilitaryBases1()
  279. ElseIf SpecButtonPressed == 8
  280. HH_ShowMenuMonuments1()
  281. ElseIf SpecButtonPressed == 9
  282. HH_ShowMenuPowerLifts1()
  283. ElseIf SpecButtonPressed == 10
  284. HH_ShowMenuRedRocket1()
  285. ElseIf SpecButtonPressed == 11
  286. HH_ShowMenuVaults()
  287. Else
  288. HH_ShowMainMenu()
  289. EndIf
  290. EndFunction
  291.  
  292. ; ------------------------------------------------------------------------------------------------------------
  293. ; CUSTOM FUNCTION: HH SHOW MENU BUS SHELTERS
  294. ; ------------------------------------------------------------------------------------------------------------
  295.  
  296. Function HH_ShowMenuBusShelters()
  297. Int Selected = HH_DestMessageSpecificBusShelters.Show()
  298.  
  299. If Selected >= 0 && Selected <= 9
  300. HHQuestScript.HH_SetDestination(QuestRefBusShelters, Selected)
  301. Utility.WaitMenuMode(0.1)
  302. HHQuestScript.HH_StartHitching()
  303. Else
  304. HH_ShowTheSpecificMenu()
  305. EndIf
  306. EndFunction
  307.  
  308. ; ------------------------------------------------------------------------------------------------------------
  309. ; CUSTOM FUNCTION: HH SHOW MENU DINERS 1
  310. ; ------------------------------------------------------------------------------------------------------------
  311.  
  312. Function HH_ShowMenuDiners1()
  313. Int Selected = HH_DestMessageSpecificDiners1.Show()
  314.  
  315. If Selected >= 0 && Selected <= 9
  316. HHQuestScript.HH_SetDestination(QuestRefDiners, Selected)
  317. Utility.WaitMenuMode(0.1)
  318. HHQuestScript.HH_StartHitching()
  319. ElseIf Selected == 10
  320. HH_ShowMenuDiners2()
  321. Else
  322. HH_ShowTheSpecificMenu()
  323. EndIf
  324. EndFunction
  325.  
  326. ; ------------------------------------------------------------------------------------------------------------
  327. ; CUSTOM FUNCTION: HH SHOW MENU DINERS 2
  328. ; ------------------------------------------------------------------------------------------------------------
  329.  
  330. Function HH_ShowMenuDiners2()
  331. Int Selected = HH_DestMessageSpecificDiners2.Show()
  332.  
  333. If Selected >= 0 && Selected <= 9
  334. HHQuestScript.HH_SetDestination(QuestRefDiners, (Selected + 10))
  335. Utility.WaitMenuMode(0.1)
  336. HHQuestScript.HH_StartHitching()
  337. ElseIf Selected == 10
  338. HH_ShowMenuDiners3()
  339. Else
  340. HH_ShowMenuDiners1()
  341. EndIf
  342. EndFunction
  343.  
  344. ; ------------------------------------------------------------------------------------------------------------
  345. ; CUSTOM FUNCTION: HH SHOW MENU DINERS 3
  346. ; ------------------------------------------------------------------------------------------------------------
  347.  
  348. Function HH_ShowMenuDiners3()
  349. Int Selected = HH_DestMessageSpecificDiners3.Show()
  350.  
  351. If Selected >= 0 && Selected <= 9
  352. HHQuestScript.HH_SetDestination(QuestRefDiners, (Selected + 20))
  353. Utility.WaitMenuMode(0.1)
  354. HHQuestScript.HH_StartHitching()
  355. Else
  356. HH_ShowMenuDiners2()
  357. EndIf
  358. EndFunction
  359.  
  360. ; ------------------------------------------------------------------------------------------------------------
  361. ; CUSTOM FUNCTION: HH SHOW MENU DIVES
  362. ; ------------------------------------------------------------------------------------------------------------
  363.  
  364. Function HH_ShowMenuDives()
  365. Int Selected = HH_DestMessageSpecificDives.Show()
  366.  
  367. If Selected >= 0 && Selected <= 12
  368. HHQuestScript.HH_SetDestination(QuestRefDives, Selected)
  369. Utility.WaitMenuMode(0.1)
  370. HHQuestScript.HH_StartHitching()
  371. Else
  372. HH_ShowTheSpecificMenu()
  373. EndIf
  374. EndFunction
  375.  
  376. ; ------------------------------------------------------------------------------------------------------------
  377. ; CUSTOM FUNCTION: HH SHOW MENU DRIVE INS
  378. ; ------------------------------------------------------------------------------------------------------------
  379.  
  380. Function HH_ShowMenuDriveIns()
  381. Int Selected = HH_DestMessageSpecificDriveIns.Show()
  382.  
  383. If Selected >= 0 && Selected <= 11
  384. HHQuestScript.HH_SetDestination(QuestRefDriveIns, Selected)
  385. Utility.WaitMenuMode(0.1)
  386. HHQuestScript.HH_StartHitching()
  387. Else
  388. HH_ShowTheSpecificMenu()
  389. EndIf
  390. EndFunction
  391.  
  392. ; ------------------------------------------------------------------------------------------------------------
  393. ; CUSTOM FUNCTION: HH SHOW MENU FACTORIES
  394. ; ------------------------------------------------------------------------------------------------------------
  395.  
  396. Function HH_ShowMenuFactories()
  397. Int Selected = HH_DestMessageSpecificFactories.Show()
  398.  
  399. If Selected >= 0 && Selected <= 11
  400. HHQuestScript.HH_SetDestination(QuestRefFactories, Selected)
  401. Utility.WaitMenuMode(0.1)
  402. HHQuestScript.HH_StartHitching()
  403. Else
  404. HH_ShowTheSpecificMenu()
  405. EndIf
  406. EndFunction
  407.  
  408. ; ------------------------------------------------------------------------------------------------------------
  409. ; CUSTOM FUNCTION: HH SHOW MENU FARMS
  410. ; ------------------------------------------------------------------------------------------------------------
  411.  
  412. Function HH_ShowMenuFarms()
  413. Int Selected = HH_DestMessageSpecificFarms.Show()
  414.  
  415. If Selected >= 0 && Selected <= 11
  416. HHQuestScript.HH_SetDestination(QuestRefFarms, Selected)
  417. Utility.WaitMenuMode(0.1)
  418. HHQuestScript.HH_StartHitching()
  419. Else
  420. HH_ShowTheSpecificMenu()
  421. EndIf
  422. EndFunction
  423.  
  424. ; ------------------------------------------------------------------------------------------------------------
  425. ; CUSTOM FUNCTION: HH SHOW MENU JUNKYARDS 1
  426. ; ------------------------------------------------------------------------------------------------------------
  427.  
  428. Function HH_ShowMenuJunkyards1()
  429. Int Selected = HH_DestMessageSpecificJunkyards1.Show()
  430.  
  431. If Selected >= 0 && Selected <= 9
  432. HHQuestScript.HH_SetDestination(QuestRefJunkyards, Selected)
  433. Utility.WaitMenuMode(0.1)
  434. HHQuestScript.HH_StartHitching()
  435. ElseIf Selected == 10
  436. HH_ShowMenuJunkyards2()
  437. Else
  438. HH_ShowTheSpecificMenu()
  439. EndIf
  440. EndFunction
  441.  
  442. ; ------------------------------------------------------------------------------------------------------------
  443. ; CUSTOM FUNCTION: HH SHOW MENU JUNKYARDS 2
  444. ; ------------------------------------------------------------------------------------------------------------
  445.  
  446. Function HH_ShowMenuJunkyards2()
  447. Int Selected = HH_DestMessageSpecificJunkyards2.Show()
  448.  
  449. If Selected >= 0 && Selected <= 9
  450. HHQuestScript.HH_SetDestination(QuestRefJunkyards, (Selected + 10))
  451. Utility.WaitMenuMode(0.1)
  452. HHQuestScript.HH_StartHitching()
  453. Else
  454. HH_ShowMenuJunkyards1()
  455. EndIf
  456. EndFunction
  457.  
  458. ; ------------------------------------------------------------------------------------------------------------
  459. ; CUSTOM FUNCTION: HH SHOW MENU MILITARY BASES 1
  460. ; ------------------------------------------------------------------------------------------------------------
  461.  
  462. Function HH_ShowMenuMilitaryBases1()
  463. Int Selected = HH_DestMessageSpecificMilitaryBases1.Show()
  464.  
  465. If Selected >= 0 && Selected <= 9
  466. HHQuestScript.HH_SetDestination(QuestRefMilitaryBases, Selected)
  467. Utility.WaitMenuMode(0.1)
  468. HHQuestScript.HH_StartHitching()
  469. ElseIf Selected == 10
  470. HH_ShowMenuMilitaryBases2()
  471. Else
  472. HH_ShowTheSpecificMenu()
  473. EndIf
  474. EndFunction
  475.  
  476. ; ------------------------------------------------------------------------------------------------------------
  477. ; CUSTOM FUNCTION: HH SHOW MENU MILITARY BASES 2
  478. ; ------------------------------------------------------------------------------------------------------------
  479.  
  480. Function HH_ShowMenuMilitaryBases2()
  481. Int Selected = HH_DestMessageSpecificMilitaryBases2.Show()
  482.  
  483. If Selected >= 0 && Selected <= 9
  484. HHQuestScript.HH_SetDestination(QuestRefMilitaryBases, (Selected + 10))
  485. Utility.WaitMenuMode(0.1)
  486. HHQuestScript.HH_StartHitching()
  487. Else
  488. HH_ShowMenuMilitaryBases1()
  489. EndIf
  490. EndFunction
  491.  
  492. ; ------------------------------------------------------------------------------------------------------------
  493. ; CUSTOM FUNCTION: HH SHOW MENU MONUMENTS 1
  494. ; ------------------------------------------------------------------------------------------------------------
  495.  
  496. Function HH_ShowMenuMonuments1()
  497. Int Selected = HH_DestMessageSpecificMonuments1.Show()
  498.  
  499. If Selected >= 0 && Selected <= 9
  500. HHQuestScript.HH_SetDestination(QuestRefMonuments, Selected)
  501. Utility.WaitMenuMode(0.1)
  502. HHQuestScript.HH_StartHitching()
  503. ElseIf Selected == 10
  504. HH_ShowMenuMonuments2()
  505. Else
  506. HH_ShowTheSpecificMenu()
  507. EndIf
  508. EndFunction
  509.  
  510. ; ------------------------------------------------------------------------------------------------------------
  511. ; CUSTOM FUNCTION: HH SHOW MENU MONUMENTS 2
  512. ; ------------------------------------------------------------------------------------------------------------
  513.  
  514. Function HH_ShowMenuMonuments2()
  515. Int Selected = HH_DestMessageSpecificMonuments2.Show()
  516.  
  517. If Selected >= 0 && Selected <= 9
  518. HHQuestScript.HH_SetDestination(QuestRefMonuments, (Selected + 10))
  519. Utility.WaitMenuMode(0.1)
  520. HHQuestScript.HH_StartHitching()
  521. ElseIf Selected == 10
  522. HH_ShowMenuMonuments3()
  523. Else
  524. HH_ShowMenuMonuments1()
  525. EndIf
  526. EndFunction
  527.  
  528. ; ------------------------------------------------------------------------------------------------------------
  529. ; CUSTOM FUNCTION: HH SHOW MENU MONUMENTS 3
  530. ; ------------------------------------------------------------------------------------------------------------
  531.  
  532. Function HH_ShowMenuMonuments3()
  533. Int Selected = HH_DestMessageSpecificMonuments3.Show()
  534.  
  535. If Selected >= 0 && Selected <= 9
  536. HHQuestScript.HH_SetDestination(QuestRefMonuments, (Selected + 20))
  537. Utility.WaitMenuMode(0.1)
  538. HHQuestScript.HH_StartHitching()
  539. Else
  540. HH_ShowMenuMonuments2()
  541. EndIf
  542. EndFunction
  543.  
  544. ; ------------------------------------------------------------------------------------------------------------
  545. ; CUSTOM FUNCTION: HH SHOW MENU POWER LIFTS 1
  546. ; ------------------------------------------------------------------------------------------------------------
  547.  
  548. Function HH_ShowMenuPowerLifts1()
  549. ; Power lifts are oldest part of file. Note the extra work because ABC order != AliasID order.
  550.  
  551. Int Selected = HH_DestMessageSpecificPowerLifts1.Show()
  552.  
  553. If Selected == 0
  554. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 11)
  555. ElseIf Selected == 1
  556. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 13)
  557. ElseIf Selected == 2
  558. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 14)
  559. ElseIf Selected == 3
  560. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 12)
  561. ElseIf Selected == 4
  562. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 4)
  563. ElseIf Selected == 5
  564. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 6)
  565. ElseIf Selected == 6
  566. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 5)
  567. ElseIf Selected == 7
  568. HH_ShowMenuPowerLifts2()
  569. Else
  570. HH_ShowTheSpecificMenu()
  571. EndIf
  572.  
  573. If Selected >= 0 && Selected <= 6
  574. Utility.WaitMenuMode(0.1)
  575. HHQuestScript.HH_StartHitching()
  576. EndIf
  577. EndFunction
  578.  
  579. ; ------------------------------------------------------------------------------------------------------------
  580. ; CUSTOM FUNCTION: HH SHOW MENU POWER LIFTS 2
  581. ; ------------------------------------------------------------------------------------------------------------
  582.  
  583. Function HH_ShowMenuPowerLifts2()
  584. ; Power lifts are oldest part of file. Note the extra work because ABC order != AliasID order.
  585.  
  586. Int Selected = HH_DestMessageSpecificPowerLifts2.Show()
  587.  
  588. If Selected == 0
  589. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 10)
  590. ElseIf Selected == 1
  591. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 1)
  592. ElseIf Selected == 2
  593. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 8)
  594. ElseIf Selected == 3
  595. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 9)
  596. ElseIf Selected == 4
  597. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 3)
  598. ElseIf Selected == 5
  599. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 7)
  600. ElseIf Selected == 6
  601. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 0)
  602. ElseIf Selected == 7
  603. HHQuestScript.HH_SetDestination(QuestRefPowerLifts, 2)
  604. Else
  605. HH_ShowMenuPowerLifts1()
  606. EndIf
  607.  
  608. If Selected >= 0 && Selected <= 7
  609. Utility.WaitMenuMode(0.1)
  610. HHQuestScript.HH_StartHitching()
  611. EndIf
  612. EndFunction
  613.  
  614. ; ------------------------------------------------------------------------------------------------------------
  615. ; CUSTOM FUNCTION: HH SHOW MENU RED ROCKET 1
  616. ; ------------------------------------------------------------------------------------------------------------
  617.  
  618. Function HH_ShowMenuRedRocket1()
  619. ; Red Rockets are oldest part of file. Note the extra work because ABC order != AliasID order.
  620.  
  621. Int Selected = HH_DestMessageSpecificRedRocket1.Show()
  622.  
  623. If Selected == 0
  624. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 16)
  625. ElseIf Selected == 1
  626. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 20)
  627. ElseIf Selected == 2
  628. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 0)
  629. ElseIf Selected == 3
  630. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 11)
  631. ElseIf Selected == 4
  632. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 9)
  633. ElseIf Selected == 5
  634. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 17)
  635. ElseIf Selected == 6
  636. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 5)
  637. ElseIf Selected == 7
  638. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 18)
  639. ElseIf Selected == 8
  640. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 8)
  641. ElseIf Selected == 9
  642. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 14)
  643. ElseIf Selected == 10
  644. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 1)
  645. ElseIf Selected == 11
  646. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 3)
  647. ElseIf Selected == 12
  648. HH_ShowMenuRedRocket2()
  649. Else
  650. HH_ShowTheSpecificMenu()
  651. EndIf
  652.  
  653. If Selected >= 0 && Selected <= 11
  654. Utility.WaitMenuMode(0.1)
  655. HHQuestScript.HH_StartHitching()
  656. EndIf
  657. EndFunction
  658.  
  659. ; ------------------------------------------------------------------------------------------------------------
  660. ; CUSTOM FUNCTION: HH SHOW MENU RED ROCKET 2
  661. ; ------------------------------------------------------------------------------------------------------------
  662.  
  663. Function HH_ShowMenuRedRocket2()
  664. ; Red Rockets are oldest part of file. Note the extra work because ABC order != AliasID order.
  665.  
  666. Int Selected = HH_DestMessageSpecificRedRocket2.Show()
  667.  
  668. If Selected == 0
  669. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 10)
  670. ElseIf Selected == 1
  671. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 2)
  672. ElseIf Selected == 2
  673. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 21)
  674. ElseIf Selected == 3
  675. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 22)
  676. ElseIf Selected == 4
  677. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 23)
  678. ElseIf Selected == 5
  679. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 12)
  680. ElseIf Selected == 6
  681. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 4)
  682. ElseIf Selected == 7
  683. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 19)
  684. ElseIf Selected == 8
  685. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 7)
  686. ElseIf Selected == 9
  687. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 24)
  688. ElseIf Selected == 10
  689. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 15)
  690. ElseIf Selected == 11
  691. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 6)
  692. ElseIf Selected == 12
  693. HHQuestScript.HH_SetDestination(QuestRefRedRocket, 13)
  694. Else
  695. HH_ShowMenuRedRocket1()
  696. EndIf
  697.  
  698. If Selected >= 0 && Selected <= 12
  699. Utility.WaitMenuMode(0.1)
  700. HHQuestScript.HH_StartHitching()
  701. EndIf
  702. EndFunction
  703.  
  704. ; ------------------------------------------------------------------------------------------------------------
  705. ; CUSTOM FUNCTION: HH SHOW MENU VAULTS
  706. ; ------------------------------------------------------------------------------------------------------------
  707.  
  708. Function HH_ShowMenuVaults()
  709. Int Selected = HH_DestMessageSpecificVaults.Show()
  710.  
  711. If Selected >= 0 && Selected <= 9
  712. HHQuestScript.HH_SetDestination(QuestRefVaults, Selected)
  713. Utility.WaitMenuMode(0.1)
  714. HHQuestScript.HH_StartHitching()
  715. Else
  716. HH_ShowTheSpecificMenu()
  717. EndIf
  718. EndFunction
  719.  
  720. ; ------------------------------------------------------------------------------------------------------------
  721. ; CUSTOM FUNCTION: HH SHOW DLC OPTIONS
  722. ; ------------------------------------------------------------------------------------------------------------
  723.  
  724. Function HH_ShowDLCOptions()
  725. Int DLCOptionsBP = HH_MenuMessageDLCOptions.Show() ; DLCOptions shows and waits for player response
  726.  
  727. If DLCOptionsBP == 0 ; DLCOptions: Disable All DLC Destinations
  728. HH_OptionExcludeDLC.SetValue(1)
  729. HH_OptionExcludeFH.SetValue(1)
  730. HH_OptionExcludeNW.SetValue(1)
  731. HH_OptionExcludeVT.SetValue(1)
  732. ElseIf DLCOptionsBP == 1 ; DLCOptions: Enable All DLC Destinations
  733. HH_OptionExcludeDLC.SetValue(0)
  734. HH_OptionExcludeFH.SetValue(0)
  735. HH_OptionExcludeNW.SetValue(0)
  736. HH_OptionExcludeVT.SetValue(0)
  737. ElseIf DLCOptionsBP == 2 ; DLCOptions: Disable Far Harbor Destinations
  738. HH_OptionExcludeFH.SetValue(1)
  739. ElseIf DLCOptionsBP == 3 ; DLCOptions: Enable Far Harbor Destinations
  740. HH_OptionExcludeFH.SetValue(0)
  741. ElseIf DLCOptionsBP == 4 ; DLCOptions: Disable Nuka-World Destinations
  742. HH_OptionExcludeNW.SetValue(1)
  743. ElseIf DLCOptionsBP == 5 ; DLCOptions: Enable Nuka-World Destinations
  744. HH_OptionExcludeNW.SetValue(0)
  745. ElseIf DLCOptionsBP == 6 ; DLCOptions: Disable Vault-Tec Destinations
  746. HH_OptionExcludeVT.SetValue(1)
  747. ElseIf DLCOptionsBP == 7 ; DLCOptions: Enable Vault-Tec Destinations
  748. HH_OptionExcludeVT.SetValue(0)
  749. ElseIf DLCOptionsBP == 8 ; DLCOptions: Back
  750. HH_ShowMainMenu()
  751. EndIf
  752.  
  753. If DLCOptionsBP >= 0 && DLCOptionsBP < 8 ; If player selected enable/disable button,
  754. HH_ShowDLCOptions() ; refresh the DLCOptions menu on screen
  755. EndIf
  756. EndFunction
  757.  
  758. ; ------------------------------------------------------------------------------------------------------------
  759. ; CUSTOM FUNCTION: HH SHOW CAMERA OPTIONS
  760. ; ------------------------------------------------------------------------------------------------------------
  761.  
  762. Function HH_ShowCameraOptions()
  763. Int CameraOptionsBP = HH_MenuMessageCameraOptions.Show() ; CameraOptions shows and waits for player response
  764.  
  765. If CameraOptionsBP == 0 ; CameraOptions: Disable Spin Camera
  766. HH_OptionSpinCamera.SetValue(0)
  767. ElseIf CameraOptionsBP == 1 ; CameraOptions: Enable Spin Camera
  768. HH_OptionSpinCamera.SetValue(1)
  769. ElseIf CameraOptionsBP == 2 ; CameraOptions: Disable Spin Ghost
  770. HH_OptionSpinGhost.SetValue(0)
  771. ElseIf CameraOptionsBP == 3 ; CameraOptions: Enable Spin Ghost
  772. HH_OptionSpinGhost.SetValue(1)
  773. ElseIf CameraOptionsBP == 4 ; CameraOptions: Set Camera Max Distance
  774. HH_ShowSetMax()
  775. ElseIf CameraOptionsBP == 5 ; CameraOptions: Set Camera Min Distance
  776. HH_ShowSetMin()
  777. ElseIf CameraOptionsBP == 6 ; CameraOptions: Set Spin Duration
  778. HH_ShowSetDuration()
  779. ElseIf CameraOptionsBP == 7 ; CameraOptions: Back
  780. HH_ShowMainMenu()
  781. EndIf
  782.  
  783. If CameraOptionsBP >= 0 && CameraOptionsBP < 4 ; If player selected enable/disable button,
  784. HH_ShowCameraOptions() ; refresh the CameraOptions menu on screen
  785. EndIf
  786. EndFunction
  787.  
  788. ; ------------------------------------------------------------------------------------------------------------
  789. ; CUSTOM FUNCTION: HH SHOW SET MAX
  790. ; ------------------------------------------------------------------------------------------------------------
  791.  
  792. Function HH_ShowSetMax()
  793. Float MaxNum
  794.  
  795. CurrentStatus = HH_OptionCamMaxDistance.GetValue()
  796. Int SetMaxBP = HH_MenuMessageSetMax.Show(CurrentStatus) ; SetMax shows and waits for player response
  797.  
  798. If SetMaxBP == 0 ; SetMax: 150 (vanilla default)
  799. MaxNum = 150
  800. ElseIf SetMaxBP == 1 ; SetMax: 200 (mod default)
  801. MaxNum = 200
  802. ElseIf SetMaxBP == 2 ; SetMax: 250
  803. MaxNum = 250
  804. ElseIf SetMaxBP == 3 ; SetMax: 500
  805. MaxNum = 500
  806. ElseIf SetMaxBP == 4 ; SetMax: 750
  807. MaxNum = 750
  808. ElseIf SetMaxBP == 5 ; SetMax: 1000
  809. MaxNum = 1000
  810. ElseIf SetMaxBP == 6 ; SetMax: Back
  811. HH_ShowCameraOptions()
  812. EndIf
  813.  
  814. If SetMaxBP < 6 ; If player selected a value,
  815. HH_OptionCamMaxDistance.SetValue(MaxNum) ; set camera max distance
  816. HH_ShowSetMax() ; and refresh the SetMax menu on screen
  817. EndIf
  818. EndFunction
  819.  
  820. ; ------------------------------------------------------------------------------------------------------------
  821. ; CUSTOM FUNCTION: HH SHOW SET MIN
  822. ; ------------------------------------------------------------------------------------------------------------
  823.  
  824. Function HH_ShowSetMin()
  825. Float MinNum
  826.  
  827. CurrentStatus = HH_OptionCamMinDistance.GetValue()
  828. Int SetMinBP = HH_MenuMessageSetMin.Show(CurrentStatus) ; SetMin shows and waits for player response
  829.  
  830. If SetMinBP == 0 ; SetMin: 0 (vanilla default)
  831. MinNum = 0
  832. ElseIf SetMinBP == 1 ; SetMin: 100 (mod default)
  833. MinNum = 100
  834. ElseIf SetMinBP == 2 ; SetMin: 150
  835. MinNum = 150
  836. ElseIf SetMinBP == 3 ; SetMin: 200
  837. MinNum = 200
  838. ElseIf SetMinBP == 4 ; SetMin: 250
  839. MinNum = 250
  840. ElseIf SetMinBP == 5 ; SetMin: 500
  841. MinNum = 500
  842. ElseIf SetMinBP == 6 ; SetMin: Back
  843. HH_ShowCameraOptions()
  844. EndIf
  845.  
  846. If SetMinBP < 6 ; If player selected a value,
  847. HH_OptionCamMinDistance.SetValue(MinNum) ; set camera min distance
  848. HH_ShowSetMin() ; and refresh the SetMin menu on screen
  849. EndIf
  850. EndFunction
  851.  
  852. ; ------------------------------------------------------------------------------------------------------------
  853. ; CUSTOM FUNCTION: HH SHOW SET DURATION
  854. ; ------------------------------------------------------------------------------------------------------------
  855.  
  856. Function HH_ShowSetDuration()
  857. Float MinNum
  858.  
  859. CurrentStatus = HH_OptionSpinDuration.GetValue()
  860. Int SetMinBP = HH_MenuMessageSetDuration.Show(CurrentStatus) ; SetDuration shows and waits for player response
  861.  
  862. If SetMinBP == 0 ; SetDuration: 10
  863. MinNum = 10
  864. ElseIf SetMinBP == 1 ; SetDuration: 15
  865. MinNum = 15
  866. ElseIf SetMinBP == 2 ; SetDuration: 20 (mod default)
  867. MinNum = 20
  868. ElseIf SetMinBP == 3 ; SetDuration: 25
  869. MinNum = 25
  870. ElseIf SetMinBP == 4 ; SetDuration: 30
  871. MinNum = 30
  872. ElseIf SetMinBP == 5 ; SetDuration: 60
  873. MinNum = 60
  874. ElseIf SetMinBP == 6 ; SetDuration: Back
  875. HH_ShowCameraOptions()
  876. EndIf
  877.  
  878. If SetMinBP < 6 ; If player selected a value,
  879. HH_OptionSpinDuration.SetValue(MinNum) ; set camera spin duration
  880. HH_ShowSetDuration() ; and refresh the SetDuration menu on screen
  881. EndIf
  882. EndFunction
  883.  
  884. ; ------------------------------------------------------------------------------------------------------------
  885. ; CUSTOM FUNCTION: HH SHOW TELEPORT OPTIONS
  886. ; ------------------------------------------------------------------------------------------------------------
  887.  
  888. Function HH_ShowTeleportOptions()
  889. Int TeleportOptionsBP = HH_MenuMessageTeleportOptions.Show() ; TeleportOptions shows and waits for player response
  890.  
  891. If TeleportOptionsBP == 0 ; TeleportOptions: Disable Auto Time Change
  892. HH_OptionSetTime.SetValue(0)
  893. ElseIf TeleportOptionsBP == 1 ; TeleportOptions: Enable Auto Time Change
  894. HH_OptionSetTime.SetValue(1)
  895. ElseIf TeleportOptionsBP == 2 ; TeleportOptions: Set Preferred Time
  896. HH_ShowSetTime()
  897. ElseIf TeleportOptionsBP == 3 ; TeleportOptions: Disable Auto Weather Change
  898. HH_OptionSetWeather.SetValue(0)
  899. ElseIf TeleportOptionsBP == 4 ; TeleportOptions: Enable Auto Weather Change
  900. HH_OptionSetWeather.SetValue(1)
  901. ElseIf TeleportOptionsBP == 5 ; TeleportOptions: Set Preferred Weather
  902. HH_ShowSetWeather()
  903. ElseIf TeleportOptionsBP == 6 ; TeleportOptions: Disable Heal On Teleport
  904. HH_OptionHeal.SetValue(0)
  905. ElseIf TeleportOptionsBP == 7 ; TeleportOptions: Enable Heal On Teleport
  906. HH_OptionHeal.SetValue(1)
  907. ElseIf TeleportOptionsBP == 8 ; TeleportOptions: Disable Loading Screens
  908. HH_OptionFastTravel.SetValue(0)
  909. ElseIf TeleportOptionsBP == 9 ; TeleportOptions: Enable Loading Screens
  910. HH_OptionFastTravel.SetValue(1)
  911. ElseIf TeleportOptionsBP == 10 ; TeleportOptions: Disable Spin Camera
  912. HH_OptionSpinCamera.SetValue(0)
  913. ElseIf TeleportOptionsBP == 11 ; TeleportOptions: Enable Spin Camera
  914. HH_OptionSpinCamera.SetValue(1)
  915. ElseIf TeleportOptionsBP == 12 ; TeleportOptions: Disable Teleport Sounds
  916. HH_OptionTeleportSound.SetValue(0)
  917. ElseIf TeleportOptionsBP == 13 ; TeleportOptions: Enable Teleport Sounds
  918. HH_OptionTeleportSound.SetValue(1)
  919. ElseIf TeleportOptionsBP == 14 ; TeleportOptions: Advanced Options
  920. HH_ShowAdvancedOptions()
  921. ElseIf TeleportOptionsBP == 15 ; TeleportOptions: Back
  922. HH_ShowMainMenu()
  923. EndIf
  924.  
  925. If TeleportOptionsBP >= 0 && TeleportOptionsBP < 14 ; If player selected enable/disable button,
  926. If TeleportOptionsBP == 2 || TeleportOptionsBP == 5
  927. ; do not refresh submenu choices
  928. Else
  929. HH_ShowTeleportOptions() ; refresh the TeleportOptions menu on screen
  930. EndIf
  931. EndIf
  932. EndFunction
  933.  
  934. ; ------------------------------------------------------------------------------------------------------------
  935. ; CUSTOM FUNCTION: HH SHOW SET TIME
  936. ; ------------------------------------------------------------------------------------------------------------
  937.  
  938. Function HH_ShowSetTime()
  939. Float PrefTime
  940.  
  941. CurrentStatus = HH_OptionSetTimePreference.GetValue()
  942. Int SetTimeBP = HH_MenuMessageSetTime.Show(CurrentStatus) ; SetTime shows and waits for player response
  943.  
  944. If SetTimeBP == 0 ; SetTime: 3 AM
  945. PrefTime = 3
  946. ElseIf SetTimeBP == 1 ; SetTime: 6 AM
  947. PrefTime = 6
  948. ElseIf SetTimeBP == 2 ; SetTime: 9 AM
  949. PrefTime = 9
  950. ElseIf SetTimeBP == 3 ; SetTime: Noon
  951. PrefTime = 12
  952. ElseIf SetTimeBP == 4 ; SetTime: 3 PM
  953. PrefTime = 15
  954. ElseIf SetTimeBP == 5 ; SetTime: 6 PM
  955. PrefTime = 18
  956. ElseIf SetTimeBP == 6 ; SetTime: 9 PM
  957. PrefTime = 21
  958. ElseIf SetTimeBP == 7 ; SetTime: Midnight
  959. PrefTime = 24
  960. ElseIf SetTimeBP == 8 ; SetTime: Back
  961. HH_ShowTeleportOptions()
  962. EndIf
  963.  
  964. If SetTimeBP < 8 ; If player selected a value,
  965. HH_OptionSetTimePreference.SetValue(PrefTime) ; set preferred time
  966. HH_ShowSetTime() ; and refresh the SetTime menu on screen
  967. EndIf
  968. EndFunction
  969.  
  970. ; ------------------------------------------------------------------------------------------------------------
  971. ; CUSTOM FUNCTION: HH SHOW SET WEATHER
  972. ; ------------------------------------------------------------------------------------------------------------
  973.  
  974. Function HH_ShowSetWeather()
  975. Float PrefWeather
  976.  
  977. CurrentStatus = HH_OptionSetWeatherPreference.GetValue()
  978. Int SetWeatherBP = HH_MenuMessageSetWeather.Show(CurrentStatus) ; SetWeather shows and waits for player response
  979.  
  980. If SetWeatherBP == 0 ; SetWeather: CommonwealthClear
  981. PrefWeather = 1
  982. ElseIf SetWeatherBP == 1 ; SetWeather: CommonwealthDusty
  983. PrefWeather = 2
  984. ElseIf SetWeatherBP == 2 ; SetWeather: CommonwealthFoggy
  985. PrefWeather = 3
  986. ElseIf SetWeatherBP == 3 ; SetWeather: CommonwealthMisty
  987. PrefWeather = 4
  988. ElseIf SetWeatherBP == 4 ; SetWeather: CommonwealthMistyRainy
  989. PrefWeather = 5
  990. ElseIf SetWeatherBP == 5 ; SetWeather: CommonwealthOvercast
  991. PrefWeather = 6
  992. ElseIf SetWeatherBP == 6 ; SetWeather: CommonwealthGSRadstorm
  993. PrefWeather = 7
  994. ElseIf SetWeatherBP == 7 ; SetWeather: CommonwealthRain
  995. PrefWeather = 8
  996. ElseIf SetWeatherBP == 8 ; SetWeather: Back
  997. HH_ShowTeleportOptions()
  998. EndIf
  999.  
  1000. If SetWeatherBP < 8 ; If player selected a value,
  1001. HH_OptionSetWeatherPreference.SetValue(PrefWeather) ; set preferred weather
  1002. HH_ShowSetWeather() ; and refresh the SetWeather menu on screen
  1003. EndIf
  1004. EndFunction
  1005.  
  1006. ; ------------------------------------------------------------------------------------------------------------
  1007. ; CUSTOM FUNCTION: HH SHOW ADVANCED OPTIONS
  1008. ; ------------------------------------------------------------------------------------------------------------
  1009.  
  1010. Function HH_ShowAdvancedOptions()
  1011. Int AdvancedOptionsBP = HH_MenuMessageAdvancedOptions.Show() ; AdvancedOptions shows and waits for player response
  1012.  
  1013. If AdvancedOptionsBP == 0 ; AdvancedOptions: Set X Offset
  1014. HH_ShowSetX()
  1015. ElseIf AdvancedOptionsBP == 1 ; AdvancedOptions: Set Y Offset
  1016. HH_ShowSetY()
  1017. ElseIf AdvancedOptionsBP == 2 ; AdvancedOptions: Set Z Offset
  1018. HH_ShowSetZ()
  1019. ElseIf AdvancedOptionsBP == 3 ; AdvancedOptions: Back
  1020. HH_ShowTeleportOptions()
  1021. EndIf
  1022. EndFunction
  1023.  
  1024. ; ------------------------------------------------------------------------------------------------------------
  1025. ; CUSTOM FUNCTION: HH SHOW SET X
  1026. ; ------------------------------------------------------------------------------------------------------------
  1027.  
  1028. Function HH_ShowSetX()
  1029. Float MinNum
  1030.  
  1031. CurrentStatus = HH_OptionOffsetX.GetValue()
  1032. Int SetX = HH_MenuMessageSetX.Show(CurrentStatus) ; SetX shows and waits for player response
  1033.  
  1034. If SetX == 0 ; SetX: 0
  1035. MinNum = 0
  1036. ElseIf SetX == 1 ; SetX: 100
  1037. MinNum = 100
  1038. ElseIf SetX == 2 ; SetX: 250 (mod default)
  1039. MinNum = 250
  1040. ElseIf SetX == 3 ; SetX: 500
  1041. MinNum = 500
  1042. ElseIf SetX == 4 ; SetX: 750
  1043. MinNum = 750
  1044. ElseIf SetX == 5 ; SetX: 1000
  1045. MinNum = 1000
  1046. ElseIf SetX == 6 ; SetX: Back
  1047. HH_ShowAdvancedOptions()
  1048. EndIf
  1049.  
  1050. If SetX < 6 ; If player selected a value,
  1051. HH_OptionOffsetX.SetValue(MinNum) ; set X offset
  1052. HH_ShowSetX() ; and refresh the SetX menu on screen
  1053. EndIf
  1054. EndFunction
  1055.  
  1056. ; ------------------------------------------------------------------------------------------------------------
  1057. ; CUSTOM FUNCTION: HH SHOW SET Y
  1058. ; ------------------------------------------------------------------------------------------------------------
  1059.  
  1060. Function HH_ShowSetY()
  1061. Float MinNum
  1062.  
  1063. CurrentStatus = HH_OptionOffsetY.GetValue()
  1064. Int SetY = HH_MenuMessageSetY.Show(CurrentStatus) ; SetY shows and waits for player response
  1065.  
  1066. If SetY == 0 ; SetY: 0
  1067. MinNum = 0
  1068. ElseIf SetY == 1 ; SetY: 100
  1069. MinNum = 100
  1070. ElseIf SetY == 2 ; SetY: 250 (mod default)
  1071. MinNum = 250
  1072. ElseIf SetY == 3 ; SetY: 500
  1073. MinNum = 500
  1074. ElseIf SetY == 4 ; SetY: 750
  1075. MinNum = 750
  1076. ElseIf SetY == 5 ; SetY: 1000
  1077. MinNum = 1000
  1078. ElseIf SetY == 6 ; SetY: Back
  1079. HH_ShowAdvancedOptions()
  1080. EndIf
  1081.  
  1082. If SetY < 6 ; If player selected a value,
  1083. HH_OptionOffsetY.SetValue(MinNum) ; set Y offset
  1084. HH_ShowSetY() ; and refresh the SetY menu on screen
  1085. EndIf
  1086. EndFunction
  1087.  
  1088. ; ------------------------------------------------------------------------------------------------------------
  1089. ; CUSTOM FUNCTION: HH SHOW SET Z
  1090. ; ------------------------------------------------------------------------------------------------------------
  1091.  
  1092. Function HH_ShowSetZ()
  1093. Float MinNum
  1094.  
  1095. CurrentStatus = HH_OptionOffsetZ.GetValue()
  1096. Int SetZ = HH_MenuMessageSetZ.Show(CurrentStatus) ; SetZ shows and waits for player response
  1097.  
  1098. If SetZ == 0 ; SetZ: 0
  1099. MinNum = 0
  1100. ElseIf SetZ == 1 ; SetZ: 100
  1101. MinNum = 100
  1102. ElseIf SetZ == 2 ; SetZ: 250
  1103. MinNum = 250
  1104. ElseIf SetZ == 3 ; SetZ: 500 (mod default)
  1105. MinNum = 500
  1106. ElseIf SetZ == 4 ; SetZ: 750
  1107. MinNum = 750
  1108. ElseIf SetZ == 5 ; SetZ: 1000
  1109. MinNum = 1000
  1110. ElseIf SetZ == 6 ; SetZ: Back
  1111. HH_ShowAdvancedOptions()
  1112. EndIf
  1113.  
  1114. If SetZ < 6 ; If player selected a value,
  1115. HH_OptionOffsetZ.SetValue(MinNum) ; set Z offset
  1116. HH_ShowSetZ() ; and refresh the SetZ menu on screen
  1117. EndIf
  1118. EndFunction
  1119.  
  1120. ; ------------------------------------------------------------------------------------------------------------
  1121. ; CUSTOM FUNCTION: HH SET MENU DEFAULTS
  1122. ; ------------------------------------------------------------------------------------------------------------
  1123.  
  1124. Function HH_SetMenuDefaults()
  1125. HH_OptionCamMaxDistance.SetValue(200)
  1126. HH_OptionCamMinDistance.SetValue(100)
  1127. HH_OptionDevTracking.SetValue(0)
  1128. HH_OptionExcludeDLC.SetValue(0)
  1129. HH_OptionExcludeFH.SetValue(0)
  1130. HH_OptionExcludeNW.SetValue(0)
  1131. HH_OptionExcludeVT.SetValue(0)
  1132. HH_OptionFastTravel.SetValue(1)
  1133. HH_OptionOffsetX.SetValue(250)
  1134. HH_OptionOffsetY.SetValue(250)
  1135. HH_OptionOffsetZ.SetValue(500)
  1136. HH_OptionSetTime.SetValue(0)
  1137. HH_OptionSetTimePreference.SetValue(9)
  1138. HH_OptionSetWeather.SetValue(0)
  1139. HH_OptionSetWeatherPreference.SetValue(1)
  1140. HH_OptionSitFurniture.SetValue(1)
  1141. HH_OptionSpinCamera.SetValue(1)
  1142. HH_OptionSpinDuration.SetValue(20)
  1143. HH_OptionSpinGhost.SetValue(1)
  1144. HH_OptionHeal.SetValue(0)
  1145. HH_OptionTeleportSound.SetValue(1)
  1146. EndFunction
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement