Merged MQ12b update

This commit is contained in:
Eddoursul 2024-02-21 17:41:16 +01:00
parent fe9971362f
commit b410dd4e62
5 changed files with 8 additions and 6 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -27,8 +27,8 @@ Function PrepareNPC(Actor akMoveActor, Bool bOnlyGhost = False)
Return
EndIf
If bOnlyGhost == False && RegisteredDisabledNPCs.Find(akMoveActor) < 0
If akMoveActor.IsDisabled()
If bOnlyGhost == False
If RegisteredDisabledNPCs.Find(akMoveActor) >= 0 || akMoveActor.IsDisabled()
Return
EndIf
@ -54,9 +54,10 @@ Function PrepareNPC(Actor akMoveActor, Bool bOnlyGhost = False)
EndFunction
Function _RegisterDisabledNPC(Actor akMoveActor)
if nRegisteredDisabledNPCs + 1 <= 128
RegisteredDisabledNPCs[nRegisteredDisabledNPCs] = akMoveActor
int iSlot = nRegisteredDisabledNPCs
if iSlot + 1 <= 128
nRegisteredDisabledNPCs += 1
RegisteredDisabledNPCs[iSlot] = akMoveActor
Debug.Trace("Registered disabled " + akMoveActor.GetBaseObject().GetName() + " " + (akMoveActor as String))
else
; Added overflow to the ghosted
@ -65,9 +66,10 @@ Function _RegisterDisabledNPC(Actor akMoveActor)
EndFunction
Function _RegisterGhostedNPC(Actor akMoveActor)
if nRegisteredGhostedNPCs + 1 <= 128
RegisteredGhostedNPCs[nRegisteredGhostedNPCs] = akMoveActor
int iSlot = nRegisteredGhostedNPCs
if iSlot + 1 <= 128
nRegisteredGhostedNPCs += 1
RegisteredGhostedNPCs[iSlot] = akMoveActor
Debug.Trace("Registered ghosted " + akMoveActor.GetBaseObject().GetName() + " " + (akMoveActor as String))
else
; oh well