4
Fork 0

Merge branch 'development' into merging + added remaining gavrant's fixes

# Conflicts:
#	scripts/_00e_questfunctions.pex
#	source/scripts/_00e_questfunctions.psc
english-generic-dialogue
Eddoursul 3 years ago
parent 0eae024fce
commit bd6ebd82b7
  1. BIN
      GavrantFixes_210510.esp
  2. BIN
      meshes/actors/mammoth/character assets/skeleton_triceratops.nif
  3. BIN
      meshes/enderal/armor/common/mercenary/vanguardhelmetclosed_1.nif
  4. BIN
      meshes/enderal/armor/steelplatearmor/hounskull_bascinet.nif
  5. BIN
      scripts/_00e_apparitionfxscript.pex
  6. BIN
      scripts/_00e_bedscript.pex
  7. BIN
      scripts/_00e_blockactivationforplayer.pex
  8. BIN
      scripts/_00e_bonespiritcontrolscript.pex
  9. BIN
      scripts/_00e_class_openclassmenuscript.pex
  10. BIN
      scripts/_00e_class_perkscript.pex
  11. BIN
      scripts/_00e_cqc05_functions.pex
  12. BIN
      scripts/_00e_cqj05_functions.pex
  13. BIN
      scripts/_00e_frozenmescript.pex
  14. BIN
      scripts/_00e_fs_affinity_absoulcallersc.pex
  15. BIN
      scripts/_00e_fs_affinity_ghostblade_onattack.pex
  16. BIN
      scripts/_00e_fs_dreameatersc.pex
  17. BIN
      scripts/_00e_fs_nq07_dinnercontrolsc.pex
  18. BIN
      scripts/_00e_fs_nqr05_perversionsc.pex
  19. BIN
      scripts/_00e_fs_psychosissc.pex
  20. BIN
      scripts/_00e_fs_theriantrophist_allowtemptsc.pex
  21. BIN
      scripts/_00e_fs_voicedletterscript.pex
  22. BIN
      scripts/_00e_game_skillmenusc.pex
  23. BIN
      scripts/_00e_mq10a_functions.pex
  24. BIN
      scripts/_00e_mq12c_functions.pex
  25. BIN
      scripts/_00e_mq12c_harbirsiegesc.pex
  26. BIN
      scripts/_00e_mq13a_functions.pex
  27. BIN
      scripts/_00e_mq13a_grammophonesc.pex
  28. BIN
      scripts/_00e_nq_g_07_functions.pex
  29. BIN
      scripts/_00e_perkblutrauschffaimedscript.pex
  30. BIN
      scripts/_00e_phasmalist_newapparitionalias.pex
  31. BIN
      scripts/_00e_phasmalist_workbench.pex
  32. BIN
      scripts/_00e_questfunctions.pex
  33. BIN
      scripts/_00e_smokingpipescript.pex
  34. BIN
      scripts/_00e_theriantrophist_blockcraftingsc.pex
  35. BIN
      scripts/_00e_theriantrophist_wolfattributes.pex
  36. BIN
      scripts/_00e_weathercontrolscriptsc.pex
  37. BIN
      scripts/_60e_fs_mystical_thoughtimplosionsc.pex
  38. BIN
      scripts/_fs_phasmalist_controlquest.pex
  39. BIN
      scripts/frostslowfix.pex
  40. BIN
      scripts/fs_nq05_alchemyscript.pex
  41. BIN
      scripts/fs_nq07_alchemyscript.pex
  42. BIN
      scripts/fxwitchlightattachscript.pex
  43. 19
      source/scripts/_00e_bedscript.psc
  44. 4
      source/scripts/_00e_blockactivationforplayer.psc
  45. 4
      source/scripts/_00e_class_openclassmenuscript.psc
  46. 182
      source/scripts/_00e_class_perkscript.psc
  47. 11
      source/scripts/_00e_cqc05_functions.psc
  48. 7
      source/scripts/_00e_cqj05_functions.psc
  49. 207
      source/scripts/_00e_frozenmescript.psc
  50. 6
      source/scripts/_00e_fs_affinity_absoulcallersc.psc
  51. 1
      source/scripts/_00e_fs_affinity_ghostblade_onattack.psc
  52. 2
      source/scripts/_00e_fs_dreameatersc.psc
  53. 2
      source/scripts/_00e_fs_nq07_dinnercontrolsc.psc
  54. 6
      source/scripts/_00e_fs_nqr05_perversionsc.psc
  55. 38
      source/scripts/_00e_fs_psychosissc.psc
  56. 39
      source/scripts/_00e_fs_theriantrophist_allowtemptsc.psc
  57. 3
      source/scripts/_00e_game_skillmenusc.psc
  58. 3
      source/scripts/_00e_mq10a_functions.psc
  59. 3
      source/scripts/_00e_mq12c_functions.psc
  60. 11
      source/scripts/_00e_mq12c_harbirsiegesc.psc
  61. 9
      source/scripts/_00e_mq13a_functions.psc
  62. 124
      source/scripts/_00e_mq13a_grammophonesc.psc
  63. 5
      source/scripts/_00e_nq_g_07_functions.psc
  64. 5
      source/scripts/_00e_perkblutrauschffaimedscript.psc
  65. 167
      source/scripts/_00e_phasmalist_newapparitionalias.psc
  66. 118
      source/scripts/_00e_phasmalist_workbench.psc
  67. 11
      source/scripts/_00e_questfunctions.psc
  68. 8
      source/scripts/_00e_smokingpipescript.psc
  69. 37
      source/scripts/_00e_theriantrophist_blockcraftingsc.psc
  70. 6
      source/scripts/_00e_theriantrophist_wolfattributes.psc
  71. 16
      source/scripts/_00e_weathercontrolscriptsc.psc
  72. 55
      source/scripts/_60e_fs_mystical_thoughtimplosionsc.psc
  73. 9
      source/scripts/_fs_phasmalist_controlquest.psc
  74. 56
      source/scripts/frostslowfix.psc
  75. 31
      source/scripts/fs_nq05_alchemyscript.psc
  76. 28
      source/scripts/fs_nq07_alchemyscript.psc
  77. 52
      source/scripts/fxwitchlightattachscript.psc

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -1,23 +1,24 @@
Scriptname _00E_BedScript extends ObjectReference
{Magically bypasses the whole waiting/resting-system thingy}
Quest Property MQ14 Auto
Message Property _00E_MQ14_CantRestNowMessage Auto
Actor Property PlayerREF Auto
Bool bActivationBlocked = False
Event OnActivate(ObjectReference akActionRef)
If akActionRef == PlayerREF && _00E_PlayerhousingMaster.ReferenceCanBeActivated(Self) && bActivationBlocked == False
bActivationBlocked = True
if (akActionRef == PlayerREF)
if !(MQ14.GetStage() >= 20)
If MQ14.GetStage() < 20
Game.SetInChargen(False, False, False)
Self.Activate(PlayerREF, True)
Game.SetInChargen(False, True, False)
Else
_00E_MQ14_CantRestNowMessage.Show()
EndIf
endif
bActivationBlocked = False
EndIf
EndEvent
Actor Property PlayerREF Auto
Quest Property MQ14 Auto
Message Property _00E_MQ14_CantRestNowMessage Auto

@ -9,7 +9,9 @@ EndEvent
Event OnActivate(ObjectReference akActionRef)
If akActionRef == Game.GetPlayer() && Self.IsActivationBlocked()
_00E_BlockedMessage.Show()
If _00E_BlockedMessage
_00E_BlockedMessage.Show()
EndIf
Else
Self.Activate(akActionRef, True)
EndIf

@ -26,7 +26,7 @@ Event OnEffectStart(Actor TheTarget, Actor TheCaster)
Else
if !(PlayerREF.IsInLocation(_00E_ClassMenuLocation))
If _00E_Meditate_Allowed.GetValueInt() == 0
If PlayerREF.GetRace() == _00E_Theriantrophist_PlayerWerewolfRace || _00E_Meditate_Allowed.GetValueInt() == 0
_00E_Meditation_sCantMeditateNow.Show()
bDoSettleDownWait = False
ElseIf PlayerREF.IsInCombat()
@ -124,3 +124,5 @@ GlobalVariable Property _00E_Meditate_FirstPerson Auto
GlobalVariable Property _00E_Meditate_Allowed Auto
ReferenceAlias Property Player Auto
Race Property _00E_Theriantrophist_PlayerWerewolfRace Auto

@ -6,103 +6,101 @@ Import Game
; EVENTS
;=====================================================================================
Event onActivate(ObjectReference akActionRef)
Event OnActivate(ObjectReference akActionRef)
If akActionRef != PlayerREF
Return
EndIf
int iButton
GoToState("DoNothing")
iButton = __Config_DisplayMessage.Show()
Int iButton = __Config_DisplayMessage.Show()
If __Config_MultipleLevelsConfirm
__Config_MultipleLevels=true
__Config_MultipleLevels = True
EndIf
If (__Config_MultipleLevels) && !(__Config_MultipleLevelsTwoLevels)
If iButton < 3
If (__Config_TeachesTalent)
TeachTalent()
Elseif !(__Config_TeachesTalent)
If __Config_MultipleLevels
If __Config_MultipleLevelsTwoLevels
If iButton < 2
TeachPerk()
FinalizeUnlock()
Return
EndIf
Else ; __Config_MultipleLevelsTwoLevels == False
If iButton < 3
If __Config_TeachesTalent
TeachTalent()
Else
TeachPerk()
EndIf
FinalizeUnlock()
Return
EndIf
TalentPoints.SetValue(TalentPoints.GetValueInt() - 1)
PlayerREF.SetAV("dragonsouls", TalentPoints.GetValueInt())
PlayVisuals()
EndIf
ElseIf (__Config_MultipleLevels) && (__Config_MultipleLevelsTwoLevels)
If iButton < 2
TeachPerk()
TalentPoints.SetValue(TalentPoints.GetValueInt() - 1)
PlayerREF.SetAV("dragonsouls", TalentPoints.GetValueInt())
PlayVisuals()
EndIf
Elseif !__Config_MultipleLevels
Else ; __Config_MultipleLevels == False
If iButton == 0
PlayerREF.AddPerk(__Config_PerkToTeach1)
If __Config_QuestToStart != None
__Config_QuestToStart.Start()
EndIf
If ( AdditionalPerk )
PlayerREF.AddPerk(AdditionalPerk)
EndIf
If sendModEventOnUnlock
SendModEvent(modEventName)
Endif
TalentPoints.SetValue(TalentPoints.GetValueInt() - 1)
PlayerREF.SetAV("dragonsouls", TalentPoints.GetValueInt())
PlayVisuals()
TeachFirstPerk()
FinalizeUnlock()
Return
EndIf
EndIf
GoToState("")
EndEvent
State DoNothing
Event OnActivate(ObjectReference akActionRef)
; Do nothing
EndEvent
EndState
;=====================================================================================
; FUNCTIONS
;=====================================================================================
Function TeachPerk()
if !(PlayerREF.HasPerk(__Config_PerkToTeach1))
PlayerREF.AddPerk(__Config_PerkToTeach1)
If __Config_QuestToStart != None
__Config_QuestToStart.start()
EndIf
if sendModEventOnUnlock
SendModEvent(modEventName)
Endif
if ( AdditionalPerk )
PlayerREF.AddPerk(AdditionalPerk)
endif
elseif (PlayerREF.HasPerk(__Config_PerkToTeach1)) && !(PlayerREF.HasPerk(__Config_PerkToTeach2))
If PlayerREF.HasPerk(__Config_PerkToTeach1) == False
TeachFirstPerk()
ElseIf PlayerREF.HasPerk(__Config_PerkToTeach2) == False
PlayerREF.AddPerk(__Config_PerkToTeach2)
else
Else
PlayerREF.AddPerk(__Config_PerkToTeach3)
endif
EndIf
EndFunction
Function TeachTalent()
if !(Game.IsWordUnlocked(__Config_WordToTeach1))
If Game.IsWordUnlocked(__Config_WordToTeach1) == False
PlayerREF.AddShout(__Config_TalentToTeach)
WordToTeach = __Config_WordToTeach1
PlayerREF.AddPerk(__Config_PerkToTeach1)
If __Config_QuestToStart != None
__Config_QuestToStart.start()
EndIf
if sendModEventOnUnlock
SendModEvent(modEventName)
Endif
elseif (Game.IsWordUnlocked(__Config_WordToTeach1)) && !(Game.IsWordUnlocked(__Config_WordToTeach2))
TeachFirstPerk(False)
ElseIf Game.IsWordUnlocked(__Config_WordToTeach2) == False
WordToTeach = __Config_WordToTeach2
PlayerREF.AddPerk(__Config_PerkToTeach2)
else
Else
WordToTeach = __Config_WordToTeach3
PlayerREF.AddPerk(__Config_PerkToTeach3)
endif
EndIf
Game.UnlockWord(WordToTeach)
Game.TeachWord(WordToTeach)
SetRecoveryTime(WordToTeach)
EndFunction
Function TeachFirstPerk(Bool bTeachAdditionalPerk = True)
PlayerREF.AddPerk(__Config_PerkToTeach1)
If __Config_QuestToStart
__Config_QuestToStart.Start()
EndIf
If AdditionalPerk && bTeachAdditionalPerk
PlayerREF.AddPerk(AdditionalPerk)
EndIf
If sendModEventOnUnlock
SendModEvent(modEventName)
EndIf
EndFunction
Function SetRecoveryTime(WordOfPower WordToTeach)
@ -116,56 +114,54 @@ Function SetRecoveryTime(WordOfPower WordToTeach)
__Config_TalentToTeach.SetNthRecoveryTime(1, fRecoveryTime03)
__Config_TalentToTeach.SetNthRecoveryTime(2, fRecoveryTime03)
EndIf
EndFunction
Function PlayVisuals()
;Fix for ERB-1355, somehow _00E_TalentpointsRemaining was not filled in that save game on all perk activators
If _00E_TalentpointsRemaining == None
_00E_TalentpointsRemaining = Game.GetFormFromFile(0x000431FB, "Skyrim.esm") as Message
EndIf
_00E_TalentpointsRemaining.Show(TalentPoints.GetValueInt() as Int)
_00E_TalentpointsRemaining.Show(TalentPoints.GetValueInt())
ObjectReference MemoryPoint = Self.GetLinkedRef()
MAGConjureImpact.Play(PlayerREF)
MemoryPoint.PlayAnimation("PlayAnim02")
if( MemoryPoint.GetLinkedRef(TestLine) )
MemoryPoint.GetLinkedRef(TestLine).PlayAnimation("Unlock")
endif
if( MemoryPoint.GetLinkedRef(__PerkLine01) )
MemoryPoint.GetLinkedRef(__PerkLine01).PlayAnimation("Unlock")
endif
if( MemoryPoint.GetLinkedRef(__PerkLine02) )
MemoryPoint.GetLinkedRef(__PerkLine02).PlayAnimation("Unlock")
endif
if( MemoryPoint.GetLinkedRef(__PerkLine03) )
MemoryPoint.GetLinkedRef(__PerkLine03).PlayAnimation("Unlock")
endif
if( MemoryPoint.GetLinkedRef(__PerkLine04) )
MemoryPoint.GetLinkedRef(__PerkLine04).PlayAnimation("Unlock")
endif
if( MemoryPoint.GetLinkedRef(__PerkLine05) )
MemoryPoint.GetLinkedRef(__PerkLine05).PlayAnimation("Unlock")
endif
if( MemoryPoint.GetLinkedRef(__PerkLine06) )
MemoryPoint.GetLinkedRef(__PerkLine06).PlayAnimation("Unlock")
endif
Sound unlockSound = Game.GetForm(0x0003A1E7) as Sound
PlayUnlockAnimationOnLinkedRef(MemoryPoint, TestLine)
PlayUnlockAnimationOnLinkedRef(MemoryPoint, __PerkLine01)
PlayUnlockAnimationOnLinkedRef(MemoryPoint, __PerkLine02)
PlayUnlockAnimationOnLinkedRef(MemoryPoint, __PerkLine03)
PlayUnlockAnimationOnLinkedRef(MemoryPoint, __PerkLine04)
PlayUnlockAnimationOnLinkedRef(MemoryPoint, __PerkLine05)
PlayUnlockAnimationOnLinkedRef(MemoryPoint, __PerkLine06)
GoToState("") ; Time to unlock OnActivate
Sound unlockSound = Game.GetFormFromFile(0x0003A1E7, "Skyrim.esm") as Sound
unlockSound.Play(PlayerREF)
MAGDragonPowerAbsorbManEffect.Play(PlayerREF, 8 , MemoryPoint)
MAGDragonPowerAbsorbManEffect.Play(PlayerREF, 8, MemoryPoint)
_00E_UnlockClassIMOD.Apply()
Utility.Wait(0.1)
_00E_Class_MemoryAbsorbFXS.Play(playerREF)
_00E_Class_MemoryAbsorbFXS.Play(PlayerREF)
Utility.Wait(3)
_00E_Class_MemoryAbsorbFXS.Stop(playerREF)
_00E_Class_MemoryAbsorbFXS.Stop(PlayerREF)
Utility.Wait(2)
MAGDragonPowerAbsorbManEffect.Stop(PlayerREF)
EndFunction
Function PlayUnlockAnimationOnLinkedRef(ObjectReference MemoryPoint, Keyword linkedKwd)
ObjectReference ref = MemoryPoint.GetLinkedRef(linkedKwd)
If ref
ref.PlayAnimation("Unlock")
EndIf
EndFunction
Function FinalizeUnlock()
TalentPoints.Mod(-1)
PlayerREF.SetAV("dragonsouls", TalentPoints.GetValueInt())
PlayVisuals()
EndFunction

@ -126,13 +126,12 @@ EndFunction
Function PlayKiss()
; Solves "torch in body" problem while kissing
_00E_MC_CaliaREF.UnEquipItem(Torch01, True)
;Solves "torch in body" problem while kissing
_FS_TheriantrophistControlQuest.TransformBackIfTransformed()
if Player.GetRace() == HighElfRace
fPlayerScale = PlayerREF.GetScale()
PlayerREF.SetScale(1.0)
endif
If Player.GetRace() == HighElfRace
fPlayerScale = _00E_QuestFunctions.SetActorScale(PlayerREF, 0.92)
EndIf
Int iHand = 0
if PlayerREF.GetEquippedItemType(iHand) == 11
@ -180,11 +179,11 @@ Function FadeOut()
CQC05_SC02_DoorREF.BlockActivation(True)
CaliaRomance.SetValueInt(1)
PlayerREF.SetScale(1.0)
FadeToBlackIMOD.Apply()
Utility.Wait(2)
FadeToBlackHoldIMOD.ApplyCrossFade(1)
Utility.Wait(1)
PlayerREF.SetScale(1.0) ; TODO, Gavrant, 2021-06-21: probably delete it. There is another revert of the scale later, in FadeBack.
_00E_MC_CaliaREF.SetUnconscious(False)
PlayerREF.SetUnconscious(False)

@ -49,8 +49,7 @@ Function PlayKissAnimation()
_00E_QuestFunctions.EndWerewolfModeWhenTransformed()
If Player.GetRace() == HighElfRace
fPlayerScale = PlayerREF.GetScale()
PlayerREF.SetScale(1.0)
fPlayerScale = _00E_QuestFunctions.SetActorScale(PlayerREF, 0.92)
EndIf
If PlayerREF.GetEquippedShield() != None
@ -103,9 +102,9 @@ Function FadeOut()
PlayerREF.SetUnconscious(False)
Debug.ToggleMenus()
Debug.ToggleCollisions()
if Player.GetRace() == HighElfRace
If Player.GetRace() == HighElfRace
PlayerREF.SetScale(fPlayerScale)
endif
EndIf
_00E_MC_JesparREF.MoveTo(MQ13a_StarshipBedREF)
_00E_MC_JesparREF.MoveTo(CQJ05_SC01_JesparLayMarker)
PlayerREF.MoveTo(MQ13a_StarshipBedREF)

@ -6,119 +6,117 @@ Scriptname _00E_FrozenMEScript extends activemagiceffect
;=====================================================================================
Auto State Default
Event OnEffectStart(Actor akTarget, Actor akCaster)
Debug.Trace(self + ", OnEffectStart (Default): akTarget = " + akTarget + "; akCaster = " + akCaster)
FrozenActor = akCaster
If FrozenActor && FrozenActor.GetAVPercentage("Health") > 0.1 && FrozenActor.HasPerk(_00E_FrozenPerk) == False
_00E_A1_ArcticWindFreezeM.Play(akTarget)
FrozenActor.AddPerk(_00E_FrozenPerk)
FrozenActor.EnableAI(False)
FrozenActor.SetAV("Paralysis", 1.0) ; Prevents movement and attacking.
GoToState("Frozen")
EndIf
Event OnEffectStart(Actor TheTarget, Actor TheCaster)
FrozenActor = TheCaster
If FrozenActor.GetAVPercentage("Health") > 0.1
KillMove.SetValueInt(0)
_00E_A1_ArcticWindFreezeM.Play(TheTarget)
FrozenActor.AddPerk(_00E_FrozenPerk)
FrozenActor.EnableAI(False)
GoToState("Frozen")
EndIf
EndEvent
Debug.Trace(self + ", OnEffectStart (Default): done")
EndEvent
EndState
;======================================FROZEN STATE================================
;====================================== FROZEN STATE =================================
State Frozen
;/
Event OnBeginState()
Debug.Trace(self + ", OnBeginState (Frozen)")
PositionMarkerRef = FrozenActor.PlaceAtMe(XMarker)
Debug.Trace(self + ", OnBeginState (Frozen): done")
EndEvent /;
Event OnUpdate()
bHitLock = False
Event OnUpdate()
bHitLock = False
EndEvent
EndEvent
Event OnHit(ObjectReference akAggressor, Form akSource, Projectile akProjectile, bool abPowerAttack, bool abSneakAttack, bool abBashAttack, bool abHitBlocked)
Debug.Trace(self + ", OnHit: akAggressor = " + akAggressor + "; akSource = " + akSource + "; akProjectile = " + akProjectile + "; abPowerAttack = " + abPowerAttack + "; abSneakAttack = " + abSneakAttack + "; abBashAttack = " + abBashAttack + "; abBashAttack = " + abHitBlocked)
Event OnHit(ObjectReference akAggressor, Form akSource, Projectile akProjectile, bool abPowerAttack, bool abSneakAttack, bool abBashAttack, bool abHitBlocked)
WPNImpactBladeVsIce.Play(FrozenActor)
WPNImpactBladeVsIce.Play(FrozenActor)
If !_00E_NoShatterNPCFormList.HasForm(FrozenActor.GetActorBase())
If FrozenActor.IsEssential()
Return
EndIf
If !PlayerREF.HasPerk(_04E_30_UNI_SongOfWinterFrostDamagePerk)
ShatterChance = __Config_BaseShatterChance
Float fShatterChance
If PlayerREF.HasPerk(_04E_30_UNI_SongOfWinterFrostDamagePerk)
fShatterChance = __Config_BaseShatterChance * 2.0
Else
ShatterChance = __Config_BaseShatterChance*2
fShatterChance = __Config_BaseShatterChance
EndIf
If !bHitLock
If bHitLock == False
bHitLock = True
If akSource.HasKeyword(WeaponTypeBluntWeapon)
ShatterChance = (ShatterChance + __Config_ShatterChanceBluntWeaponBonus)
fShatterChance += __Config_ShatterChanceBluntWeaponBonus
EndIf
If abPowerAttack == True
ShatterChance = (ShatterChance + __Config_ShatterChancePowerAttackBonus)
If abPowerAttack
fShatterChance += __Config_ShatterChancePowerAttackBonus
EndIf
If ShockSpells.HasForm(akSource)
ShatterChance = (ShatterChance + __Config_ShatterChanceShockSpellBonus)
fShatterChance += __Config_ShatterChanceShockSpellBonus
fShatterChance += 1.0
EndIf
If akSource == _00E_A1_OnslaughtCloakDMG
ShatterChance = (ShatterChance + __Config_ShatterChanceOnslaughtSpellBonus)
fShatterChance += __Config_ShatterChanceOnslaughtSpellBonus
If _00E_Synergy_ArcticWindOnslaught.GetValueInt() == 0
_00E_Synergy_ArcticWindOnslaught.SetValueInt(1)
Levelsystem.ShowSynergyMessage()
EndIf
EndIf
If Utility.RandomFloat() < ShatterChance
HasBeenShattered = true
ShatterEnemy()
GoToState("Finished")
If Utility.RandomFloat() < fShatterChance
If bNoShatter == False
GoToState("Finished")
ShatterEnemy()
Debug.Trace(self + ", OnHit: shatter!")
EndIf
Else
If bNoShatter == False
RegisterForSingleUpdate(1.5)
EndIf
EndIf
RegisterForSingleUpdate(fHitTimer)
Endif
EndIf
EndEvent
Event OnDying(Actor akKiller)
FrozenActor.EnableAI(True)
Self.Dispel()
EndEvent
EndIf
Event OnEffectFinish(Actor akTarget, Actor akCaster)
;If FrozenActor.GetAV("Health") < 1 && !_00E_NoShatterNPCFormList.HasForm(FrozenActor.GetActorBase())
; ShatterEnemy()
;Else
Debug.Trace(self + ", OnHit: done")
EndEvent
Event OnDying(Actor akKiller)
Debug.Trace(self + ", OnDying")
bNoShatter = True
EnableTargetAI()
; FrozenActor.EnableAI(True)
; Self.Dispel()
Debug.Trace(self + ", OnDying: done")
EndEvent
Event OnEffectFinish(Actor akTarget, Actor akCaster)
Debug.Trace(self + ", OnEffectFinish")
bNoShatter = True
GoToState("Finished")
_00E_A1_ArcticWindFreezeM.Play(akTarget)
FrozenActor.SetAlpha(1.0, true)
;EndIf
FrozenActor.EnableAI(True)
FrozenActor.RemovePerk(_00E_FrozenPerk)
If Utility.GetINIBool("bVATSDisable:VATS") == 0
KillMove.SetValueInt(1)
EndIf
GoToState("Finished")
; Debug.Trace(self + ", OnEffectFinish: distance from the marker: " + FrozenActor.GetDistance(PositionMarkerRef))
EndEvent
EnableTargetAI()
FrozenActor.RemovePerk(_00E_FrozenPerk)
; DeletePositionMarker()
Debug.Trace(self + ", OnEffectFinish: done")
EndEvent
EndState
;======================================FINISHED STATE================================
;====================================== FINISHED STATE ===============================
State Finished
@ -131,19 +129,19 @@ EndState
;=====================================================================================
Function ShatterEnemy()
; EnableTargetAI()
FrozenActor.Kill(PlayerREF)
Utility.Wait(0.1)
FrozenActor.PlaceAtMe(_00E_FrostShatteringExplosion02)
if FrozenActor.HasKeyword(ActorTypeNPC) || FrozenActor.GetRace() == DraugrRace
If FrozenActor.HasKeyword(ActorTypeNPC) || FrozenActor.GetRace() == DraugrRace
FrozenActor.PlaceAtMe(_00E_FS_MAGIceGoreExplosion)
Else
FrozenActor.PlaceAtMe(_00E_FrostShatteringExplosion)
EndIf
FrozenActor.SetAlpha (0.0, true)
FrozenActor.SetCriticalStage(FrozenActor.CritStage_DisintegrateStart)
FrozenActor.SetAlpha(0.0, true)
FrozenActor.AttachAshPile(_00E_ShatteredEnemyPile)
WPNImpactBladeVsIce.Play(FrozenActor)
Game.ShakeCamera(afStrength = 0.3)
@ -154,31 +152,48 @@ Function ShatterEnemy()
Game.UnlockAchievement("END_FROZEN_01")
_00E_FrozenAchievementUnlocked.SetValueInt(1)
EndIf
; DeletePositionMarker()
EndFunction
Function DeletePositionMarker()
If PositionMarkerRef
PositionMarkerRef.Disable()
PositionMarkerRef.Delete()
PositionMarkerRef = None
EndIf
EndFunction
Function EnableTargetAI()
If bReenabledAI == False
bReenabledAI = True
FrozenActor.SetAV("Paralysis", 0)
;/ If PositionMarkerRef
FrozenActor.MoveTo(PositionMarkerRef)
EndIf /;
FrozenActor.EnableAI(True)
EndIf
EndFunction
;=====================================================================================
; PROPERTIES
;=====================================================================================
float ShatterChance
float KillMoveChanceOriginal
bool HasBeenShattered
bool bHitLock
Bool bHitLock
Bool bReenabledAI
Bool bNoShatter
float fHitTimer = 1.5
Actor FrozenActor
ObjectReference PositionMarkerRef
float __Config_BaseShatterChance = 0.06
float __Config_ShatterChancePowerAttackBonus = 0.035
float __Config_ShatterChanceBluntWeaponBonus = 0.02
float __Config_ShatterChanceShockSpellBonus = 0.025
float __Config_ShatterChanceOnslaughtSpellBonus = 0.04
Float Property __Config_BaseShatterChance = 0.06 AutoReadOnly
Float Property __Config_ShatterChancePowerAttackBonus = 0.035 AutoReadOnly
Float Property __Config_ShatterChanceBluntWeaponBonus = 0.02 AutoReadOnly
Float Property __Config_ShatterChanceShockSpellBonus = 0.025 AutoReadOnly
Float Property __Config_ShatterChanceOnslaughtSpellBonus = 0.04 AutoReadOnly
_00E_QuestFunctions Property Levelsystem Auto
Actor FrozenActor
GlobalVariable Property KillMove Auto
GlobalVariable Property _00E_Synergy_ArcticWindOnslaught Auto
GlobalVariable Property _00E_FrozenAchievementUnlocked Auto
GlobalVariable Property _00E_AchievementsEnabled Auto
@ -207,4 +222,4 @@ Perk Property _04E_30_UNI_SongOfWinterFrostDamagePerk Auto
Sound Property WPNImpactBladeVsIce Auto
FormList Property _00E_NoShatterNPCFormList Auto
Static Property XMarker Auto

@ -4,8 +4,10 @@ WordOfPower Property _00E_Affinity_Soulcaller_TransformApparation_Word01 Auto
Shout Property _00E_Affinity_Soulcaller_TransformApparation Auto
Event OnEffectStart(Actor akTarget, Actor akCaster)
Game.TeachWord(_00E_Affinity_Soulcaller_TransformApparation_Word01)
Game.UnlockWord(_00E_Affinity_Soulcaller_TransformApparation_Word01)
If Game.IsWordUnlocked(_00E_Affinity_Soulcaller_TransformApparation_Word01) == False
Game.TeachWord(_00E_Affinity_Soulcaller_TransformApparation_Word01)
Game.UnlockWord(_00E_Affinity_Soulcaller_TransformApparation_Word01)
EndIf
akTarget.AddShout(_00E_Affinity_Soulcaller_TransformApparation)
Endevent

@ -6,6 +6,7 @@ Spell Property _00E_FakeArrowSP Auto
Spell Property _00E_FS_Ghostblade_FakeAttackSpellSP Auto
Event OnEffectStart(Actor akTarget, Actor akCaster)
Debug.Trace("_00E_FS_Affinity_Ghostblade_OnSneakAttack: OnEffectStart")
Actor akApparition = PhasmalistControlQuest.GetApparitionFailsafeRef()
If akApparition
Int iEquippedItemType = akApparition.GetEquippedItemType(1)

@ -35,6 +35,7 @@ Event OnEffectStart(Actor akTarget, Actor akCaster)
If akTarget.HasMagicEffect(_00E_FS_PsychosisWeaknessVisualME)
akTarget.DispelSpell(_00E_FS_PsychosisWeaknessSP)
akTarget.DispelSpell(_00E_FS_PsychosisWeaknessSP_NoSlow)
EndIf
EndEvent
@ -69,3 +70,4 @@ Message Property _00E_FS_FakeStealthMsg Auto
Sound Property UISneakAttackM Auto
Spell Property _00E_FS_PsychosisWeaknessSP Auto
Spell Property _00E_FS_PsychosisWeaknessSP_NoSlow Auto

@ -52,4 +52,4 @@ Potion Property FoodCabbagePotatoSoup Auto
GlobalVariable Property FS_NQ07_HoneyWineBought Auto
GlobalVariable Property FS_NQ07_ChickenCooked Auto
GlobalVariable Property FS_NQ07_SoupBrewed Auto
GlobalVariable Property FS_NQ07_SoupBrewed Auto

@ -41,8 +41,10 @@ Function PlayDeathFX()
SetCriticalStage(CritStage_DisintegrateEnd)
myActorBase.SetEssential(True)
If (Game.GetPlayer() as _00E_EPUpdateFunctions).receiveEP(RewardExp)
; Player receives EXP
If RewardExp > 0
If (Game.GetPlayer() as _00E_EPUpdateFunctions).receiveEP(RewardExp)
; Player receives EXP
EndIf
EndIf
EndFunction

@ -24,42 +24,39 @@ EndEvent
;=====================================================================================
Function CheckForPsychosis()
If !akVictim.HasSpell(_00E_FS_PsychosisWeaknessSP)
If !akVictim.HasSpell(_00E_FS_PsychosisCounter_01_SP)
If akVictim.HasMagicEffect(_00E_FS_PsychosisWeaknessVisualME) == False
If akVictim.HasSpell(_00E_FS_PsychosisCounter_01_SP) == False
akVictim.AddSpell(_00E_FS_PsychosisCounter_01_SP, False)
ElseIf akVictim.HasSpell(_00E_FS_PsychosisCounter_01_SP) && !akVictim.HasSpell(_00E_FS_PsychosisCounter_02_SP)
akVictim.AddSpell(_00E_FS_PsychosisCounter_02_SP, false)
ElseIf akVictim.HasSpell(_00E_FS_PsychosisCounter_02_SP) == False
akVictim.AddSpell(_00E_FS_PsychosisCounter_02_SP, False)
Else
AddDebuff()
EndIf
EndIf
EndFunction
Function AddDebuff()
Spell weaknessSpell = _00E_FS_PsychosisWeaknessSP_NoSlow
If caster == PlayerREF
If PlayerREF.HasPerk(_00E_Class_Sinistrope_P08_C_Illusionist)
weaknessSpell = _00E_FS_PsychosisWeaknessSP
EndIf
_00E_FS_Psychosis_Weakened.Show()
EndIf
float fResist = caster.GetActorValue("Illusion")/2
Float fResist = caster.GetActorValue("Illusion") * 0.5
_00E_FS_PsychosisWeaknessSP.SetNthEffectMagnitude(0, fResist)
_00E_FS_PsychosisWeaknessSP.SetNthEffectMagnitude(1, fResist)
_00E_FS_PsychosisWeaknessSP.SetNthEffectMagnitude(2, fResist)
_00E_FS_PsychosisWeaknessSP.SetNthEffectMagnitude(3, fResist)
_00E_FS_PsychosisWeaknessSP.SetNthEffectMagnitude(4, fResist)
_00E_FS_PsychosisWeaknessSP.SetNthEffectMagnitude(5, fResist)
weaknessSpell.SetNthEffectMagnitude(0, fResist)
weaknessSpell.SetNthEffectMagnitude(1, fResist)
weaknessSpell.SetNthEffectMagnitude(2, fResist)
weaknessSpell.SetNthEffectMagnitude(3, fResist)
weaknessSpell.SetNthEffectMagnitude(4, fResist)
weaknessSpell.SetNthEffectMagnitude(5, fResist)
_00E_FS_PsychosisWeaknessSP.Cast(akVictim, akVictim)
weaknessSpell.Cast(akVictim, akVictim)
akVictim.RemoveSpell(_00E_FS_PsychosisCounter_01_SP)
akVictim.RemoveSpell(_00E_FS_PsychosisCounter_02_SP)
EndFunction
;=====================================================================================
@ -71,7 +68,10 @@ Actor caster
Actor Property PlayerREF Auto
Perk Property _00E_Class_Sinistrope_P08_C_Illusionist Auto
Spell Property _00E_FS_PsychosisWeaknessSP Auto
Spell Property _00E_FS_PsychosisWeaknessSP_NoSlow Auto
MagicEffect Property _00E_FS_PsychosisWeaknessVisualME Auto
Spell Property _00E_FS_PsychosisCounter_01_SP Auto
Spell Property _00E_FS_PsychosisCounter_02_SP Auto

@ -1,47 +1,16 @@
Scriptname _00E_FS_Theriantrophist_AllowTempTSC extends ObjectReference
Event OnTriggerEnter(ObjectReference akActionRef)
if akActionRef == PlayerREF
If akActionRef == PlayerREF
_00E_FS_Theriantrophist_AllowTemporaryTransform.SetValueInt(1)
if bCrampyDungeon
fOriginalScale = PlayerREF.GetScale()
PlayerREF.SetScale(0.92)
endif
endif
EndIf
EndEvent
Event OnTriggerLeave(ObjectReference akActionRef)
if akActionRef == PlayerREF
If akActionRef == PlayerREF
_00E_FS_Theriantrophist_AllowTemporaryTransform.SetValueInt(0)
if bCrampyDungeon
if fOriginalScale > 0
PlayerREF.SetScale(fOriginalScale)
else
PlayerREF.SetScale(1.0)
endif
endif
endif
EndIf
EndEvent
float fOriginalScale = 1.0
bool Property bCrampyDungeon = False Auto
; This makes the werewolf a bit smaller
Actor Property PlayerREF Auto
GlobalVariable Property _00E_FS_Theriantrophist_AllowTemporaryTransform Auto

@ -39,8 +39,7 @@ Event OnKeyDown(Int KeyCode)
If KeyCode == iHeroMenuKeycode || (MenuOpen && (KeyCode == iExitHeroMenuKeycode1 || KeyCode == iExitHeroMenuKeycode2))
If !MenuOpen
If Utility.IsInMenuMode() == False && UI.IsTextInputEnabled() == False && bReadyToOpen && PlayerREF.GetCurrentLocation() != _00E_Dreamworld_Location
bReadyToOpen = False
If Utility.IsInMenuMode() == False && UI.IsTextInputEnabled() == False && PlayerREF.GetCurrentLocation() != _00E_Dreamworld_Location && bReadyToOpen
bReadyToOpen = False
InitializeActorValueInfos()
OpenSkillmenu()

@ -15,8 +15,7 @@ Function SetUpScene()
MQ10a_SC1_HeartParentREF.Enable()
Levelsystem.RemoveSilence()
PlayerREF.MoveTo(PlayerStartMarkerNew)
fPlayerScale = PlayerREF.GetScale()
PlayerREF.SetScale(0.85)
fPlayerScale = _00E_QuestFunctions.SetActorScale(PlayerREF, 0.85)
Levelsystem.SkipTimeToHour(18.4)
Game.ForceFirstPerson()
_00E_QuestFunctions.PlayerAIWalkStop() ; workaround for the "uncompiled scripts bug" of patch 1.5.8.0

@ -254,8 +254,7 @@ Function StartSC03()
_00E_QuestFunctions.PlayerAIWalkStop()
Game.ShowFirstPersonGeometry(False)
Game.RequestAutoSave()
fPlayerScale = PlayerREF.GetScale()
PlayerREF.SetScale(0.85)
fPlayerScale = _00E_QuestFunctions.SetActorScale(PlayerREF, 0.85)
TimeScale.SetValue(0.1)
Levelsystem.SkipTimeToHour(18.5)
ImageSpaceModifier.RemoveCrossFade(3)

@ -6,8 +6,7 @@ Scriptname _00E_MQ12c_HarbirSiegeSC extends ObjectReference Conditional
Event OnTriggerEnter(ObjectReference akActionRef)
If MQ12c.GetStage() >= 5 && akActionRef == PlayerREF
_00E_EnderalOvercast.SetActive(True)
If akActionRef == PlayerREF
bInTrigger = True
RegisterForSingleUpdate(1)
SpotPlayer()
@ -17,9 +16,8 @@ EndEvent
Event OnTriggerLeave(ObjectReference akActionRef)
If MQ12c.GetStage() >= 5 && akActionRef == PlayerREF
If akActionRef == PlayerREF
bInTrigger = False
Weather.ReleaseOverride()
if MQ12c_OpenFire.GetValueInt() == 1
StopFireOnPlayer()
EndIf
@ -49,6 +47,7 @@ State KillPlayerState
EndEvent
EndState
;=====================================================================================
; FUNCTIONS
;=====================================================================================
@ -150,13 +149,9 @@ Message Property _00E_MQ12c_CaughtByNehrimese Auto
MusicType Property _00E_Music_Combat_BonehunterNoCond Auto
Weather Property _00E_EnderalOvercast Auto
Sound Property MAGVampireSunlight Auto
Spell Property _00E_MQ12c_BallistaSpell Auto
Quest Property MQ12c Auto
Topic Property MQ12c_D01_NehrimeseScoutBranchTopic Auto
Topic Property BanditDialogue_NormalToCombat Auto

@ -326,10 +326,13 @@ Function CleanUpAndSetUpSC07()
PlayerREF.UnequipItem(PlayerREF.GetEquippedWeapon(0), false, true)
PlayerREF.UnequipItem(PlayerREF.GetEquippedWeapon(1), false, true)
PlayerREF.UnequipItem(PlayerREF.GetEquippedShield(), false, true)
If PlayerREF.GetActorBase().GetRace() == HighElfRace && PlayerREF.GetActorBase().GetSex() == 0
; TODO, Gavrant, 2021-06-21: No idea what the commented-out code below was supposed to do.
; But it would conflict with the follow-up romance kiss scenes that attempt to do the same, but for both sexes of HighElfRace
; Why only for males and why no scale reverts if no romance happens are a mystery. Target this for later purge.
;/ If PlayerREF.GetActorBase().GetRace() == HighElfRace && PlayerREF.GetActorBase().GetSex() == 0
PlayerREF.SetScale(0.92)
EndIf
EndIf /;
Weather.ReleaseOverride()
MQ13a_Door02_REF.Enable()

@ -1,21 +1,127 @@
Scriptname _00E_MQ13a_GrammophoneSC extends ObjectReference
Event OnUpdate()
Actor Property PlayerREF Auto
Sound Property _00E_MUS_Special_DrachenflugM Auto
Message Property _00E_PlayerhousingKoppophonVolume Auto
Int iSoundID = -1
Float fVolume = 0.5
Bool bMusicLocked = False
Float Property MUSIC_LENGTH = 243.0 AutoReadOnly
;=====================================================================================
; FUNCTIONS
;=====================================================================================
Function PlayMusic(Sound musicSound, Float fMusicLength)
If fVolume <= 0.0 || fVolume > 1.0
fVolume = 0.5
EndIf
RegisterForModEvent("BardsLoadGame", "OnBardsLoadGame")
iSoundID = musicSound.Play(Self)
Sound.SetInstanceVolume(iSoundID, fVolume)
RegisterForSingleUpdate(_00E_QuestFunctions.AdjustTimePeriodByEngineTimerError(fMusicLength))
GoToState("")
_00E_PlayerhousingKoppophonVolume.Show(fVolume * 100.0)
EndFunction
Function ChangeMusicVolume()
If fVolume >= 0.0 && fVolume < 1.0
fVolume += 0.25
Else ; fVolume >= 1.0 or something is wrong with fVolume
fVolume = 0.0
EndIf
Sound.SetInstanceVolume(iSoundID, fVolume)
_00E_PlayerhousingKoppophonVolume.Show(fVolume * 100.0)
EndFunction
Function StopMusic()
bMusicLocked = True
GoToState("DoneCleanup")
UnregisterForModEvent("BardsLoadGame")
UnregisterForUpdate()
If iSoundID != -1
Sound.StopInstance(iSoundID)
iSoundID = -1
EndIf
bMusicLocked = False
EndFunction
Function TryStopMusic()
If bMusicLocked == False
StopMusic()
Else
RegisterForSingleUpdate(0.5)
EndIf
EndFunction
bIsPlaying = False
;=====================================================================================
; EVENTS
;=====================================================================================
Event OnInit()
GoToState("DoneCleanup")
EndEvent
Event OnActivate(ObjectReference akActionRef)
If akActionRef == PlayerREF && bMusicLocked == False
bMusicLocked = True
If !bIsPlaying
bIsPlaying = True
_00E_MUS_Special_DrachenflugM.Play(Self)
RegisterForSingleUpdate(160)
If iSoundID == -1
PlayMusic(_00E_MUS_Special_DrachenflugM, MUSIC_LENGTH)
Else
ChangeMusicVolume()
EndIf
bMusicLocked = False
EndIf
EndEvent
bool bIsPlaying
Event OnUpdate()
TryStopMusic()
EndEvent
Event OnBardsLoadGame(string eventName, string strArg, float numArg, Form sender)
; Player just loaded a save with the gramophone playing. The sound is dead by now.
TryStopMusic()
EndEvent
Event OnCellAttach()
TryStopMusic()
EndEvent
Event OnLoad()
TryStopMusic()
EndEvent
Event OnCellDetach()
TryStopMusic()
EndEvent
Event OnUnload()
TryStopMusic()
EndEvent
State DoneCleanup
Event OnCellAttach()
; Do nothing
EndEvent
Event OnLoad()
; Do nothing
EndEvent
Event OnCellDetach()
; Do nothing
EndEvent
Sound Property _00E_MUS_Special_DrachenflugM Auto
Event OnUnload()
; Do nothing
EndEvent
EndState

@ -486,8 +486,7 @@ EndFunction
Function PlayKiss()
If PlayerREF.GetActorBase().GetRace() == HighElfRace
fPlayerScale = PlayerREF.GetScale()
PlayerREF.SetScale(0.92)
fPlayerScale = _00E_QuestFunctions.SetActorScale(PlayerREF, 0.92)
EndIf
PlayerREF.UnequipItem(PlayerREF.GetEquippedShield(), false, true)
@ -529,9 +528,7 @@ Function FadeOut()
PlayerREF.RemoveSpell(_00E_Game_abSlowTime)
If PlayerREF.GetActorBase().GetRace() == HighElfRace
PlayerREF.SetScale(fPlayerScale)
EndIf
PlayerREF.SetUnconscious(False)

@ -0,0 +1,5 @@
Scriptname _00E_PerkBlutrauschFFAimedScript extends activemagiceffect
Event OnEffectStart(Actor akTarget, Actor akCaster)
Debug.Trace("Bloodlust: OnEffectStart")
EndEvent

@ -47,6 +47,8 @@ Int Property iGhostlyWarriorBoostArmorSkill1 = 7 AutoReadOnly
Int Property iGhostlyWarriorBoostArmorSkill2 = 17 AutoReadOnly
Int Property iGhostlyWarriorBoostArmorSkill3 = 30 AutoReadOnly
Float Property DEFAULT_HEAL_RATE = 50.0 AutoReadOnly
Explosion Property _00E_Phasmalist_EnterWorldExp Auto
Perk Property _00E_Class_Phasmalist_P03_Talent_SummonApparation_01 Auto
@ -98,6 +100,8 @@ _00E_Phasmalist_TrinketSC SummonTrinket
; Needed for the failsafe in OnLoadGame() and some other shenanigans
Actor Property AliasFailsafeRef = None Auto Hidden
Bool bTeleportHealRate = False
;=====================================================================================
; SUMMON & SETUP
@ -108,6 +112,7 @@ Function Summon(_00E_Phasmalist_TrinketSC trinket, ObjectReference moveToRef, Bo
SummonTrinket = trinket
bActivationBusy = bPhasmalismTankMode ; Reset just in case
bTeleportHealRate = False ; Reset just in case
_00E_Phasmalist_IsApparitionSummoned.SetValue(1)
Setup() ; init stats before any armor buffs are applied
@ -158,11 +163,8 @@ Function Summon(_00E_Phasmalist_TrinketSC trinket, ObjectReference moveToRef, Bo
EndFunction
Function PlaySummonExplosion(ObjectReference markerRef)
ObjectReference expMarker = markerRef.placeAtMe(XMarker)
expMarker.MoveTo(markerRef, 0.0, 0.0, 15)
expMarker.PlaceAtMe(_00E_Phasmalist_EnterWorldExp)
expMarker.Disable()
expMarker.Delete()
ObjectReference expMarker = _PlaceExplosionEx(_00E_Phasmalist_EnterWorldExp, markerRef, 15.0)
_DeleteMarker(expMarker)
EndFunction
Int Property BOOST_CLASS_MAGE = 0 AutoReadOnly
@ -219,11 +221,19 @@ EndFunction
Function SetupNotPersistentStats(Actor akSelf)
akSelf.GetActorBase().SetCombatStyle(SummonTrinket.GetUsedCombatStyle())
akSelf.SetAV("HealRate", 50)
If bTeleportHealRate == False
akSelf.SetAV("HealRate", DEFAULT_HEAL_RATE)
Else
akSelf.SetAV("HealRate", 0.0)
EndIf
akSelf.SetAV("MagickaRate", fApparitionManaRate)
;failsafe since setav doesn't work sometimes
akSelf.ForceAV("HealRate", 50)
If bTeleportHealRate == False
akSelf.ForceAV("HealRate", DEFAULT_HEAL_RATE)
Else
akSelf.ForceAV("HealRate", 0.0)
EndIf
akSelf.ForceAV("MagickaRate", fApparitionManaRate)
EndFunction
@ -290,8 +300,11 @@ Function _AddClassBoost(Actor akSelf, Int iBoostClass, Int iBoostLevel)
akSelf.ModAV("HeavyArmor", iBoostArmor)
;akSelf.ForceAV("LightArmor", akSelf.GetAV("LightArmor") + iBoostArmor)
akSelf.ModAV("LightArmor", iBoostArmor)
; MeleeDamage AV seems to be not working, it's actually always zero
;akSelf.ForceAV("MeleeDamage", akSelf.GetAV("MeleeDamage") + iBoostMelee)
akSelf.ModAV("MeleeDamage", iBoostMelee)
;akSelf.ModAV("MeleeDamage", iBoostMelee)
akSelf.ModAV("OneHanded", iBoostMelee)
akSelf.ModAV("TwoHanded", iBoostMelee)
Else
Debug.Notification("Phasmalist Control Quest has issues: Unsupported boost class " + iBoostClass)
EndIf
@ -393,12 +406,20 @@ EndFunction
Function TeleportToPlayer(Bool bTeleportInFront, Bool bSilent)
Actor akSelf = Self.GetActorReference()
If akSelf
; Zero out-of-combat heal rate for teleport and a few seconds after it.
; This is to prevent the apparition regenerating health IN combat on "Call Apparition" spam.
UnregisterForUpdate()
akSelf.ForceAV("HealRate", 0.0)
bTeleportHealRate = True
akSelf.Disable()
_MoveToPlayer(akSelf, bTeleportInFront)
akSelf.Enable()
If bSilent == False
akSelf.PlaceAtMe(_00E_Phasmalist_EnterWorldExp)
EndIf
RegisterForSingleUpdate(2.0)
EndIf
EndFunction
@ -460,10 +481,11 @@ FormList Property _00E_Phasmalist_CombatStyleWerewolfList Auto
Spell Property _00E_FS_Affinity_Soulcaller_ApparationWolfBoostSP Auto
Idle Property WerewolfTransformBack Auto
Idle Property IdleWerewolfTransformation Auto
Idle Property _00E_IdleStomp Auto
Explosion Property _00E_FS_Theriantrophist_TransEXP Auto
Race Property _00E_Theriantrophist_PlayerWerewolfRace Auto
ObjectReference Property _00E_FS_Affinity_Soulcaller_RemoveAndAddApparationItemsChest Auto
Idle Property LooseFullBodyStagger Auto
Armor Property _00E_InvisibleHelmet_Armor Auto
Float Property WEREWOLF_TRANSFORM_UNARMED_DAMAGE_BOOST = 20.0 AutoReadOnly
Float Property WEREWOLF_TRANSFORM_HEALTH_BOOST = 40.0 AutoReadOnly
@ -475,34 +497,38 @@ Bool Function IsTransformedToWerewolf()
EndFunction
Function TransformToWerewolf(Actor akSpellTarget)
ObjectReference expMarker
Actor akSelf = GetActorReference()
If (akSelf == None) || (akSelf != akSpellTarget)
Return
EndIf
akSelf.SetPlayerTeammate(False)
bActivationBusy = True
Utility.Wait(0.2)
akSelf.UnequipAll()
akSelf.SetPlayerTeammate(False)
akSelf.EvaluatePackage()
WerewolfTranform_OriginalRace = akSelf.getRace()
Utility.Wait(0.2)
akSelf.PlayIdle(IdleWerewolfTransformation)
Utility.Wait(0.8)
_SetCombatStyle(akSelf, _00E_Phasmalist_CombatStyleWerewolfList.GetAt(0) as CombatStyle)
_00E_FS_Affinity_Soulcaller_ApparationWolfBoostSP.SetNthEffectMagnitude(0, WEREWOLF_TRANSFORM_UNARMED_DAMAGE_BOOST)
_00E_FS_Affinity_Soulcaller_ApparationWolfBoostSP.SetNthEffectMagnitude(1, WEREWOLF_TRANSFORM_HEALTH_BOOST)
akSelf.AddSpell(_00E_FS_Affinity_Soulcaller_ApparationWolfBoostSP)
Utility.Wait(1)
ObjectReference expMarker = akSelf.PlaceAtMe(XMarker)
expMarker.MoveTo(akSelf, 0.0, 0.0, 100.0)
expMarker.PlaceAtMe(_00E_FS_Theriantrophist_TransEXP)
expMarker = _PlaceExplosionEx(_00E_FS_Theriantrophist_TransEXP, akSelf, 100.0)
Utility.Wait(0.4) ; Pause to synchronize the explosion with the transformation animation(s)
akSelf.SetLookAt(akSelf) ; Reset headtracking to prevent the head getting stuck looking sideways after the tranformation
akSelf.UnequipAll()
akSelf.SetRace(_00E_Theriantrophist_PlayerWerewolfRace)
expMarker.Disable()
expMarker.Delete()
Utility.Wait(0.2)
_DeleteMarker(expMarker)
Utility.Wait(0.2)
akSelf.SetPlayerTeammate(True)
akSelf.EvaluatePackage()
bActivationBusy = False
EndFunction
Function TransformFromWerewolf(Actor akSpellTarget, Bool bIsUnsummoned, Bool bSilent)
@ -511,6 +537,9 @@ Function TransformFromWerewolf(Actor akSpellTarget, Bool bIsUnsummoned, Bool bSi
Return
EndIf
bActivationBusy = True
bTeleportHealRate = False
If akSelf.IsDead()
_TransformFromWerewolfDead(akSelf, bIsUnsummoned, bSilent)
Else
@ -518,25 +547,33 @@ Function TransformFromWerewolf(Actor akSpellTarget, Bool bIsUnsummoned, Bool bSi
EndIf
WerewolfTranform_OriginalRace = None
bActivationBusy = False
EndFunction
Function _TransformFromWerewolfDead(Actor akSelf, Bool bIsUnsummoned, Bool bSilent)
ObjectReference expMarker = None
GoToState("")
If bSilent == False
expMarker = _PlaceExplosionEx(_00E_FS_Theriantrophist_TransEXP, akSelf, 15.0)
EndIf
; RemoveAllItems is needed here for _TriggerEquipmentUpdate to work
akSelf.RemoveAllItems(_00E_FS_Affinity_Soulcaller_RemoveAndAddApparationItemsChest)
akSelf.SetPlayerTeammate(False)
akSelf.Resurrect()
_00E_FS_Affinity_Soulcaller_RemoveAndAddApparationItemsChest.RemoveAllItems(akSelf)
Utility.Wait(0.2)
If bSilent == False
akSelf.PlaceAtMe(_00E_FS_Theriantrophist_TransEXP)
EndIf
Utility.Wait(0.2) ; Pause for the ragdoll to settle. Without it the apparition appears in the air on SetRace
_SetCombatStyle(akSelf, SummonTrinket.GetUsedCombatStyle())
akSelf.RemoveSpell(_00E_FS_Affinity_Soulcaller_ApparationWolfBoostSP)
If expMarker
_DeleteMarker(expMarker)
expMarker = None
EndIf
akSelf.SetRace(WerewolfTranform_OriginalRace)
Utility.Wait(0.2)
_TriggerEquipmentUpdate(akSelf, False)
akSelf.ClearLookAt() ; Reenable headtracking
If bIsUnsummoned == False
GoToState("Working")
@ -545,27 +582,42 @@ Function _TransformFromWerewolfDead(Actor akSelf, Bool bIsUnsummoned, Bool bSile
EndFunction
Function _TransformFromWerewolfAlive(Actor akSelf, Bool bIsUnsummoned, Bool bSilent)
ObjectReference expMarker = None
akSelf.SetPlayerTeammate(False)
If bSilent == False
akSelf.PlaceAtMe(_00E_FS_Theriantrophist_TransEXP)
EndIf
akSelf.EvaluatePackage()
akSelf.PlayIdle(WerewolfTransformBack)
_SetCombatStyle(akSelf, SummonTrinket.GetUsedCombatStyle())
akSelf.RemoveSpell(_00E_FS_Affinity_Soulcaller_ApparationWolfBoostSP)
_SetCombatStyle(akSelf, SummonTrinket.GetUsedCombatStyle())
If bSilent == False
expMarker = _PlaceExplosionEx( _00E_FS_Theriantrophist_TransEXP, akSelf, 100.0)
EndIf
akSelf.SetRace(WerewolfTranform_OriginalRace)
; RemoveAllItems is necessary to correctly reequip items
akSelf.RemoveAllItems(_00E_FS_Affinity_Soulcaller_RemoveAndAddApparationItemsChest)
_00E_FS_Affinity_Soulcaller_RemoveAndAddApparationItemsChest.RemoveAllItems(akSelf)
akSelf.PlayIdle(_00E_IdleStomp)
If bIsUnsummoned
Utility.Wait(0.2)
Else
Utility.Wait(0.1)
_TriggerEquipmentUpdate(akSelf, True)
If expMarker
_DeleteMarker(expMarker)
expMarker = None
EndIf
Utility.Wait(0.2)
akSelf.ClearLookAt() ; Reenable headtracking
If bIsUnsummoned == False
SetupBehaviour(akSelf)
SetupNotPersistentStats(akSelf)
akSelf.EvaluatePackage()
EndIf
EndFunction
Function _TriggerEquipmentUpdate(Actor akSelf, Bool bPlayStaggerIdle)
akSelf.SetPlayerTeammate(True) ; Yes, the apparition has to be a player's teammate for AddItem-EquipItem below to trigger equipment update
If bPlayStaggerIdle
akSelf.PlayIdle(LooseFullBodyStagger)
EndIf
akSelf.AddItem(_00E_InvisibleHelmet_Armor, 1, True)
akSelf.EquipItem(_00E_InvisibleHelmet_Armor, 1)
akSelf.RemoveItem(_00E_InvisibleHelmet_Armor, 1)
EndFunction
;=====================================================================================
; HELPER FUNCTIONS
@ -629,6 +681,18 @@ Function _UnregisterSpellBook(Actor akSelf, Form akBaseItem)
EndIf
EndFunction
ObjectReference Function _PlaceExplosionEx(Explosion exp, ObjectReference refSpot, Float fOffsetZ)
ObjectReference expMarker = refSpot.PlaceAtMe(XMarker)
expMarker.MoveTo(refSpot, 0.0, 0.0, fOffsetZ)
expMarker.PlaceAtMe(exp)
Return expMarker
EndFunction
Function _DeleteMarker(ObjectReference refMarker)
refMarker.Disable()
refMarker.Delete()
EndFunction
;=====================================================================================
; EVENTS
@ -650,12 +714,14 @@ State Working
UIExtensions.SetMenuPropertyIndexString("UIWheelMenu", "optionText", 0, "$View_Attributes")
UIExtensions.SetMenuPropertyIndexString("UIWheelMenu", "optionLabelText", 0, "$View_Attributes")
UIExtensions.SetMenuPropertyIndexString("UIWheelMenu", "optionText", 1, "$Adapt_Combat_Style")
UIExtensions.SetMenuPropertyIndexString("UIWheelMenu", "optionLabelText", 1, "$Adapt_Combat_Style")
UIExtensions.SetMenuPropertyIndexString("UIWheelMenu", "optionText", 4, "$Currently_Equipped")
UIExtensions.SetMenuPropertyIndexString("UIWheelMenu", "optionLabelText", 4, "$Currently_Equipped")
If IsTransformedToWerewolf() == False
UIExtensions.SetMenuPropertyIndexString("UIWheelMenu", "optionText", 1, "$Adapt_Combat_Style")
UIExtensions.SetMenuPropertyIndexString("UIWheelMenu", "optionLabelText", 1, "$Adapt_Combat_Style")
UIExtensions.SetMenuPropertyIndexString("UIWheelMenu", "optionText", 4, "$Currently_Equipped")
UIExtensions.SetMenuPropertyIndexString("UIWheelMenu", "optionLabelText", 4, "$Currently_Equipped")
EndIf
UIExtensions.SetMenuPropertyIndexString("UIWheelMenu", "optionText", 5, "$Quit")
UIExtensions.SetMenuPropertyIndexString("UIWheelMenu", "optionLabelText", 5, "$Quit")
@ -708,4 +774,11 @@ State Working
EndIf
EndEvent
Event OnUpdate()
If bTeleportHealRate
bTeleportHealRate = False
GetActorReference().ForceAV("HealRate", DEFAULT_HEAL_RATE)
EndIf
EndEvent
EndState

@ -1,21 +1,21 @@
Scriptname _00E_Phasmalist_Workbench extends ObjectReference
; script that is attached to all phasmalist workbenches and manages their gui and functions
Message Property illegalTrinket auto
Message Property illegalTrinket Auto
{Message objects whose title is the message that is displayed when the player tries to summon an apparition but wears no phasmalist trinket object}
Message Property reallyDespectralize auto
_FS_Phasmalist_ControlQuest Property phasmalistControlQuest auto
ObjectReference Property spectralizerContainer auto
Message Property reallyDespectralize Auto
_FS_Phasmalist_ControlQuest Property phasmalistControlQuest Auto
ObjectReference Property spectralizerContainer Auto
{the container items that should be spectralized are put in; should be the same for all workbenches}
ObjectReference Property _00E_Phasmalist_DespectralizingContainerReference auto
ObjectReference Property _00E_Phasmalist_DespectralizingContainerReference Auto
Keyword Property _00E_Phasmalist_CraftingWorkbench_NPCMarker auto
Keyword Property _00E_Phasmalist_CraftingWorkbench_NPCMarker Auto
Actor Property PlayerREF Auto
Message Property _00E_Theriantrophist_CantCraftMSG Auto
Race Property _00E_Theriantrophist_PlayerWerewolfRace Auto
_00E_PlayerhousingMaster Property PlayerhousingMaster Auto
GlobalVariable Property _00E_Phasmalist_TankMode Auto
Static Property _00E_NPCMarkerBlue Auto
Bool bApparitionPrepared = False
bool bApparitionSummoned = False
@ -24,6 +24,10 @@ String Property CRAFTING_MENU = "Crafting Menu" AutoReadOnly
String Property CONTAINER_MENU = "ContainerMenu" AutoReadOnly
;=====================================================================================
; EVENTS
;=====================================================================================
Event OnInit()
BlockActivation()
EndEvent
@ -40,20 +44,36 @@ Event OnActivate(ObjectReference akActionRef)
If akActionRef == PlayerREF
GoToState("Waiting")
If PlayerREF.GetRace() == _00E_Theriantrophist_PlayerWerewolfRace
_00E_Theriantrophist_CantCraftMSG.Show()
ElseIf (((Self as ObjectReference) as _00E_Playerhousing_Furniture) == None) || PlayerhousingMaster.GetState() == "Buildmode"
ShowMainMenu()
If _00E_PlayerhousingMaster.ReferenceCanBeActivated(Self)
If PlayerREF.GetRace() == _00E_Theriantrophist_PlayerWerewolfRace
_00E_Theriantrophist_CantCraftMSG.Show()
Else
ShowMainMenu()
Return
EndIf
EndIf
GoToState("")
Else
Activate(akActionRef, true)
EndIf
EndEvent
State Waiting
Event OnActivate(ObjectReference akActionRef)
; Do nothing
EndEvent
EndState
;=====================================================================================
; PHASMALISM MENU
;=====================================================================================
; Summons the apparition and places it in the tank
Function PrepareApparition()
If bApparitionPrepared == False
ObjectReference tankMarkerRef = GetlinkedRef(_00E_Phasmalist_CraftingWorkbench_NPCMarker)
ObjectReference tankMarkerRef = GetTankMarker()
If bApparitionPrepared == False
bApparitionPrepared = True
_00E_Phasmalist_TankMode.SetValue(1)
@ -76,7 +96,7 @@ EndFunction
Function ResetApparitionOnInventoryChange()
If bApparitionPrepared
ObjectReference tankMarkerRef = GetlinkedRef(_00E_Phasmalist_CraftingWorkbench_NPCMarker)
ObjectReference tankMarkerRef = GetTankMarker()
Actor akApparition = phasmalistControlQuest.GetApparitionRef()
If akApparition
akApparition.Disable()
@ -264,7 +284,7 @@ State Spectralize
EndState
State Despectralize
Event onBeginState()
Event OnBeginState()
Actor akApparition = phasmalistControlQuest.GetApparitionRef()
If akApparition
reallyDespectralize.show()
@ -299,8 +319,68 @@ State Despectralize
EndEvent
EndState
State Waiting
Event OnActivate(ObjectReference akActionRef)
; Do nothing
EndEvent
EndState
;=====================================================================================
; PLACEABLE WORKBENCH
;=====================================================================================
ObjectReference PlaceableTankMarkerRef = None
Float Property FAST_TRANSLATION_SPEED = 1000000.0 AutoReadOnly
ObjectReference Function GetTankMarker()
If PlaceableTankMarkerRef
Return PlaceableTankMarkerRef
EndIf
Return GetlinkedRef(_00E_Phasmalist_CraftingWorkbench_NPCMarker)
EndFunction
Function StartPlacement()
If PlaceableTankMarkerRef
PlaceableTankMarkerRef.Disable()
EndIf
EndFunction
Function OnPickUp()
If PlaceableTankMarkerRef
PlaceableTankMarkerRef.Disable()
PlaceableTankMarkerRef.Delete()
PlaceableTankMarkerRef = None
EndIf
EndFunction
Function FinishPlacement()
If PlaceableTankMarkerRef == None
PlaceableTankMarkerRef = PlaceAtMe(_00E_NPCMarkerBlue, abInitiallyDisabled = True)
Else
PlaceableTankMarkerRef.Disable()
EndIf
; (Re)position the marker
Float fOffsetX = -116.0
Float fOffsetY = 5.0 ; 54 ; 22.4
Float fOffsetZ = 20.0
Float fOffsetAngleZ = 136.0
Float fWorkbenchAngleZ = GetAngleZ()
Float cosZ = Math.Cos(fWorkbenchAngleZ)
Float sinZ = Math.Sin(fWorkbenchAngleZ)
Float mx = GetPositionX() + fOffsetY * sinZ + fOffsetX * cosZ
Float my = GetPositionY() + fOffsetY * cosZ - fOffsetX * sinZ
Float mz = GetPositionZ() + fOffsetZ
PlaceableTankMarkerRef.MoveTo(self)
PlaceableTankMarkerRef.Enable()
_00E_QuestFunctions.WaitForReferenceToLoad(PlaceableTankMarkerRef)
PlaceableTankMarkerRef.TranslateTo(mx, my, mz, 0, 0, fWorkbenchAngleZ + fOffsetAngleZ, FAST_TRANSLATION_SPEED, FAST_TRANSLATION_SPEED)
; PlaceableTankMarkerRef.SetPosition(mx, my, mz)
; PlaceableTankMarkerRef.SetAngle(0, 0, fWorkbenchAngleZ + fOffsetAngleZ)
EndFunction

@ -133,14 +133,7 @@ endFunction
Function DisableDialogueQuitting() Global
{Disables the TAB Key during dialogue. Resets automatically upon dialogue exit via Goodbye.}
if UI.GetBool("Dialogue Menu", "_root.DialogueMenu_mc.bEnableTab") != true
; Suspected non-Enderal dialoguemenu.swf replacer, rechecking value in order to be sure.
UI.InvokeBool("Dialogue Menu", "_root.DialogueMenu_mc.SetVariable", True)
if UI.GetBool("Dialogue Menu", "_root.DialogueMenu_mc.bEnableTab") != true
Debug.Notification("Detected incompatible dialoguemenu.swf!")
endif
endif
UI.InvokeBool("Dialogue Menu", "_root.DialogueMenu_mc.SetVariable", False)
EndFunction
@ -1235,7 +1228,7 @@ Message Property _00E_PleaseRemoveMoney Auto
GlobalVariable Property GameHour Auto
;--------------------------------------VISION-----------------------------------;
;--------------------------------------VISION-----------------------------------
float PlayerSpeed
int VisionSound

@ -1,10 +1,14 @@
Scriptname _00E_SmokingPipeScript extends ObjectReference
Scriptname _00E_SmokingPipeScript extends ObjectReference
_00E_PeaceweedControlScript Property PeaceweedControl Auto
Actor Property PlayerRef Auto
Event OnEquipped(Actor akActor)
If akActor == PlayerRef
PeaceweedControl.StartSmoking()
; The check of base object is needed because this script somehow gets attached to the quest ref of _00E_FS_NQ07_Rezept (and to various containers)
Form baseObj = GetBaseObject()
If baseObj == None || (baseObj as MiscObject) != None
PeaceweedControl.StartSmoking()
EndIf
EndIf
EndEvent

@ -1,27 +1,30 @@
Scriptname _00E_Theriantrophist_BlockCraftingSC extends ObjectReference
Event OnInit()
Actor Property PlayerREF Auto
Message Property _00E_Theriantrophist_CantCraftMSG Auto
Race Property _00E_Theriantrophist_PlayerWerewolfRace Auto
Bool bActivationBlocked = False
BlockActivation(True)
Event OnInit()
BlockActivation(True)
EndEvent
Event OnActivate(ObjectReference akActionRef)
If akActionRef == PlayerREF
If _00E_PlayerhousingMaster.ReferenceCanBeActivated(Self) && bActivationBlocked == False
bActivationBlocked = True
if akActionRef == PlayerREF
if PlayerREF.GetRace() == _00E_Theriantrophist_PlayerWerewolfRace
_00E_Theriantrophist_CantCraftMSG.Show()
elseif !((self as ObjectReference) as _00E_Playerhousing_Furniture)
Activate(akActionRef, true)
endif
else
Activate(akActionRef, true)
endif
If PlayerREF.GetRace() == _00E_Theriantrophist_PlayerWerewolfRace
_00E_Theriantrophist_CantCraftMSG.Show()
Else
Activate(akActionRef, true)
EndIf
bActivationBlocked = False
EndIf
Else
Activate(akActionRef, true)
EndIf
EndEvent
Actor Property PlayerREF Auto
Message Property _00E_Theriantrophist_CantCraftMSG Auto
Race Property _00E_Theriantrophist_PlayerWerewolfRace Auto

@ -141,6 +141,12 @@ State WolfForm
carryCapacityMod = PlayerREF.getAV("CarryWeight") - WerewolfBaseCarryCapacity
humanSpeedMult = PlayerREF.getAV("speedMult")
; If the player is under the influence of a slowdown magic effect, take the player's normal speedMult from Fame AV. See FrostSlowFix.psc
Float fFame = PlayerREF.GetBaseActorValue("Fame")
If fFame > humanSpeedMult
humanSpeedMult = fFame
EndIf
speedMult = humanSpeedMult
temporarySpeedMultMod = 0
renewNotPersistentStats()

@ -78,6 +78,14 @@ Event OnLocationChange(Location akOldLoc, Location akNewLoc)
bGradualTransition = True
EndIf
ElseIf bArkSpecialWeather && akNewLoc == ArkSiegeWeatherEdge
; If we're leaving Ark's outskirts, keep the current Ark weather for a bit longer.
; This prevents frequent weather switches if we're wondering at the edge of the siege weather zone and regularly crossing that edge.
If (akOldLoc == CapitalCityLocation || akOldLoc == ArkSiegeWeather) && (iCurrentArkWeather == WEATHER_OVERCAST || iCurrentArkWeather == WEATHER_RAIN)
iNewWeather = iCurrentArkWeather
bGradualTransition = True
EndIf
EndIf
SetNewWeather(iNewWeather, bGradualTransition)
@ -158,8 +166,10 @@ Bool Function LocationIsSuntemple(Location lc)
EndFunction
Bool Function LocationIsArk(Location lc)
If lc && ((lc == CapitalCityLocation) || lc.isChild(CapitalCityLocation))
Return True
If lc
If (lc == CapitalCityLocation) || (lc == ArkSiegeWeather) || lc.isChild(CapitalCityLocation)
Return True
EndIf
EndIf
Return False
@ -244,6 +254,8 @@ Int iCurrentArkWeather = 0
Bool bGameTimeUpdatesActive = False
Location Property CapitalCityLocation Auto
Location Property ArkSiegeWeather Auto
Location Property ArkSiegeWeatherEdge Auto
FormList Property _00E_SuntempleLocations Auto
Weather Property _00E_EnderalOvercast Auto

@ -4,19 +4,16 @@ Scriptname _60E_FS_Mystical_ThoughtImplosionSC extends ActiveMagicEffect
; EVENTS
;=====================================================================================
Event OnEffectStart(Actor akTarget, Actor akCaster)
int iChance = Utility.RandomInt(1, 100)
Int iChance = Utility.RandomInt(1, 100)
if iChance > 0 && iChance < 33
If iChance < 33
; Do nothing
Elseif iChance >= 33 && iChance < 66
ElseIf iChance < 66 || akTarget.HasMagicEffect(_00E_FS_PsychosisWeaknessVisualME)
PushBack(akTarget)
Elseif iChance >= 66
Else
Weaken(akTarget)
EndIf
EndEvent
;=====================================================================================
@ -24,34 +21,39 @@ EndEvent
;=====================================================================================
Function PushBack(Actor Target)
MAGAlterationTelekinesisThrow.Play(Target)
float fPushStrength = (PlayerREF.GetActorValue("Illusion")/10)
if fPushStrength < 4
Float fPushStrength = PlayerREF.GetActorValue("Illusion") / 10.0
If fPushStrength < 4
_00E_FS_PsionicPushStaggerSP.Cast(Target, Target)
Else
PlayerREF.PushActorAway(Target, (PlayerREF.GetActorValue("Illusion")/10))
PlayerREF.PushActorAway(Target, fPushStrength)
EndIf
EndFunction
Function Weaken(Actor Target)
Spell weaknessSpell
If PlayerREF.HasPerk(_00E_Class_Sinistrope_P08_C_Illusionist)
weaknessSpell = _00E_FS_PsychosisWeaknessSP
Else
weaknessSpell = _00E_FS_PsychosisWeaknessSP_NoSlow
EndIf
_00E_FS_Psychosis_Weakened.Show()
float fResist = PlayerREF.GetActorValue("Illusion")/2
Float fResist = PlayerREF.GetActorValue("Illusion") * 0.5
_00E_FS_PsychosisWeaknessSP.SetNthEffectMagnitude(0, fResist)
_00E_FS_PsychosisWeaknessSP.SetNthEffectMagnitude(1, fResist)
_00E_FS_PsychosisWeaknessSP.SetNthEffectMagnitude(2, fResist)
_00E_FS_PsychosisWeaknessSP.SetNthEffectMagnitude(3, fResist)
_00E_FS_PsychosisWeaknessSP.SetNthEffectMagnitude(4, fResist)
_00E_FS_PsychosisWeaknessSP.SetNthEffectMagnitude(5, fResist)
weaknessSpell.SetNthEffectMagnitude(0, fResist)
weaknessSpell.SetNthEffectMagnitude(1, fResist)
weaknessSpell.SetNthEffectMagnitude(2, fResist)
weaknessSpell.SetNthEffectMagnitude(3, fResist)
weaknessSpell.SetNthEffectMagnitude(4, fResist)
weaknessSpell.SetNthEffectMagnitude(5, fResist)
_00E_FS_PsychosisWeaknessSP.Cast(Target, Target)
weaknessSpell.Cast(Target, Target)
Target.RemoveSpell(_00E_FS_PsychosisCounter_01_SP)
Target.RemoveSpell(_00E_FS_PsychosisCounter_02_SP)
EndFunction
;=====================================================================================
@ -60,9 +62,16 @@ EndFunction
Actor Property PlayerREF Auto
Spell Property _00E_FS_PsychosisWeaknessSP Auto
Spell Property _00E_FS_PsionicPushStaggerSP Auto
Sound Property MAGAlterationTelekinesisThrow Auto
Message Property _00E_FS_Psychosis_Weakened Auto
Message Property _00E_FS_Psychosis_Weakened Auto
Perk Property _00E_Class_Sinistrope_P08_C_Illusionist Auto
Spell Property _00E_FS_PsychosisWeaknessSP Auto
Spell Property _00E_FS_PsychosisWeaknessSP_NoSlow Auto
MagicEffect Property _00E_FS_PsychosisWeaknessVisualME Auto
Spell Property _00E_FS_PsychosisCounter_01_SP Auto
Spell Property _00E_FS_PsychosisCounter_02_SP Auto

@ -22,12 +22,14 @@ GlobalVariable Property _00E_Phasmalist_TankMode Auto
Message Property _00E_Phasmalist_NoApparitionCurrentlySummoned Auto
Perk Property _00E_Class_Phasmalist_P05_C_Violence_01 Auto
Actor Property PlayerREF Auto
Bool bCreatedFirstTrinket = false
Int iScriptVersion = 0
Int Property CURRENT_SCRIPT_VERSION = 1 AutoReadOnly
Int Property CURRENT_SCRIPT_VERSION = 2 AutoReadOnly
;=====================================================================================
@ -78,6 +80,11 @@ Function LoadGameFailsave()
RegisterTeleportKey()
((self as Quest) as _FS_Phasmalist_AffinityControlQuest).OnGameLoad() ; Obsolete, not needed anymore, so shut it down
bDoApparitionOnLoadGame = False
Else
If iScriptVersion < 2 && PlayerREF.HasPerk(_00E_Class_Phasmalist_P05_C_Violence_01) && IsApparitionSpawned()
SummonApparition(PlayerREF, False, True)
bDoApparitionOnLoadGame = False
EndIf
EndIf
iScriptVersion = CURRENT_SCRIPT_VERSION

@ -1,43 +1,37 @@
Scriptname FrostSlowFix extends activemagiceffect
{Behebt den Fehler, dass die Verlangsamung von Frostzaubern nicht funktioniert, indem das SpeedMult-Attribut durch kurzzeitige Änderung des InventoryWeight geupdatet wird.}
Keyword Property MagicSlowDownTarget Auto
MagicEffect Property FrostSlowFFAimed Auto
MagicEffect Property FrostSlowConcAimed Auto
MagicEffect Property FrostSlowFFContact Auto
MagicEffect Property FrostSlowFFSelfArea100 Auto
float speed
float basespeed
float slowspeed
Event OnEffectStart(Actor akTarget, Actor akCaster)
If akTarget.GetBaseActorValue("Speedmult") > akTarget.GetBaseActorValue("Fame") ;ensures that the speedmult gets only halved once
basespeed=akTarget.GetBaseActorValue("Speedmult")
akTarget.SetActorValue("Fame", basespeed)
slowspeed=akTarget.GetBaseActorValue("Speedmult")/2
akTarget.SetActorValue("Speedmult", slowspeed)
EndIf
akTarget.ModActorValue("InventoryWeight", -0.1)
Utility.Wait(0.01)
akTarget.ModActorValue("InventoryWeight", 0.1)
Actor Target
Endevent
Event OnEffectStart(Actor akTarget, Actor akCaster)
Target = akTarget
Float fBaseSpeed = Target.GetBaseActorValue("Speedmult")
If fBaseSpeed > Target.GetBaseActorValue("Fame") ; ensures that the speedmult gets only halved once
Target.SetActorValue("Fame", fBaseSpeed)
Target.SetActorValue("Speedmult", fBaseSpeed * 0.5)
ForceSpeedMultUpdate()
EndIf
EndEvent
Event OnEffectFinish(Actor akTarget, Actor akCaster)
If (akTarget.HasMagicEffect(FrostSlowFFAimed)||akTarget.HasMagicEffect(FrostSlowConcAimed)||akTarget.HasMagicEffect(FrostSlowFFContact)||akTarget.HasMagicEffect(FrostSlowFFSelfArea100))==0
basespeed=akTarget.GetBaseActorValue("Fame")
akTarget.SetActorValue("Speedmult", basespeed)
akTarget.SetActorValue("Fame", 0)
If Target == None ; version update
Target = akTarget
EndIf
akTarget.ModActorValue("InventoryWeight", -0.1)
Utility.Wait(0.01)
akTarget.ModActorValue("InventoryWeight", 0.1)
Endevent
If Target.HasMagicEffectWithKeyword(MagicSlowDownTarget) == False
Target.SetActorValue("Speedmult", Target.GetBaseActorValue("Fame"))
Target.SetActorValue("Fame", 0)
ForceSpeedMultUpdate()
EndIf
EndEvent
Function ForceSpeedMultUpdate()
Target.ModActorValue("InventoryWeight", -0.1)
Utility.Wait(0.01)
Target.ModActorValue("InventoryWeight", 0.1)
EndFunction

@ -10,21 +10,24 @@ Ingredient Property MothWingMonarch Auto
Ingredient Property Garlic Auto
Message Property FS_NQ05_AlchemyMessagebox Auto
Event OnActivate(objectReference akActionRef)
Bool bActivationBlocked = False
If (akActionRef == PlayerREF && FS_NQ05.GetStage() < 40 && FS_NQ05.GetStage() >= 30)
int iButton = FS_NQ05_AlchemyMessagebox.Show()
if iButton == 0
PlayerREF.RemoveItem(Nirnroot, 1)
PlayerREF.RemoveItem(SkeeverTail, 1)
PlayerREF.RemoveItem(MothWingMonarch, 1)
PlayerREF.RemoveItem(Garlic, 1)
PlayerREF.RemoveItem(FS_NQ05_Rezept, 1)
FS_NQ05.SetStage(40)
ElseIf iButton == 1
Return
Event OnActivate(ObjectReference akActionRef)
If akActionRef == PlayerREF && _00E_PlayerhousingMaster.ReferenceCanBeActivated(Self) && bActivationBlocked == False
bActivationBlocked = True
Int qStage = FS_NQ05.GetStage()
If qStage >= 30 && qStage < 40
If FS_NQ05_AlchemyMessagebox.Show() == 0
PlayerREF.RemoveItem(Nirnroot, 1)
PlayerREF.RemoveItem(SkeeverTail, 1)
PlayerREF.RemoveItem(MothWingMonarch, 1)
PlayerREF.RemoveItem(Garlic, 1)
PlayerREF.RemoveItem(FS_NQ05_Rezept, 1)
FS_NQ05.SetStage(40)
EndIf
EndIf
Endif
bActivationBlocked = False
EndIf
EndEvent

@ -9,21 +9,23 @@ Ingredient Property FrostMirriam Auto
Potion Property FoodBananenschnaps Auto
Message Property _00E_FS_NQ07_AlchemyMessagebox Auto
Bool bActivationBlocked = False
Event OnActivate(objectReference akActionRef)
If (akActionRef == PlayerREF && FS_NQ07.GetStage() == 115)
int iButton = _00E_FS_NQ07_AlchemyMessagebox.Show()
if iButton == 0
PlayerREF.RemoveItem(FoodMead, 1)
PlayerREF.RemoveItem(FrostMirriam, 2)
PlayerREF.RemoveItem(FoodBananenschnaps, 1)
PlayerREF.RemoveItem(_00E_FS_NQ07_Rezept, 1)
FS_NQ07.SetStage(120)
ElseIf iButton == 1
Return
Event OnActivate(ObjectReference akActionRef)
If akActionRef == PlayerREF && _00E_PlayerhousingMaster.ReferenceCanBeActivated(Self) && bActivationBlocked == False
bActivationBlocked = True
If FS_NQ07.GetStage() == 115
If _00E_FS_NQ07_AlchemyMessagebox.Show() == 0
PlayerREF.RemoveItem(FoodMead, 1)
PlayerREF.RemoveItem(FrostMirriam, 2)
PlayerREF.RemoveItem(FoodBananenschnaps, 1)
PlayerREF.RemoveItem(_00E_FS_NQ07_Rezept, 1)
FS_NQ07.SetStage(120)
EndIf
EndIf
EndIf
bActivationBlocked = False
EndIf
EndEvent

@ -0,0 +1,52 @@
Scriptname FXWitchlightAttachSCRIPT extends ActiveMagicEffect conditional
{Attaches and manages witchlights's fx}
VisualEffect Property WitchlightFXAttachEffect Auto
Spell Property WispDrainAttack Auto
Sound Property NPCWitchlightAttackM Auto
Actor Property PlayerREF Auto
ObjectReference selfRef
Event OnEffectStart(Actor Target, Actor Caster)
selfRef = caster
; Small version update.
; The new script properties do not get auto-filled if the NPC ref has been already inited
If PlayerREF == None
PlayerREF = Game.GetPlayer()
EndIf
If WispDrainAttack == None
WispDrainAttack = Game.GetFormFromFile(0x00091F78, "Skyrim.esm") as Spell
EndIf
If NPCWitchlightAttackM == None
NPCWitchlightAttackM = Game.GetFormFromFile(0x00036E7E, "GavrantFixes_210510.esp") as Sound
EndIf
;USKP 2.0.1 - Stop this from attaching to the player.
If selfRef == PlayerREF
Dispel()
Return
EndIf
; only attack FX once the 3D is loaded
Int iLoadCountdown = 50
While selfRef.Is3DLoaded() == False && iLoadCountdown > 0
iLoadCountdown -= 1
EndWhile
;USKP 2.0.2 - So despite ALL THAT above, we still need to check this. Stupid.
If selfRef.Is3DLoaded()
WitchlightFXAttachEffect.Play(selfRef, -1)
EndIf
EndEvent
Event OnSpellCast(Form akSpell)
If akSpell == WispDrainAttack
NPCWitchlightAttackM.Play(selfRef)
EndIf
EndEvent
Event OnEffectFinish(Actor Target, Actor Caster)
WitchlightFXAttachEffect.Stop(selfRef)
EndEvent
Loading…
Cancel
Save