The tile temperature is set during map generation, and the API allows us to get that temperature. However...
It would be very desirable to have an additional API call to get current temperature based on time of day (map brightness).
For example, when the sun sets, I would expect temperatures to start dropping, eventually reaching a minimum based on tile elevation, etc. When sun rises, temperatures start to increase, reaching a peak around noon.
While I could code that sort of logic in to a mod, IMO it would be better for the game to provide it so that any mods wanting current tile temperature would get the same results without lots of code duplication. In addition, a mod trying to implement it has to access several values (elevation, brightness, etc) all of which need typecasting to Lua types.
Something like: TileProperties :: current_temperature
The default temperature would still be accessible via TileProperties :: temperature; it's useful to have that as it provides a rough average temperature for a tile.
[closed] Current tile temperature
- aubergine18
- Smart Inserter
- Posts: 1264
- Joined: Fri Jul 22, 2016 8:51 pm
- Contact:
[closed] Current tile temperature
Last edited by aubergine18 on Sat Aug 27, 2016 11:07 pm, edited 1 time in total.
Better forum search for modders: Enclose your search term in quotes, eg. "font_color" or "custom-input" - it prevents the forum search from splitting on hypens and underscores, resulting in much more accurate results.
Re: Current tile temperature
There is no "current temperature". A tile temperature is used purely to generate data at chunk generation and then never touched again. It doesn't change over time with daytime or any of that.
If you want to get ahold of me I'm almost always on Discord.
Re: Current tile temperature
@Rseding91: Well maybe the suggestion forum is a better place for this.
Could be placed near weather / seasons.
So if maybe a temperature change during the daytime is implemented, please add a mod interface for that
@aubergine18: Maybe the quickest way would be implementing it by a mod and look how it goes.
There is a mod called Winterio (https://mods.factorio.com/mods/AnonymoScoot/Winterio) which could be took as example for cold/snowy weather,
Greetings steinio
Could be placed near weather / seasons.
So if maybe a temperature change during the daytime is implemented, please add a mod interface for that

@aubergine18: Maybe the quickest way would be implementing it by a mod and look how it goes.
There is a mod called Winterio (https://mods.factorio.com/mods/AnonymoScoot/Winterio) which could be took as example for cold/snowy weather,
Greetings steinio
- aubergine18
- Smart Inserter
- Posts: 1264
- Joined: Fri Jul 22, 2016 8:51 pm
- Contact:
Re: Current tile temperature
Yup, I'll look at that mod and also MoWeather mod.
Better forum search for modders: Enclose your search term in quotes, eg. "font_color" or "custom-input" - it prevents the forum search from splitting on hypens and underscores, resulting in much more accurate results.