DDProductions83 Posted June 5, 2014 Share Posted June 5, 2014 Lol heres a thought, I thought he wa transforming BACK into a wood elf after combat not during the transformation, it could be combat screwing it up so add Utility.wait(3.0) actorproperty.setrace(werewolfbeastrace) after the werewolfchangefx, that should force him to be set as werewolf though it could get screwy if combat ends in the next 3 seconds lol Link to comment Share on other sites More sharing options...
sp0ckrates Posted June 8, 2014 Share Posted June 8, 2014 Did you try loading an earlier save (one made before you first added the script)? I've noticed when testing scripts in game that scripts sometimes do not update unless an earlier save is used. Link to comment Share on other sites More sharing options...
thisisheffner Posted June 12, 2014 Author Share Posted June 12, 2014 Sorry for the delay in response. A short vacation kept my attention. Alas, even when applied to an earlier save, the script doesn't appear to have changed the same problem I have been having. Should I extend the wait time after the transformation? This is where the script currently stands: Scriptname FollowerWerewolfTransformAliasScript extends Actor SPELL Property WerewolfChangeFX Auto Actor Property actorproperty Auto race property raceyouwant auto race property secondaryrace auto Event OnCombatStateChanged(Actor akTarget, int aeCombatState) if (aeCombatState == 0) actorproperty.setrace(raceyouwant) unregisterforupdate() elseif (aeCombatState == 1) registerforupdate(3.0) endif endevent event onupdate() float ActorHealth2 = actorproperty.GetAVPercentage("Health") if (ActorHealth2 < 0.4) werewolfchangefx.cast(actorproperty) Utility.Wait(3.0) actorproperty.setrace(secondaryrace) unregisterforupdate() endif endevent Link to comment Share on other sites More sharing options...
thisisheffner Posted June 12, 2014 Author Share Posted June 12, 2014 I made some more changes to the script only now he'll change in to werewolf form and just stand there. Enemies won't target him nor will he target them...this is what I came up with after perusing the CK wiki. Thoughts on what to do? SPELL Property WerewolfChangeFX Auto Actor Property actorproperty Auto race property raceyouwant auto race property secondaryrace auto Event OnHit(ObjectReference akAggressor, Form akSource, Projectile akProjectile, bool abPowerAttack, bool abSneakAttack, bool abBashAttack, bool abHitBlocked) float ActorHealth2 = actorproperty.GetAVPercentage("Health") if (ActorHealth2 < 0.4) werewolfchangefx.cast(actorproperty) actorproperty.setrace(secondaryrace) actorproperty.SetRelationshipRank(Game.GetPlayer(), 3) registerforupdate(3.0) endif EndEvent event onupdate() float ActorHealth2 = actorproperty.GetAVPercentage("Health") if (ActorHealth2 >= 0.9) actorproperty.setrace(raceyouwant) actorproperty.SetRelationshipRank(Game.GetPlayer(), 3) unregisterforupdate() endif endevent Link to comment Share on other sites More sharing options...
sp0ckrates Posted June 12, 2014 Share Posted June 12, 2014 You might need to add a line to the script to add the NPC to the player's faction and to the werewolf faction. Enemies of either faction might then attack the NPC and the NPC might then no longer remain neutral. Let us know if that works. Link to comment Share on other sites More sharing options...
thisisheffner Posted June 12, 2014 Author Share Posted June 12, 2014 Alas, even setting the follower to those factions doesn't appear to work...I wish I knew more about scripting so that I could contribute more, but I do appreciate both of yours both. :) Here is the script as it stands currently: Scriptname FollowerWerewolfTransformAliasScript extends Actor SPELL Property WerewolfChangeFX Auto Actor Property actorproperty Auto race property raceyouwant auto race property secondaryrace auto Faction property WerewolfFaction auto Faction property PlayerFaction auto Event OnHit(ObjectReference akAggressor, Form akSource, Projectile akProjectile, bool abPowerAttack, bool abSneakAttack, bool abBashAttack, bool abHitBlocked) float ActorHealth2 = actorproperty.GetAVPercentage("Health") if (ActorHealth2 < 0.4) werewolfchangefx.cast(actorproperty) actorproperty.setrace(secondaryrace) actorproperty.SetRelationshipRank(Game.GetPlayer(), 3) actorproperty.SetFactionRank(WerewolfFaction, 1) actorproperty.SetFactionRank(PlayerFaction, 1) registerforupdate(3.0) endif EndEvent event onupdate() float ActorHealth2 = actorproperty.GetAVPercentage("Health") if (ActorHealth2 >= 0.9) actorproperty.setrace(raceyouwant) actorproperty.SetRelationshipRank(Game.GetPlayer(), 3) actorproperty.SetFactionRank(PlayerFaction, 1) actorproperty.RemoveFromFaction(WerewolfFaction) unregisterforupdate() endif endevent Link to comment Share on other sites More sharing options...
sp0ckrates Posted June 13, 2014 Share Posted June 13, 2014 (edited) It will be really something if you get it to work! OK, if we are sure factions are not the cause, maybe there is an issue with the NPC's AI? For example, there is a way to use the command console to remove AI from NPCs so that they just stand in one place, don't speak and take no action. What you are describing sounds similar. Edited June 13, 2014 by sp0ckrates Link to comment Share on other sites More sharing options...
sp0ckrates Posted June 13, 2014 Share Posted June 13, 2014 So perhaps it might help to examine the scripts in the game used to turn an NPC into a werewolf? In the Companions quest Proving Honor, Farkas uses beast form to transform from a Nord. After transforming, he takes out a group of five Silver Hand. Link to comment Share on other sites More sharing options...
sp0ckrates Posted June 21, 2014 Share Posted June 21, 2014 ThisIsHeffner: Did you get it figured out? Link to comment Share on other sites More sharing options...
sp0ckrates Posted June 30, 2014 Share Posted June 30, 2014 I figured it out, if you want to know. :) Link to comment Share on other sites More sharing options...
Recommended Posts