Started by
uhmshadow
on
Topic category: Help with Minecraft modding (Java Edition)
How would you go about making player temperature (like in a heat or cold mod), varying in certain biomes and around certain blocks/items. And with overlays? Just dont know how to or where to start.
Edited by uhmshadow on Sun, 02/20/2022 - 21:09
start with the player variable (or nbt, but don't do nbt) called bodyTemperature I suppose
1.make all textures for temperatures; hot, cold, neutral, and stuff inbetween. most mods with temperature use a circle above the hotbar
2.make a new *OVERLAY* not gui and put all of the art on the screen, it doesnt matter where rn.
3.save the overlay for now and make a new procedure. type in the searchbar "temperature" and take out the first result
4.go the the minecraft wiki and get biome temperatures (https://minecraft.fandom.com/wiki/Biome)
5. make an amount of procedures = the number of textures you made
6. do this for every procedure
(and Else; Return false.)
7.assign each procedure to its respective temperature image display condition (double click on each image) in the UI.
8. stack all of the textures atop eachother in the UI (oh yeah, make sure the textures have the same shape)
9.make another procedure that tells what temp you are in and applies the effects, like this: (and make the global trigger "loaded entity tick and make this only apply to players)
this should work... i think
holy cheese balls (idk if i can cus in here lol) this is a perfect example of helping. i will come back to this form if i have any troubles. thank you and expect a thirst mod with maybe temperature in it ;)
I need something similar to this but when your in a cold biome/place I need your temp to start decreasing, or the opposite when your in a warm biome.
oh so not just to jump to it. maybe it would be better to make multiple overlays as a bootleg animation for the different temperature when going down/up. then assigning those procedures but instead of making one really cold one a one really hot one, make many as they start to go up or down. not sure if this works :/ just a thought
what would be nice is a procedure to Set Temperature on a block (air or wtv) so we could make Heaters and ACs :D
is this possible maybe?
im going to do a overlay for my mod that will show a small termometer that chance the bar with the biome temperature uhmshadow, if u want more help let me know