[FREE] Water Rise plugin

Status
This thread has been locked.

itsfsnow

Supreme
Feedback score
1
Posts
138
Reactions
31
Resources
0
After watching this video, I became inspired to create a plugin for this to play with my friends.

You have a 100x100 area, and the water level rises every now and again, depending on what you put in the cmd

Here is the commands:
/rise instant <amount> - this will instantly rise the water by whatever amount. you start @ level 60.
/rise timer <seconds> <amount> - this will rise automatically every how many seconds you set
/rise cancel - this will cancel your timer. I haven't tried setting a timer and then setting another one without cancelling, but I don't think it's a good idea.

To have permission to each of these you require the node 'waterrise.command'

Do not do this on existing worlds, as it will essentially destroy them by setting the world border & rising the water in that area. Create a new world under the level-type 'AMPLIFIED' for best experience.

I doubt anyone will want to use this, but there was no point in me just keeping the code to myself.

I don't know how to use github, so I just put the sourcecode in a .zip file below, along with a jar version built on 1.14.1, but in theory this should work on any version which supports:
  • the /fill command with the replace function
  • worldborders
Thanks for reading this thread, and if you do decide to check out the code comment anything which could be improved. Thanks!
 

Attachments

  • WaterRise.zip
    12.3 KB · Views: 586
PebbleHost
High performance, consistent uptime and fast support. Minecraft hosting that just works.

itsfsnow

Supreme
Feedback score
1
Posts
138
Reactions
31
Resources
0
I just realised, but you need to add a little bit to the rise method, otherwise if you go up by for example 5, it might not ever reach the top but will get stuck just before
Code:
    void rise(int amount) {
        for(Player player : Bukkit.getOnlinePlayers()) player.sendMessage(ChatColor.translateAlternateColorCodes('&', "&a The sea level has risen from &l" + currentLevel + "&r&a to &l" + (currentLevel + amount)));
        currentLevel = currentLevel + amount;
        if(currentLevel > 255) currentLevel = 255;
        if(currentLevel  == 255) Bukkit.getScheduler().cancelTask(riseScheduler);
        Bukkit.dispatchCommand(Bukkit.getConsoleSender(), "fill -50 " + currentLevel + " -50 " + "50 " + currentLevel + " 50 minecraft:water replace minecraft:air");
    }
 

itsfsnow

Supreme
Feedback score
1
Posts
138
Reactions
31
Resources
0
Why would you need that
I made it just for like a one time thing with my friends for a game, so I put it here if anyone else wants to try it[DOUBLEPOST=1564779717][/DOUBLEPOST]
I recommend you post this on https://github.com/, it may come useful to many more developers.
I don't know how to use github though, I tried but I gave up lol
 

NaturalBBB

Feedback score
0
Posts
26
Reactions
3
Resources
0
Hello may you please contact me on discord!
Dm me To Partner (500+)
#7190[DOUBLEPOST=1565475641][/DOUBLEPOST]Hello can you please contact us we need help!
 
Last edited:

heyimmelol

Feedback score
0
Posts
1
Reactions
0
Resources
0
if u have world edit u can put a command to get rid of it, i forgot whats the command but theres probaly in google
 
Status
This thread has been locked.
Top