Account
News
Downloads
Community
Wiki
Walkthrough

WabbajackCreatureScript

Editor ID:
WabbajackCreatureScript


Form ID:
00026D85


Typ:
Objekt


Script:
scn WabbajackCreatureScript

short doOnce
float timer
short done

ref originalRef
ref me

short dead

begin OnLoad
if doOnce == 0 && GetSelf != 0
set me to GetSelf
set DAWabbajack.replacement to me
set originalRef to DAWabbajack.target
originalRef.disable
; messageBox "Setting replacement: %.0f", me
pme STRP
playsound SPLConjurationCast
set doOnce to 1
endif
end

begin gamemode
if done == 0
set timer to timer + getsecondspassed
if timer > 10
set DAWabbajack.spellRunning to 2
set done to 1
endif
endif

if ( dead == 0 )
if ( GetDead == 1 )
set dead to 1
; if Wabbajack creature dies, disable and replace with original (dead) creature
set originalRef to DAWabbajack.target
set me to GetSelf
originalRef.kill player
originalRef.enable
originalRef.moveto me
disable
return
endif
endif

end

;begin OnDeath player
; ; if Wabbajack creature dies, disable and replace with original (dead) creature
; set originalRef to DAWabbajack.target
; set me to GetSelf
; originalRef.kill player
; originalRef.enable
; originalRef.moveto me
; disable
; return ; don't go to generic onDeath block. Only difference is there we don't tell it that the player killed it.
;end

;begin OnDeath
; ; if Wabbajack creature dies, disable and replace with original (dead) creature
; set originalRef to DAWabbajack.target
; set me to GetSelf
; originalRef.kill
; originalRef.enable
; originalRef.moveto me
; disable
; return
;end


Mit der Nutzung dieser Website erklären Sie sich damit einverstanden, dass wir Cookies verwenden. Weitere Informationen hierzu finden Sie in unserer Datenschutzerklärung.
OK