I want to change item`s id value by lua script.
example,
Add two item on json file.
Item1s id is "test", and item2s id is “test_on.”
Ok. I write lua script like below.
function test_off()
type = game.item_type(item)
type["id"] = type["id"] + "_on"
end
game.register_iuse(“TESTOFF”, test_off)
but, this script didn`t work.
How to change id value of item by lua script?