Jump to content

Recommended Posts

Hello! I am trying to make a custom character, but I am running into a problem which is I want them to be completely resistant to the cold, but over heat faster and take increased damage from overheating. If you know how to do this please tell me, and thank you in advance.

@jtkirby

Freezing disable:

-- When freezing (below 0)inst:ListenForEvent("startfreezing", function(inst, data)	-- Set back to 0	inst.components.temperature:SetTemperature(0)end)

Heat damage:

inst:ListenForEvent("healthdelta", function(inst, data)	if (data.cause == "hot") then -- When hurt by heat		inst.components.health:DoDelta(-1) -- Do more damage	endend)

@Blueberrys,

Thanks for this, the problem is that I am new to modding Don't Starve and I don't know what file to put this code in and where to put it.


@Blueberrys,

Thanks for this, the problem is that I am new to modding Don't Starve and I don't know what file to put this code in and where to put it.

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...