Having issues with restoring the Starting actor values:
When i call them them in a different script, they return as 0.
The areas I added to save the AVs and restore the AVs are in codeboxes within the spoilers (don't wanna explode the post now)
The first script:
The second script:
Int StartHealth
Int StartMagicka
Int StartStamina
Int StartOnehanded
Int StartTwohanded
Int StartMarksman
Int StartBlock
Int StartSmithing
Int StartHeavyArmor
Int StartLightArmor
Int StartPickpocket
Int StartLockpicking
Int StartSneak
Int StartAlchemy
Int StartSpeechcraft
Int StartAlteration
Int StartConjuration
Int StartDestruction
Int StartIllusion
Int StartRestoration
Int StartEnchanting
Game.GetPlayer().SetAV("health", StartHealth)
Game.GetPlayer().SetAV("magicka", StartMagicka)
Game.GetPlayer().SetAV("stamina", StartStamina)
Game.GetPlayer().SetAV("onehanded", StartOnehanded)
Game.GetPlayer().SetAV("twohanded", StartTwohanded)
Game.GetPlayer().SetAV("marksman", StartMarksman)
Game.GetPlayer().SetAV("block", StartBlock)
Game.GetPlayer().SetAV("smithing", StartSmithing)
Game.GetPlayer().SetAV("heavyarmor", StartHeavyArmor)
Game.GetPlayer().SetAV("lightarmor", StartLightArmor)
Game.GetPlayer().SetAV("pickpocket", StartPickpocket)
Game.GetPlayer().SetAV("lockpicking", StartLockpicking)
Game.GetPlayer().SetAV("sneak", StartSneak)
Game.GetPlayer().SetAV("alchemy", StartAlchemy)
Game.GetPlayer().SetAV("speechcraft", StartSpeechcraft)
Game.GetPlayer().SetAV("alteration", StartAlteration)
Game.GetPlayer().SetAV("conjuration", StartConjuration)
Game.GetPlayer().SetAV("destruction", StartDestruction)
Game.GetPlayer().SetAV("illusion", StartIllusion)
Game.GetPlayer().SetAV("restoration", StartRestoration)
Game.GetPlayer().SetAV("enchanting", StartEnchanting)
FullHeal.Cast(Game.GetPlayer())
Int RandomExit = Utility.RandomInt(0, 18) ;Assigning the random number to the variable "Random".
;The random number minimum and maximum.
if RandomExit == 1
Game.GetPlayer().MoveTo(SleepingGiant1)
Debug.MessageBox("You find yourself at The Sleeping Giant Inn")
elseif RandomExit == 2
Game.GetPlayer().MoveTo(BannerMare2)
Debug.MessageBox("You find yourself at The Bannered Mare")
elseif RandomExit == 3
Game.GetPlayer().MoveTo(Frostfruit3)
Debug.MessageBox("You find yourself at Frostfruit Inn")
elseif RandomExit == 4
Game.GetPlayer().MoveTo(DrunkenHuntsman4)
Debug.MessageBox("You find yourself at The Drunken Huntsman")
elseif RandomExit == 5
Game.GetPlayer().MoveTo(DeadMansDrink5)
Debug.MessageBox("You find yourself at Dead Man's Drink")
elseif RandomExit == 6
Game.GetPlayer().MoveTo(Braidwood6)
Debug.MessageBox("You find yourself at Braidwood Inn")
elseif RandomExit == 7
Game.GetPlayer().MoveTo(BeeBarb7)
Debug.MessageBox("You find yourself at The Bee and Barb")
elseif RandomExit == 8
Game.GetPlayer().MoveTo(VilemyrInn8)
Debug.MessageBox("You find yourself at Vilemyr Inn")
elseif RandomExit == 9
Game.GetPlayer().MoveTo(NewGnisis9)
Debug.MessageBox("You find yourself at New Gnisis Cornerclub")
elseif RandomExit == 10
Game.GetPlayer().MoveTo(SilverBlood10)
Debug.MessageBox("You find yourself at The Silver-Blood Inn")
elseif RandomExit == 11
Game.GetPlayer().MoveTo(OldHroldan11)
Debug.MessageBox("You find yourself at Old Hroldan Inn")
elseif RandomExit == 12
Game.GetPlayer().MoveTo(WinkingSkeever12)
Debug.MessageBox("You find yourself at The Winking Skeever")
elseif RandomExit == 13
Game.GetPlayer().MoveTo(FourShields13)
Debug.MessageBox("You find yourself at Four Shields Tavern")
elseif RandomExit == 14
Game.GetPlayer().MoveTo(Moorside14)
Debug.MessageBox("You find yourself at Moorside Inn")
elseif RandomExit == 15
Game.GetPlayer().MoveTo(Windpeak15)
Debug.MessageBox("You find yourself at Windpeak Inn")
elseif RandomExit == 16
Game.GetPlayer().MoveTo(Nightgate16)
Debug.MessageBox("You find yourself at Nightgate Inn")
elseif RandomExit == 17
Game.GetPlayer().MoveTo(FrozenHearth17)
Debug.MessageBox("You find yourself at The Frozen Hearth")
elseif RandomExit == 18
Game.GetPlayer().MoveTo(Candlehearth18)
Debug.MessageBox("You find yourself at Candlehearth Hall")
EndIf
elseif ReadBookAgain == 1
NoReturn.show()
endif
endif
endEVENT