mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Fix -Wtype-limits warnings and remove disabling of -Wtype-limits
This commit is contained in:
parent
5038b9aaec
commit
3993102e88
6 changed files with 20 additions and 18 deletions
|
@ -1766,7 +1766,11 @@ void Map::transformLiquids(std::map<v3s16, MapBlock*> & modified_blocks)
|
|||
content_t new_node_content;
|
||||
s8 new_node_level = -1;
|
||||
s8 max_node_level = -1;
|
||||
u8 range = rangelim(nodemgr->get(liquid_kind).liquid_range, 0, LIQUID_LEVEL_MAX+1);
|
||||
|
||||
u8 range = nodemgr->get(liquid_kind).liquid_range;
|
||||
if (range > LIQUID_LEVEL_MAX+1)
|
||||
range = LIQUID_LEVEL_MAX+1;
|
||||
|
||||
if ((num_sources >= 2 && nodemgr->get(liquid_kind).liquid_renewable) || liquid_type == LIQUID_SOURCE) {
|
||||
// liquid_kind will be set to either the flowing alternative of the node (if it's a liquid)
|
||||
// or the flowing alternative of the first of the surrounding sources (if it's air), so
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue