Jump to content

Scripting Noob in Need of Help from The Pros


Recommended Posts

Chris20201986 wrote: "I need to have an activator that returns all ingredients to the alchemy wardrobe. .. What did I do wrong?"
and later " the player has any items listed in the formlist and removing them to the wardrobe
"

https://www.creationkit.com/index.php?title=RemoveItem_-_ObjectReference

Questions:
What is source?
What is destination?


Think about it and have a look to the wiki link above!

Link to comment
Share on other sites

  • Replies 44
  • Created
  • Last Reply

Top Posters In This Topic

I figured it out. This is the script I wrote to remove items from the player's inventory that are in a formlist and deposit into a container.

 

 

Scriptname JLReturnIngredients extends ObjectReference
ObjectReference Property JLS_Alchemy_Wardrobe1 Auto
FormList Property JL_Ingredients_List Auto
Actor Property PlayerRef auto
Event OnActivate(objectReference akActivator)
If akActivator == Game.GetPlayer()
Int num = PlayerRef.GetItemCount(JL_Ingredients_List)
akActivator.RemoveItem(JL_Ingredients_List,num,true,JLS_Alchemy_Wardrobe1)
EndIf
EndEvent

Edited by Chris20201986
Link to comment
Share on other sites

Next project. Say I have a pickaxe. It's the only weapon like it in the game. It has the ability to mine stalhrim. Upon the player retrieving item, and enchantment should be learned to be able to enchant other pickaxes with the ability to mine stalhrim. How should I go about this? Or maybe and instant thing? Like as soon as the play has the item their other pickaxes become usable for mining stalhrim? I would hate to have to disenchant and loose the ancient nordic pickaxe just to learn the enchantment. No skse use.
Link to comment
Share on other sites

You want other pickaxes to mine stalhrim but only after obtaining the ancient nordic pickaxe?

 

Add a small script to a player alias. Use an inventory event filter for the ancient nordic pickaxe.

When the ancient nordic pickaxe is added to inventory, add all the other pickaxe items to the DLC2 formlist that the stalhrim nodes use for the allowed tools. No SKSE needed for that.

 

As far as an actual enchantment, no idea.

Link to comment
Share on other sites

  • 2 months later...
  • Recently Browsing   0 members

    • No registered users viewing this page.

×
×
  • Create New...