Advertisement
ThoraldGM

Safe Settlements

Jul 4th, 2016
277
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.49 KB | None | 0 0
  1.  
  2. ; SCAVVER MOD BY @THORALDGM | THORALDGM AT GMAIL.COM | SCRIPT UPDATED 20160704
  3.  
  4. ; -----------------------------------------------------------------------------------------------------------
  5. ; FUNCTION: END MY TRAVEL PACKAGE
  6. ; -----------------------------------------------------------------------------------------------------------
  7.  
  8. Function EndMyTravelPackage()
  9. pgvScavverIsRelocating.SetValue(0) ; Scavver is no longer relocating
  10. pgvScavverRelocated.SetValue(1) ; Scavver finished relocating
  11.  
  12. Int CurrentMarker = pgvScavverCurrentMarker.GetValue() as Int
  13. ObjectReference FoundWorkbench = Game.FindClosestReferenceOfAnyTypeInListFromRef(pScavverWorkbenchList, arScavMarkers[CurrentMarker], 10000)
  14.  
  15. Int[] DontLoot = new Int[7]
  16.  
  17. If FoundWorkbench
  18. If pgvScavverStatusSniffer.GetValue() == 1
  19. Debug.Notification("Scavver destination near workbench.")
  20. EndIf
  21.  
  22. pgvScavverDoNotLootHere.SetValue(1) ; just visiting or move along
  23. EndIf
  24.  
  25. DontLoot[0] = 0 ; Vault111Ext
  26. DontLoot[1] = 1 ; Sanctuary
  27. DontLoot[2] = 2 ; Minuteman Statue
  28. DontLoot[3] = 3 ; Concord / Red Rocket
  29. DontLoot[4] = 5 ; Drumlin / Carla's vendor chest?
  30. DontLoot[5] = 19 ; Tenpines Bluff
  31. DontLoot[6] = 22 ; Raider shack near 111
  32.  
  33. If DontLoot.Find(CurrentMarker) >= 0
  34. If pgvScavverStatusSniffer.GetValue() == 1
  35. Debug.Notification("Scavver is just visiting.")
  36. EndIf
  37.  
  38. pgvScavverDoNotLootHere.SetValue(1) ; just visiting or move along
  39. EndIf
  40.  
  41. If pgvScavverDoNotLootHere.GetValue() == 1
  42. pgvScavverLootedArea.SetValue(1) ; Flag destination as already looted
  43. Else
  44. pgvScavverLootedArea.SetValue(0) ; IMPORTANT! THIS IS THE MAIN SWEEP FLAG!
  45. EndIf
  46.  
  47. If pgvScavverIsHome.GetValue() == 1 ; If Scavver has arrived home,
  48. pScavverUtilityScript.BuildScavverSettlement() ; build next stage of settlement
  49. EndIf
  50.  
  51. pScavActor.EvaluatePackage(true) ; Forces package to end.
  52.  
  53. EndFunction
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement