Jump to content

Custom Item Mod error


Recommended Posts

Hi! I recently received a copy of DST for my birthday and I've been really loving the game! The mod community is so big and thriving and I thought to make some mods myself for fun. So far I've been stuck trying to make custom items for my character. This is the error log I get:

 

[00:00:33]: [string "scripts/components/inventory.lua"]:638: attempt to index local 'inst' (a nil value)
LUA ERROR stack traceback:
    scripts/components/inventory.lua:638 in (method) GiveItem (Lua) <637-771>
    scripts/prefabs/player_common.lua:888 in (method) OnNewSpawn (Lua) <883-915>
    scripts/networking.lua:250 in () ? (Lua) <238-256>
    =[C]:-1 in (method) SendSpawnRequestToServer (C) <-1--1>
    scripts/mainfunctions.lua:1405 in (local) cb (Lua) <1403-1406>
    scripts/frontend.lua:598 in (method) DoFadingUpdate (Lua) <562-602>
    scripts/frontend.lua:650 in (method) Update (Lua) <610-760>
    scripts/update.lua:92 in () ? (Lua) <33-129>

 

I've been copying other custom item mods to use as reference and making sure they work before changing the details and art but I keep getting these errors. I've been following a guide and scouring the forums for similar topics but I can't seem to find an answer. I'd appreciate any help or input!

Thanks in advance for your time!!

Link to comment
Share on other sites

From the looks of it the mod is having a hard time giving your inventory item probably because its not part of the mod. It originates from here:

local start_inv = {
    "customitem",
}

That customitem needs to be in the modmain, and combined into one mod.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

Please be aware that the content of this thread may be outdated and no longer applicable.

×
  • Create New...