I have been trying to modify a vanilla item.
My intention is that when the item is destroyed it will give another item in the inventory, just like the water bottle does.
In order to do that I know that I have to add the ReplaceOnDeplete attribute but the ways that I have been trying have not worked.
I just have lua left to try it with, although I have already tried this lines of code.
function UpgradePropaneTank()
ScriptManager().instance:getItem("Base.PropaneTank"):setReplaceOnDeplete("EmptyTank");
end
Events.OnGameBoot.Add(UpgradePropaneTank);
I have used OnLoad and OnGameStart