Jump to content

Recommended Posts

I dont know how to make my custom hat to lose durability when worn just like a winter hat. I tried to look in the game files but  I didint see anything that could help me. If anyone could help me that would be awesome!

The hats of DST are all adorably stuffed in hats.lua like a clown car, so I was able to scavange around, and I assume these lines of code are responsible for depleting the winter's hat durability when it is in use:

inst:AddComponent("fueled")
inst.components.fueled.fueltype = FUELTYPE.USAGE
inst.components.fueled:InitializeFuelLevel(TUNING.WINTERHAT_PERISHTIME)
inst.components.fueled:SetDepletedFn(inst.Remove)
  • Like 2

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
×
  • Create New...