Jump to content

About skill trees


 Share

Recommended Posts

Salutations, I am relatively new to DST modding
What's concerning me is this in prefabs/skilltree_defs.lua as it just crashes the custom skill trees under trying to index a bool and what I have to do is set it back to nil and everything works just as fine

setmetatable(SkillTree.SKILLTREE_DEFS, {
    __newindex = function(t, k, v)
        v.modded = true
        rawset(t, k, v)
    end,
})

I was wondering why this should cause issues at all as doing type(table) indeed identifies it as a table, but trying to index it would crash the game

Link to comment
Share on other sites

On 3/18/2023 at 7:30 PM, Cyachao said:

Salutations, I am relatively new to DST modding
What's concerning me is this in prefabs/skilltree_defs.lua as it just crashes the custom skill trees under trying to index a bool and what I have to do is set it back to nil and everything works just as fine

setmetatable(SkillTree.SKILLTREE_DEFS, {
    __newindex = function(t, k, v)
        v.modded = true
        rawset(t, k, v)
    end,
})

I was wondering why this should cause issues at all as doing type(table) indeed identifies it as a table, but trying to index it would crash the game

SKILLTREE_DEFS is a table that should include only data for skills as assumed by the game, but the modded = true field messes things up. This is on Klei's part.

I've reported the issue in the Bug Tracker.

Link to comment
Share on other sites

8 hours ago, Hornete said:

SKILLTREE_DEFS is a table that should include only data for skills as assumed by the game, but the modded = true field messes things up. This is on Klei's part.

I've reported the issue in the Bug Tracker.

Alright, thanks for clarifying!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...