Jump to content

DOWNLOAD MODS

Are you looking for something shiny for your load order? We have many exclusive mods and resources you won't find anywhere else. Start your search now...

LEARN MODDING

Ready to try your hand at making your own mod creations? Visit the Enclave, the original ES/FO modding school, and learn the tricks of the trade from veteran modders...

JOIN THE ALLIANCE

Membership is free and registering unlocks image galleries, project hosting, live chat, unlimited downloads, & more...

Dragon Priest bust / OnActivate Script Help


edhelsereg
 Share

Recommended Posts

I am trying to write a simple script whereby activating the Konahrik bust not only adds the ultra mask but also adds some other items. To limit the number of times the additional items can be acquired, I am applying a script to a quest alias of the bust activator. This way, once the quest completes, further activation of the bust adds and removes the mask, but doesn't add extra items anymore. It might be helpful to understand how the bust works, but I don't see any scripts attached to the center bust. This is what I have so far, as of now it is not working...

Scriptname KonahrikAcSCRIPT extends ReferenceAlias

Quest Property myQST Auto

Int Property SetToStage Auto

Armor Property Mask Auto

Armor Property robes Auto

Armor Property Gloves Auto

Armor Property boots Auto

Event onactivate(ObjectReference akActionRef)

Debug.Trace("Activated by " + akActionRef)

if (Game.GetPlayer().GetItemCount(mask) == 0)

myQST.setstage(SetToStage)

Game.GetPlayer().AddItem(robes, 1, true)

Game.GetPlayer().AddItem(Gloves, 1, true)

Game.GetPlayer().AddItem(boots, 1, true)

endIf

endEvent

The onactivate Event is connected to the DragonPriestMaskUltra01 Activator Alias. The stage is supposed to set to 100 and complete the [undocumented] quest so that you can only collect the extra items once.

Edited by edhelsereg
Link to comment
Share on other sites

New plan. I tried making a chest that requires a key and unlocks when you have konahrik in your inventory, but this script doesn't work either.

Scriptname KonahrikGearCheckSCRIPT extends ObjectReference

{unlocks chest if the ultra mask is in the player's inventory}

Armor Property Mask Auto

Event onactivate(ObjectReference akActionRef)

if (Game.GetPlayer().GetItemCount(Mask) == 1)

endIf

akActionRef.Lock(0)

endEvent

Any help would be greatly appreciated.

Edited by edhelsereg
Link to comment
Share on other sites

First post:

Are you getting the debug.trace message?

What your doing is, if the player does not have the mask, the stage is set and you get the equipment.

Second post:

The 'IF' condition does nothing.

You are trying to 'unlock' the activator of the chest, which would be the player. You need to just use:

Lock(0)

Both posts:

Do you have the properties attached to game objects correctly?

Link to comment
Share on other sites

The chest script is working now. Now it unlocks the chest rather than the player. haha

Scriptname KonahrikGearCheckSCRIPT extends ObjectReference

{unlocks chest if the ultra mask is in the player's inventory}

Armor Property Mask Auto

Event onactivate(ObjectReference akActionRef)

if akActionRef == Game.GetPlayer() && akActionRef.GetItemCount(Mask) > 0

Lock(false)

endIf

endEvent

Thanks for the help!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...