Pyrathas Posted January 25, 2018 Posted January 25, 2018 I'm making a player home mod for Evil characters and an Adult version: Thrallmire Keep and Thrallmire Keep Loverslab Expansion. The mod starts as a kill Necromancers quest, get Reward, go back, Accept the BYOH quest or refuse the power (fail). There are Prisoners in the Dungeon and a Boss. The Free prisoners are optional but here is the Kicker: Many switches only one frees them the others kill them (failed optional quest) Spawning Undead to swarm your only means of escape (evil laughter). Yes Later on a feature is given where if you killed a unique NPC, you have the option of having their remains brought to the crypt, and you resurrect them as thralls. In the Adult Version? Well, I would say Death is a release. Not a punishment right? Any help with references for coding would be great as I am just learning to code and finally got the Main Mod Questline to work (Aside from the scenes) and the BYOH script to work. Im trying to set up a scene where you see the Boss reanimate a dead corpse, then he summons undead that are lying on the ground to attack, in one scene, I got the Undead spawn to go on toggle, and the last scene is where the Former Master of the Keep, a Ghost named Micar the Corruptor asks you to rebuild the Keep in exchange for his secrets and the Power of the Keep. I can't seem to mirror the Valthume Opening scene... So right now Im trying to make a mod where an NPC when equipping Shackles is restrained and ignores Faction enemies (Player) and when a player flips a switch the NPC is free. Here is what I got so far: ScriptName _PyrShackle extends ObjectReference Keyword Property ActorTypeNPC auto ObjectReference property Shackle01 auto Int LeverPosition = 1 Int LeverPositionOld Function SetDefaultState() if (LeverPosition == 1) if akTarget.HasKeyword(ActorTypeNPC) akTarget.OnObjectEquipped(Shackle01) akTarget.SetRestrained() elseif (LeverPosition == -1) akTarget.OnObjectEquipped(Shackle01) akTarget.SetRestrained(false) endif LeverPositionOld = LeverPosition LeverPosition = 0 akTarget.OnObjectEquipped(Shackle01) akTarget.SetRestrained(false) EndFunction Event OnEffectStart(Actor akTarget, Actor akCaster) if akTarget.HasKeyword(ActorTypeNPC) akTarget.OnObjectEquipped(Shackle01) akTarget.SetRestrained() Event OnReset() SetDefaultState() if akTarget.HasKeyword(ActorTypeNPC) akTarget.OnObjectEquipped(Shackle01) akTarget.SetRestrained() EndEvent Event OnLoad() SetDefaultState() if akTarget.HasKeyword(ActorTypeNPC) akTarget.OnObjectEquipped(Shackle01) akTarget.SetRestrained() EndEvent Auto State Inactive Event OnActivate(ObjectReference akActivateRef) GoToState("Active") if akTarget.HasKeyword(ActorTypeNPC) akTarget.OnObjectEquipped(Shackle01) akTarget.SetRestrained(false) if (LeverPosition != 0) SetDefaultState() else if (LeverPositionOld == 1) if akTarget.HasKeyword(ActorTypeNPC) akTarget.OnObjectEquipped(Shackle01) akTarget.SetRestrained(false) LeverPosition = -1 else if akTarget.HasKeyword(ActorTypeNPC) akTarget.OnObjectEquipped(Shackle01) akTarget.SetRestrained() LeverPosition = 1 endif LeverPositionOld = 0 if akTarget.HasKeyword(ActorTypeNPC) akTarget.OnObjectEquipped(Shackle01) akTarget.SetRestrained(false) endif Utility.Wait(1) GoToState("Inactive") EndEvent EndState State Active EndState So yeah...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.