Fix lag when lavacooling sets lots of nodes

Do you want to have the changed lavacooling in minetest_game?

yes, please change the lavacooling
10
67%
no, I don't like this change
1
7%
no, I want that creating lavacooling mountains is impossible
1
7%
I hate you
3
20%
 
Total votes : 15

Hybrid Dog
Member
 
Posts: 2460
Joined: Thu Nov 01, 2012 12:46

Fix lag when lavacooling sets lots of nodes

by Hybrid Dog » Tue Apr 22, 2014 20:18

I edited the lavacooling function that it uses vmanip if many nodes become cooled:
https://github.com/HybridDog/minetest_g ... s.lua#L146
This greatly decreases server lag when e.g. someone makes a lavacooling mountain.

Sometimes I can see such a mountain created with lavacooling on a server, often it's made by me but not every time.
Image
Image
I have much more pictures, tell me if you want to see them, some of the mountains are much bigger.

https://github.com/HybridDog/lavacoolin ... 9b5ee1fe9e

I changed the code of my lavacooling mod that creating such a mountain with a lava and water bucket (or something else with lava and water) doesn't cause a server lag that it needs to become shut down because it's fairly impossible to continue playing there without disabling lavacooling (except on fast computers).
After that l changed the lavacooling of default in my version of minetest_game. Calinou's carbone game uses the code.
Attachments
somewhere1.png
somewhere1.png (236.04 KiB) Viewed 1576 times
jeijamap_1.png
jeijamap_1.png (152.24 KiB) Viewed 1577 times
Last edited by Hybrid Dog on Sat Sep 10, 2016 12:13, edited 4 times in total.
 

User avatar
Krock
Member
 
Posts: 3598
Joined: Thu Oct 03, 2013 07:48
GitHub: SmallJoker

Re: reduce the lag of creating lavacooling mountains

by Krock » Wed Apr 23, 2014 11:21

Lava-water-stone mountains on no-rule-servers: HAHA! trololo system ressources :PP !!111!11!!1!1
Lava-water-stone mountains on serious servers: No- please not.
A speedup can be produced with faster water flowing and maybe using voxelmanip for it.
Newest Win32 builds - Find a mod - All my mods
ALL YOUR DONATION ARE BELONG TO PARAMAT (Please support him and Minetest)
New DuckDuckGo !bang: !mtmod <keyword here>
 

User avatar
HeroOfTheWinds
Member
 
Posts: 470
Joined: Wed Apr 23, 2014 23:16
GitHub: HeroOfTheWinds
IRC: WindHero

Re: reduce the lag of creating lavacooling mountains

by HeroOfTheWinds » Thu Apr 24, 2014 03:40

I'm not sure if it's just my terrible internet, but it always seems to me that lava creates tremendous lag whenever I'm near it. Anything to lessen this is appreciated.
Nam ex spatio, omnes res venire possunt.
Why let the ground limit you when you can reach for the sky?
Back to college now, yay for sophomore year schedules. :P
 

Hybrid Dog
Member
 
Posts: 2460
Joined: Thu Nov 01, 2012 12:46

Re: reduce the lag of creating lavacooling mountains

by Hybrid Dog » Thu Apr 24, 2014 10:41

Krock wrote:...and maybe using voxelmanip for it.

I thought the vote was made for this... maybe I understood something wrong


HeroOfTheWinds wrote:I'm not sure if it's just my terrible internet, but it always seems to me that lava creates tremendous lag whenever I'm near it. Anything to lessen this is appreciated.

Does the server use special mods?
 

paramat
Member
 
Posts: 2662
Joined: Sun Oct 28, 2012 00:05
GitHub: paramat

Re: reduce the lag of creating lavacooling mountains

by paramat » Thu Apr 24, 2014 14:22

When i added lavacooling to watershed, i noticed that default mod lavacooling has an interval of 1 and a chance of 1. So every second, every lava node has all it's neighbours checked for water nodes, this results in instant and fast lavacooling, but also large processing spikes, the interval and chance should be changed to avoid this, for slower and more gradual cooling.
 

User avatar
HeroOfTheWinds
Member
 
Posts: 470
Joined: Wed Apr 23, 2014 23:16
GitHub: HeroOfTheWinds
IRC: WindHero

Re: reduce the lag of creating lavacooling mountains

by HeroOfTheWinds » Thu Apr 24, 2014 22:37

Hybrid Dog wrote:
HeroOfTheWinds wrote:I'm not sure if it's just my terrible internet, but it always seems to me that lava creates tremendous lag whenever I'm near it. Anything to lessen this is appreciated.

Does the server use special mods?


The only one that I can think of that would affect that is the mod (can't remember the name) that causes particles to fly up from the lava, as well as add a flowing water sound when water is near.
Nam ex spatio, omnes res venire possunt.
Why let the ground limit you when you can reach for the sky?
Back to college now, yay for sophomore year schedules. :P
 

User avatar
Jordach
Member
 
Posts: 4412
Joined: Mon Oct 03, 2011 17:58
GitHub: Jordach
IRC: Jordach
In-game: Jordach

Re: reduce the lag of creating lavacooling mountains

by Jordach » Fri Apr 25, 2014 06:59

Will take a look into it via BFD, have a feeling it's the internet side and not server: in BFD I have seen any lag with lavacooling, due to being 64bit. And playing locally.
 

Hybrid Dog
Member
 
Posts: 2460
Joined: Thu Nov 01, 2012 12:46

Re: reduce the lag of creating lavacooling mountains

by Hybrid Dog » Fri Apr 25, 2014 11:27

HeroOfTheWinds wrote:
Hybrid Dog wrote:
HeroOfTheWinds wrote:I'm not sure if it's just my terrible internet, but it always seems to me that lava creates tremendous lag whenever I'm near it. Anything to lessen this is appreciated.

Does the server use special mods?


The only one that I can think of that would affect that is the mod (can't remember the name) that causes particles to fly up from the lava, as well as add a flowing water sound when water is near.

maybe it's the old particles mod
 

User avatar
HeroOfTheWinds
Member
 
Posts: 470
Joined: Wed Apr 23, 2014 23:16
GitHub: HeroOfTheWinds
IRC: WindHero

Re: reduce the lag of creating lavacooling mountains

by HeroOfTheWinds » Fri Apr 25, 2014 21:09

Hybrid Dog wrote:maybe it's the old particles mod

I looked up the mods on the server. The mod in question is [dplus].
Nam ex spatio, omnes res venire possunt.
Why let the ground limit you when you can reach for the sky?
Back to college now, yay for sophomore year schedules. :P
 

Hybrid Dog
Member
 
Posts: 2460
Joined: Thu Nov 01, 2012 12:46

Re: reduce the lag of creating lavacooling mountains

by Hybrid Dog » Thu May 22, 2014 18:50

https://github.com/HybridDog/minetest_g ... d43fbed3e3
I need to change the "[lavacooling]" message and use minetest.log.
 

User avatar
Calinou
Member
 
Posts: 3124
Joined: Mon Aug 01, 2011 14:26
GitHub: Calinou
IRC: Calinou
In-game: Calinou

Re: reduce the lag of creating lavacooling mountains

by Calinou » Thu May 22, 2014 19:06

Carbone implemented the lava cooling changes (which also seems to prevent sound spam), thank you. It also logs it.
 

Hybrid Dog
Member
 
Posts: 2460
Joined: Thu Nov 01, 2012 12:46

Re: reduce the lag of creating lavacooling mountains

by Hybrid Dog » Thu Oct 23, 2014 13:08

Calinou wrote:Carbone implemented the lava cooling changes (which also seems to prevent sound spam), thank you. It also logs it.
I don't know if you changed it at carbone yet, I fixed the liquid flow update:
https://github.com/HybridDog/minetest_g ... 408e43R232
 

User avatar
Krock
Member
 
Posts: 3598
Joined: Thu Oct 03, 2013 07:48
GitHub: SmallJoker

Re: reduce the lag of creating lavacooling mountains

by Krock » Thu Oct 23, 2014 16:08

Hybrid Dog wrote:I don't know if you changed it at carbone yet, I fixed the liquid flow update:
https://github.com/HybridDog/minetest_g ... 408e43R232

Thanks.
Newest Win32 builds - Find a mod - All my mods
ALL YOUR DONATION ARE BELONG TO PARAMAT (Please support him and Minetest)
New DuckDuckGo !bang: !mtmod <keyword here>
 

Dragonop
Member
 
Posts: 1178
Joined: Tue Oct 23, 2012 12:59
GitHub: Dragonop
IRC: Dragonop
In-game: Dragonop

Re: reduce the lag of creating lavacooling mountains

by Dragonop » Sat Oct 25, 2014 22:42

Why the colors in the pictures look so bright?
 

User avatar
Krock
Member
 
Posts: 3598
Joined: Thu Oct 03, 2013 07:48
GitHub: SmallJoker

Re: reduce the lag of creating lavacooling mountains

by Krock » Sun Oct 26, 2014 09:28

Dragonop wrote:Why the colors in the pictures look so bright?

You can take screenshots at night and make them brighter. It's not fully dark at night, that's why it's possible.
Newest Win32 builds - Find a mod - All my mods
ALL YOUR DONATION ARE BELONG TO PARAMAT (Please support him and Minetest)
New DuckDuckGo !bang: !mtmod <keyword here>
 


Return to Minetest Features

Who is online

Users browsing this forum: No registered users and 8 guests

cron