Water As A Resource ZpmEdition deprecated

by ZpmFred

Turns Water into a non infinite resource. Water bodies get removed and replaced by solid ground. Offshore Drains allow water & oil to be put back into these depleted areas.

4 years ago
0.17
5

b Infinite scan, revomed fluid and Warptorio compatibility

4 years ago
(updated 4 years ago)

Hello!
Just some little things to change here:

First, il you put an offshore pump on a realy big lake, or on the sea, the tile scan will take a long long time, if not forever

Second, if you remove a mod that create fluid lake, and you've previously put an offshore pump on it, the game crash, throwing an error (the called entityAPI is invalid)

I fixed this two in this file: [control.lua]
https://pastebin.com/fQk3buJ9
You can find what changes I made near the label "Dexy Edit"
If you can make an option that will define the max tiles scan, it will be realy nice!

Now, I got a little problem with Warptorio2
If I put a pump on a lake, warp on a new planet, and put another pump on a lake with nearly the same coordinate in a different surface, the game doesn't reconize the lake like a new lake
I will try to take a look on this

Edit:
It's done! Now, when you warp, all created lakes is removed :)
Updated the pastebin link for Warptorio compatibility

Edit2:
Added many nullcheck that caused the game to crash

New response