Jump to content

Creation kit: how to add torches recipe


Nedellis

Recommended Posts

. The tutorial is actually for a helmet or something, but torches should be pretty much the same.

 

Or this one. It's text based.

Edited by MShoap13
Link to comment
Share on other sites

You are correct. Torches are apparently only stored as Light objects and don't have a Misc. object reference. There's no Light category under any of the crafting benches (that may or may not be appendable, probably is though).

 

I did find this mod (Craftable Torches). It gets around this issue by creating a "TorchDummy" Misc. item that swaps itself out for a number of actual torches and then making a crafting recipe for the dummy item. The source code for the script is included in the download.

Link to comment
Share on other sites

You are correct. Torches are apparently only stored as Light objects and don't have a Misc. object reference. There's no Light category under any of the crafting benches (that may or may not be appendable, probably is though).

 

I did find this mod (Craftable Torches). It gets around this issue by creating a "TorchDummy" Misc. item that swaps itself out for a number of actual torches and then making a crafting recipe for the dummy item. The source code for the script is included in the download.

 

 

I know it. But i'm not able to reproduce the effect. Don't know why. I do exatcly what he do.

So i have open this topic. I'd like to read a step-by-step procedure. And understand something about the script behind that mod.

Edited by Nedellis
Link to comment
Share on other sites

Scriptname TorchCraftingScript extends ObjectReference  

MiscObject Property Torch01Dummy  Auto  

Light Property Torch01  Auto  

Event OnContainerChanged(ObjectReference akNewContainer, ObjectReference akOldContainer)
 if akNewContainer == Game.GetPlayer()
   Game.GetPlayer().AddItem(Torch01, 5, true)
   Game.GetPlayer().RemoveItem(Torch01Dummy, 1, true)
 endif
endEvent

 

 

This is the script written for craftable torches. But it has a bug. When new torches are crafted and equipped the model disappear but light is casted. If you draw your weapon the model will be loaded correctly.

 

Do this to reproduce the bug:

 

-leave all torches to the ground

-craft torches

-equip

Edited by Nedellis
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...