1
Fork 0

Replaced GetActorRef() shortcuts

development
Eddoursul 5 months ago
parent 6f1abd6630
commit ba655e1df5
  1. BIN
      scripts/_00e_barddialoguefunctions.pex
  2. BIN
      scripts/_00e_dgintimidatealiasscript.pex
  3. BIN
      scripts/_00e_dgintimidateplayerscript.pex
  4. BIN
      scripts/_00e_nq10_functions.pex
  5. BIN
      scripts/_00e_nq_bounty01_targetscript.pex
  6. BIN
      scripts/_fs_phasmalist_controlquest.pex
  7. BIN
      scripts/dialoguefollowerscript.pex
  8. BIN
      scripts/qf__00e_nq06_freda_000725ba.pex
  9. BIN
      scripts/qf_bardstart_00149591.pex
  10. BIN
      scripts/qf_dgintimidatequest_0011a493.pex
  11. BIN
      scripts/sf__00e_genericdialogues_pri_0006ff3a.pex
  12. BIN
      scripts/sf_mq11c_sc7_ryneusraisesphe_00090bca.pex
  13. BIN
      scripts/tif__0012787d.pex
  14. 6
      source/scripts/_00e_barddialoguefunctions.psc
  15. 4
      source/scripts/_00e_dgintimidatealiasscript.psc
  16. 2
      source/scripts/_00e_dgintimidateplayerscript.psc
  17. 14
      source/scripts/_00e_nq10_functions.psc
  18. 2
      source/scripts/_00e_nq_bounty01_targetscript.psc
  19. 4
      source/scripts/_fs_phasmalist_controlquest.psc
  20. 16
      source/scripts/dialoguefollowerscript.psc
  21. 4
      source/scripts/qf__00e_nq06_freda_000725ba.psc
  22. 2
      source/scripts/qf_bardstart_00149591.psc
  23. 18
      source/scripts/qf_dgintimidatequest_0011a493.psc
  24. 2
      source/scripts/sf__00e_genericdialogues_pri_0006ff3a.psc
  25. 2
      source/scripts/sf_mq11c_sc7_ryneusraisesphe_00090bca.psc
  26. 4
      source/scripts/tif__0012787d.psc

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -108,7 +108,7 @@ Function CheerAudience() ; When a song ends normally, time for the audience to c
EndFunction EndFunction
Function OnSongEnd() ; When a song ends normally or is interrupted. Called from the scenes. Function OnSongEnd() ; When a song ends normally or is interrupted. Called from the scenes.
Actor akBard = SingingBard.GetActorRef() ; If akBard is None in OnSongEnd, most likely it's the player just left the cell and the quest is stopping Actor akBard = SingingBard.GetActorReference() ; If akBard is None in OnSongEnd, most likely it's the player just left the cell and the quest is stopping
Bool bLongDelay = False Bool bLongDelay = False
If akBard If akBard
akBard.PlayIdle(IdleStop) akBard.PlayIdle(IdleStop)
@ -154,7 +154,7 @@ Function PlayRequestedSong(Scene requestedSongScene)
EndFunction EndFunction
Event OnUpdate() Event OnUpdate()
Actor akBard = SingingBard.GetActorRef() Actor akBard = SingingBard.GetActorReference()
If akBard == None If akBard == None
Stop() Stop()
Return Return
@ -255,7 +255,7 @@ Function PickRandomSongFromSongList()
EndFunction EndFunction
Actor Function GetSingingBardActor() Actor Function GetSingingBardActor()
Return SingingBard.GetActorRef() Return SingingBard.GetActorReference()
EndFunction EndFunction
Bool Function IsQuestAudienceLocation() Bool Function IsQuestAudienceLocation()

@ -8,7 +8,7 @@ Faction Property DGIntimidateFaction Auto
;-- Functions --------------------------------------- ;-- Functions ---------------------------------------
Event OnUpdate() Event OnUpdate()
actor pActor = self.GetActorRef() actor pActor = self.GetActorReference()
if pActor.IsInCombat() == 0 && pActor.IsBleedingOut() == 0 && GetOwningQuest().GetStage() <= 15 ;&& GetOwningQuest().GetStage() < 15 if pActor.IsInCombat() == 0 && pActor.IsBleedingOut() == 0 && GetOwningQuest().GetStage() <= 15 ;&& GetOwningQuest().GetStage() < 15
GetOwningQuest().SetStage(200) GetOwningQuest().SetStage(200)
endIf endIf
@ -30,7 +30,7 @@ Event OnMagicEffectApply(ObjectReference akCaster, MagicEffect akEffect)
EndEvent EndEvent
Event OnHit(ObjectReference akAggressor, Form akWeapon, Projectile akProjectile, bool abPowerAttack, bool abSneakAttack, bool abBashAttack, bool abHitBlocked) Event OnHit(ObjectReference akAggressor, Form akWeapon, Projectile akProjectile, bool abPowerAttack, bool abSneakAttack, bool abBashAttack, bool abHitBlocked)
actor pActor = self.GetActorRef() actor pActor = self.GetActorReference()
actor pPlayer = game.GetPlayer() actor pPlayer = game.GetPlayer()
if akAggressor == pPlayer if akAggressor == pPlayer
if akProjectile || (akWeapon && akWeapon != UnarmedWeapon) if akProjectile || (akWeapon && akWeapon != UnarmedWeapon)

@ -25,7 +25,7 @@ Event OnEnterBleedout()
EndEvent EndEvent
Event OnLocationChange(Location akOldLoc, Location akNewLoc) Event OnLocationChange(Location akOldLoc, Location akNewLoc)
if GetPlayer().IsInLocation(Opponent.GetActorRef().GetCurrentLocation()) == False if GetPlayer().IsInLocation(Opponent.GetActorReference().GetCurrentLocation()) == False
; Debug.Trace(self + "Player has left opponent's location, shutting down") ; Debug.Trace(self + "Player has left opponent's location, shutting down")
GetOwningQuest().SetStage(200) GetOwningQuest().SetStage(200)
endIf endIf

@ -15,7 +15,7 @@ Event OnUpdateGameTime()
EndEvent EndEvent
Function SetupFinalScene() Function SetupFinalScene()
Actor akElfride = Alias_Elfride.GetActorRef() Actor akElfride = Alias_Elfride.GetActorReference()
If akElfride.IsDisabled() ; For backward compatibility If akElfride.IsDisabled() ; For backward compatibility
PutElfrideToCage() PutElfrideToCage()
_00E_QuestFunctions.WaitForReferenceToLoad(akElfride) _00E_QuestFunctions.WaitForReferenceToLoad(akElfride)
@ -25,15 +25,15 @@ Function SetupFinalScene()
_00E_NQ10_ElfriedeCageRef.SetOpen(True) _00E_NQ10_ElfriedeCageRef.SetOpen(True)
_00E_ElfriedeMoohMarker.Play(akElfride) _00E_ElfriedeMoohMarker.Play(akElfride)
Actor akEshra = Alias_Eshra.GetActorRef() Actor akEshra = Alias_Eshra.GetActorReference()
akEshra.MoveTo(EshraPortRef) akEshra.MoveTo(EshraPortRef)
Debug.SendAnimationEvent(akEshra, "IdleForceDefaultState") Debug.SendAnimationEvent(akEshra, "IdleForceDefaultState")
EndFunction EndFunction
Function FinishQuest() Function FinishQuest()
; Start end travel for Eshra ; Start end travel for Eshra
Actor akEshra = Alias_Eshra.GetActorRef() Actor akEshra = Alias_Eshra.GetActorReference()
_00E_QuestFunctions.DistanceFailsafeMoveTo(Alias_Elfride.GetActorRef(), akEshra, 256.0) _00E_QuestFunctions.DistanceFailsafeMoveTo(Alias_Elfride.GetActorReference(), akEshra, 256.0)
akEshra.SetActorValue("Variable01", 1.0) akEshra.SetActorValue("Variable01", 1.0)
RegisterForSingleUpdateGameTime(1.0) RegisterForSingleUpdateGameTime(1.0)
@ -45,7 +45,7 @@ Function FinishQuest()
EndFunction EndFunction
Function PutElfrideToCage() Function PutElfrideToCage()
Actor akElfride = Alias_Elfride.GetActorRef() Actor akElfride = Alias_Elfride.GetActorReference()
akElfride.SetFactionRank(NoFeedingIdleFaction, 0) akElfride.SetFactionRank(NoFeedingIdleFaction, 0)
akElfride.MoveToMyEditorLocation() ; Just in case akElfride.MoveToMyEditorLocation() ; Just in case
akElfride.Enable() akElfride.Enable()
@ -58,10 +58,10 @@ EndFunction
Function FinishEndTravel() Function FinishEndTravel()
UnregisterForUpdateGameTime() UnregisterForUpdateGameTime()
Actor akEshra = Alias_Eshra.GetActorRef() Actor akEshra = Alias_Eshra.GetActorReference()
akEshra.SetActorValue("Variable01", 0.0) akEshra.SetActorValue("Variable01", 0.0)
akEshra.EvaluatePackage() akEshra.EvaluatePackage()
Actor akElfride = Alias_Elfride.GetActorRef() Actor akElfride = Alias_Elfride.GetActorReference()
akElfride.RemoveFromFaction(NoFeedingIdleFaction) akElfride.RemoveFromFaction(NoFeedingIdleFaction)
EndFunction EndFunction

@ -40,7 +40,7 @@ Event OnCombatStateChanged(Actor akTarget, int aeCombatState)
If akTarget == PlayerRef || akTarget.IsPlayerTeammate() || akTarget.HasKeyword(_00E_PlayerSummonedCreature) || akTarget.GetFactionReaction(PlayerRef) == 2 || akTarget.HasEffectKeyword(BlameSpellKeyword) If akTarget == PlayerRef || akTarget.IsPlayerTeammate() || akTarget.HasKeyword(_00E_PlayerSummonedCreature) || akTarget.GetFactionReaction(PlayerRef) == 2 || akTarget.HasEffectKeyword(BlameSpellKeyword)
finished = True finished = True
GetActorRef().GetActorBase().SetEssential(False) GetActorReference().GetActorBase().SetEssential(False)
EndIf EndIf
EndIf EndIf
EndEvent EndEvent

@ -195,7 +195,7 @@ Bool Function IsBadApparitionLocation(Location loc)
EndFunction EndFunction
Actor Function GetApparitionRef() Actor Function GetApparitionRef()
Return NewApparitionAlias.GetActorRef() Return NewApparitionAlias.GetActorReference()
EndFunction EndFunction
Actor Function GetApparitionFailsafeRef() Actor Function GetApparitionFailsafeRef()
@ -206,7 +206,7 @@ Actor Function GetApparitionFailsafeRef()
EndFunction EndFunction
Bool Function IsApparitionSpawned() Bool Function IsApparitionSpawned()
If NewApparitionAlias.GetActorRef() If NewApparitionAlias.GetActorReference()
Return (CurrentSummonState != SUMMON_STATE_UNSUMMONING) ; It exists and is not being unsummoned Return (CurrentSummonState != SUMMON_STATE_UNSUMMONING) ; It exists and is not being unsummoned
Else Else
Return (CurrentSummonState == SUMMON_STATE_SUMMONING) ; It's not there yet but spawning Return (CurrentSummonState == SUMMON_STATE_SUMMONING) ; It's not there yet but spawning

@ -52,7 +52,7 @@ EndFunction
Function FollowerWait() Function FollowerWait()
actor FollowerActor = pFollowerAlias.GetActorRef() as Actor actor FollowerActor = pFollowerAlias.GetActorReference() as Actor
FollowerActor.SetActorValue("WaitingForPlayer", 1) FollowerActor.SetActorValue("WaitingForPlayer", 1)
;SetObjectiveDisplayed(10, abforce = true) ;SetObjectiveDisplayed(10, abforce = true)
;follower will wait 3 days ;follower will wait 3 days
@ -62,7 +62,7 @@ EndFunction
Function AnimalWait() Function AnimalWait()
actor AnimalActor = pAnimalAlias.GetActorRef() as Actor actor AnimalActor = pAnimalAlias.GetActorReference() as Actor
AnimalActor.SetActorValue("WaitingForPlayer", 1) AnimalActor.SetActorValue("WaitingForPlayer", 1)
;SetObjectiveDisplayed(20, abforce = true) ;SetObjectiveDisplayed(20, abforce = true)
;follower will wait 3 days ;follower will wait 3 days
@ -72,7 +72,7 @@ EndFunction
Function FollowerFollow() Function FollowerFollow()
actor FollowerActor = pFollowerAlias.GetActorRef() as Actor actor FollowerActor = pFollowerAlias.GetActorReference() as Actor
FollowerActor.SetActorValue("WaitingForPlayer", 0) FollowerActor.SetActorValue("WaitingForPlayer", 0)
SetObjectiveDisplayed(10, abdisplayed = false) SetObjectiveDisplayed(10, abdisplayed = false)
@ -80,7 +80,7 @@ EndFunction
Function AnimalFollow() Function AnimalFollow()
actor AnimalActor = pAnimalAlias.GetActorRef() as Actor actor AnimalActor = pAnimalAlias.GetActorReference() as Actor
AnimalActor.SetActorValue("WaitingForPlayer", 0) AnimalActor.SetActorValue("WaitingForPlayer", 0)
SetObjectiveDisplayed(20, abdisplayed = false) SetObjectiveDisplayed(20, abdisplayed = false)
@ -88,7 +88,7 @@ EndFunction
Function DismissFollower(Int iMessage = 0, Int iSayLine = 1) Function DismissFollower(Int iMessage = 0, Int iSayLine = 1)
If pFollowerAlias && pFollowerAlias.GetActorRef().IsDead() == False If pFollowerAlias && pFollowerAlias.GetActorReference().IsDead() == False
If iMessage == 0 If iMessage == 0
FollowerDismissMessage.Show() FollowerDismissMessage.Show()
ElseIf iMessage == 1 ElseIf iMessage == 1
@ -105,7 +105,7 @@ Function DismissFollower(Int iMessage = 0, Int iSayLine = 1)
;failsafe ;failsafe
FollowerDismissMessage.Show() FollowerDismissMessage.Show()
EndIf EndIf
actor DismissedFollowerActor = pFollowerAlias.GetActorRef() as Actor actor DismissedFollowerActor = pFollowerAlias.GetActorReference() as Actor
DismissedFollowerActor.StopCombatAlarm() DismissedFollowerActor.StopCombatAlarm()
DismissedFollowerActor.AddToFaction(pDismissedFollower) DismissedFollowerActor.AddToFaction(pDismissedFollower)
DismissedFollowerActor.SetPlayerTeammate(false) DismissedFollowerActor.SetPlayerTeammate(false)
@ -139,8 +139,8 @@ EndFunction
Function DismissAnimal() Function DismissAnimal()
If pAnimalAlias && pAnimalAlias.GetActorRef().IsDead() == False If pAnimalAlias && pAnimalAlias.GetActorReference().IsDead() == False
actor DismissedAnimalActor = pAnimalAlias.GetActorRef() as Actor actor DismissedAnimalActor = pAnimalAlias.GetActorReference() as Actor
DismissedAnimalActor.SetActorValue("Variable04", 0) DismissedAnimalActor.SetActorValue("Variable04", 0)
;DismissedAnimalActor.AllowPCDialogue(False) ;DismissedAnimalActor.AllowPCDialogue(False)
pPlayerAnimalCount.SetValue(0) pPlayerAnimalCount.SetValue(0)

@ -67,8 +67,8 @@ _00E_NQ06_Functions kmyQuest = __temp as _00E_NQ06_Functions
;END AUTOCAST ;END AUTOCAST
;BEGIN CODE ;BEGIN CODE
SetObjectiveCompleted(30) SetObjectiveCompleted(30)
Alias_Bonni.GetActorRef().SetFactionRank(PlayerHorseFaction, 1) Alias_Bonni.GetActorReference().SetFactionRank(PlayerHorseFaction, 1)
Alias_Bonni.GetActorRef().SetFactionOwner(PlayerFaction) Alias_Bonni.GetActorReference().SetFactionOwner(PlayerFaction)
kmyQuest.SetMuleName() kmyQuest.SetMuleName()
kmyQuest.AddHorseFlute() kmyQuest.AddHorseFlute()
If _00E_AchievementsEnabled.GetValueInt() == 1 If _00E_AchievementsEnabled.GetValueInt() == 1

@ -32,7 +32,7 @@ While BardDialogue.IsStopped() == False && iTimeoutCounter < 60
EndWhile EndWhile
; Start BardDialogue again (with the new bard) ; Start BardDialogue again (with the new bard)
Actor akBard = alias_Bard.GetActorRef() Actor akBard = alias_Bard.GetActorReference()
If akBard If akBard
BardDialogue.Start() BardDialogue.Start()
(BardDialogue as _00E_BardDialogueFunctions).Setup(akBard, lastSongScene) (BardDialogue as _00E_BardDialogueFunctions).Setup(akBard, lastSongScene)

@ -56,8 +56,8 @@ DGIntimidateQuestScript kmyQuest = __temp as DGIntimidateQuestScript
;BEGIN CODE ;BEGIN CODE
; Stage 10: Start ; Stage 10: Start
; fill the alias if this is CR04 and don't end quest if player fights dirty ; fill the alias if this is CR04 and don't end quest if player fights dirty
Actor OpponentREF = Alias_Opponent.GetActorRef() Actor OpponentREF = Alias_Opponent.GetActorReference()
Actor FriendREF = Alias_OpponentFriend.GetActorRef() Actor FriendREF = Alias_OpponentFriend.GetActorReference()
(Alias_Player as _00E_DGIntimidatePlayerScript).Setup() (Alias_Player as _00E_DGIntimidatePlayerScript).Setup()
@ -97,7 +97,7 @@ DGIntimidateQuestScript kmyQuest = __temp as DGIntimidateQuestScript
;END AUTOCAST ;END AUTOCAST
;BEGIN CODE ;BEGIN CODE
; Stage 20: forcegreet is done (never happens in Enderal) ; Stage 20: forcegreet is done (never happens in Enderal)
Alias_Opponent.GetActorRef().EvaluatePackage() Alias_Opponent.GetActorReference().EvaluatePackage()
;END CODE ;END CODE
EndFunction EndFunction
;END FRAGMENT ;END FRAGMENT
@ -110,8 +110,8 @@ DGIntimidateQuestScript kmyQuest = __temp as DGIntimidateQuestScript
;END AUTOCAST ;END AUTOCAST
;BEGIN CODE ;BEGIN CODE
; Stage 200: End quest (1st phase) ; Stage 200: End quest (1st phase)
Actor OpponentREF = Alias_Opponent.GetActorRef() Actor OpponentREF = Alias_Opponent.GetActorReference()
Actor OpponentFriendREF = Alias_OpponentFriend.GetActorRef() Actor OpponentFriendREF = Alias_OpponentFriend.GetActorReference()
Actor PlayerREF = Game.GetPlayer() Actor PlayerREF = Game.GetPlayer()
OpponentREF.AllowBleedoutDialogue(False) OpponentREF.AllowBleedoutDialogue(False)
@ -149,7 +149,7 @@ EndFunction
Function Fragment_9() Function Fragment_9()
;BEGIN CODE ;BEGIN CODE
; Stage 15: opponent is down, cue victory dialogue (victory dialogue does not happen in Enderal) ; Stage 15: opponent is down, cue victory dialogue (victory dialogue does not happen in Enderal)
Actor myOpponent = Alias_Opponent.GetActorRef() Actor myOpponent = Alias_Opponent.GetActorReference()
myOpponent.AllowBleedoutDialogue(True) myOpponent.AllowBleedoutDialogue(True)
Game.IncrementStat( "Brawls Won" ) Game.IncrementStat( "Brawls Won" )
;END CODE ;END CODE
@ -175,9 +175,9 @@ Function Fragment_14()
Game.GetPlayer().StopCombatAlarm() Game.GetPlayer().StopCombatAlarm()
;make sure player's hired hands don't aggro ;make sure player's hired hands don't aggro
Alias_Opponent.GetActorRef().StopCombatAlarm() Alias_Opponent.GetActorReference().StopCombatAlarm()
If Alias_OpponentFriend.GetActorRef() != None If Alias_OpponentFriend.GetActorReference() != None
Alias_OpponentFriend.GetActorRef().StopCombatAlarm() Alias_OpponentFriend.GetActorReference().StopCombatAlarm()
EndIf EndIf
;END CODE ;END CODE
EndFunction EndFunction

@ -23,7 +23,7 @@ EndFunction
;BEGIN FRAGMENT Fragment_2 ;BEGIN FRAGMENT Fragment_2
Function Fragment_2() Function Fragment_2()
;BEGIN CODE ;BEGIN CODE
Preacher.GetActorRef().PlayIdle(IdleStop_Loose) Preacher.GetActorReference().PlayIdle(IdleStop_Loose)
;END CODE ;END CODE
EndFunction EndFunction
;END FRAGMENT ;END FRAGMENT

@ -5,7 +5,7 @@ Scriptname SF_MQ11c_SC7_RyneusRaiseSphe_00090BCA Extends Scene Hidden
;BEGIN FRAGMENT Fragment_4 ;BEGIN FRAGMENT Fragment_4
Function Fragment_4() Function Fragment_4()
;BEGIN CODE ;BEGIN CODE
Alias_Ryneus.GetActorRef().SetLookAt(Alias_Sphere.GetRef()) Alias_Ryneus.GetActorReference().SetLookAt(Alias_Sphere.GetRef())
;END CODE ;END CODE
EndFunction EndFunction
;END FRAGMENT ;END FRAGMENT

@ -6,8 +6,8 @@ Scriptname TIF__0012787D Extends TopicInfo Hidden
Function Fragment_0(ObjectReference akSpeakerRef) Function Fragment_0(ObjectReference akSpeakerRef)
Actor akSpeaker = akSpeakerRef as Actor Actor akSpeaker = akSpeakerRef as Actor
;BEGIN CODE ;BEGIN CODE
PlayerHorseNew.GetActorRef().SetFactionRank(PlayerHorseFaction, 1) PlayerHorseNew.GetActorReference().SetFactionRank(PlayerHorseFaction, 1)
PlayerHorseNew.GetActorRef().SetFactionOwner(PlayerFaction) PlayerHorseNew.GetActorReference().SetFactionOwner(PlayerFaction)
game.IncrementStat( "Horses Owned" ) game.IncrementStat( "Horses Owned" )
Game.GetPlayer().RemoveItem(Gold001, 600) Game.GetPlayer().RemoveItem(Gold001, 600)
NQ06.SetHorseName() NQ06.SetHorseName()

Loading…
Cancel
Save