S86 Powers
Introduction
Minecraft is a great game on its own, but chances are if you're here and you're a server admin then you're looking for more to offer your clients. As you may know by now, when it comes to the extras every player wants something unique. Some want new mechanics, others want better weapons. Some want to help their friends, others want to dominate them. The problem is most plugins often offer a blanket solution. While it may fulfill the needs of a few, the remaining may not want to participate. Sure you can mess with permissions to exclude some people, but why not just cut to the chase and give every player EXACTLY what they want?
For the server that wants its players to each have individual benefits and abilities, S86 Powers is the plugin for you.
How It Works
S86 Powers is a plugin that allows users to have powers assigned to them. The core plugin comes with internal powers, but is also capable of importing powers made by others (more info to come).
To get started, simply place the S86Powers.jar file where you put your other plugins. Note that ProtocolLib is required for S86 Powers to function. On first run, several configuration files are created with default values. It is recommended that you not edit these files directly unless the server is off, as entered values may be overwritten the next time the server shuts down or restarts.
Next, you'll want to review permissions and configuration options. Operators by default get permission to everything, otherwise assigning the permission s86powers.admin will accomplish the same thing. To view configuration options, use the command /p config list [page#] (for example, /p config list 2 shows you page 2). For more information on what an option does, use the command /p config info [config], and to change config options use the command /p config set [config] [value].
Finally, for players to use powers they must first have them assigned, and before they can do that they'll want to know what's available. Use the command /p power list to get a list of loaded powers, then /p power [power] for more info on a specific power. If you don't like how a power is setup, you can check and set its configurable options with /p power [power] option. Note that changes to power options affect all users, and may require a server reload/restart for changes to take effect.
Players can be assigned powers in several ways, the two most prominent being admin-assigned or self-assigned. Admin-assigned requires a user with the s86powers.manage.user permission to use the command /p user [player] add [power]. Note that the above permission allows the user to set anyone's powers and shouldn't be given to most players. Self-assigned requires a user to have the s86powers.manage.self permission, and use the command /p add [power]. This method is safer, as the user can only modify their own powers.
What Are Powers?
Most powers come in three categories: offensive, defensive, and passive. Offensive and defensive powers operate similarly: the player does something with a specified item, and it causes an effect. Offensive powers usually do something that causes damage to others, while defensive powers usually do something to protect the player in some way. Passive powers tend to work automatically and provide some kind of bonus that neither hurts others nor protects the player (though there are exceptions).
An example of an offensive power is Laser. In its default configuration, left-clicking while holding a dispenser will fire a laser in the direction that the player is looking. This laser steadily does damage to anything it hits but uses redstone dust as fuel. The laser turns off when either the player left-clicks while holding a dispenser again, or when the player runs out of redstone dust. After using Laser, the player has to wait for a 10 second cooldown before using it again.
An example of a defensive power is Celestial Pillars. Left-clicking the ground while holding a sea lantern will create pillars of light around you. While these pillars stand, nothing can pass between the pillars except for the player. Pillars last for 45 seconds, however the player can't create new ones until the old ones expire.
An example of a passive power is Lumberjack. With Lumberjack assigned, breaking one log block of a tree with an axe will cause all adjacent tree blocks to break as well, essentially harvesting the entire tree at once. By default, a threshold is put in place so players can't level entire jungles.
Some powers have additional effects when they're used a lot. For example, after creating 60 pillars with the Celestial Pillars power, you gain the ability to create a second set of pillars by left-clicking the same block with a sea lantern again.
By default, players can only have one of each of the above power types assigned to them, though this limit can be removed with config options.
The last power type is utility. Utility powers can be used by anyone, including players with no assigned powers. Neutralizer Grenade allows players to throw lapis lazuli like a grenade, temporarily disabling the powers of any players nearby when it hits. Neutralizer Beacon allows players to create a block that constantly disables the powers of players who go near it.
Commands / Permissions
All commands can be viewed by simply using the /powers help command. You can view additional pages using /powers help [page], or view help on specific topics like /powers help player.
Donate
Creating and maintaining a plugin this size can be a full-time job on its own. I enjoy working on this plugin and don't mind doing it for free, but the fact remains that I must commit a majority of my free time to do this. If you like my work and would like to support it, please consider donating.
Need support? Have an idea for a power? Join my Discord server!
@fletch_to_99
Yeah, this would actually be wicked easy. I can get it implemented for v3.2.2.
@sirrus86
Can you add a way with permissions to set groups (lets say my permissions group members had s86powers.groups.awesome) it would make my permissions group members part of the awesome powers group? If you don't want to do this and have a github repo I'll be glad to fork and add this :)
@Chalkie19
The reload command basically just disables, then re-enables to plugin. This is meant to interrupt malfunctioning powers, but will also reload configs and reinitialize the plugin for the most part (though not to the extent that Bukkit's /reload does). One of these steps is to check if pConfig.yml exists, and if not, save a new copy. This takes place elsewhere in the plugin, so I'll be sure to check that as well.
@sirrus86
I get the same thing on my Centos Server, seems to appear after a /powers reload command.
@fletch_to_99
Looks like you're using a Unix-based filesystem? I honestly didn't anticipate this, my bad.
Originally what you suggested is what I had, this wound up creating a file in the plugins folder called "S86 PowerspConfig.yml". I'm going to rewrite the code to include File.sepratorChar like you suggested, I'm new to Java and wasn't aware this existed.
Thanks for helping me improve the plugin!
@sirrus86
in pchecks.java can you change line 26 too
or use File.separatorChar
That should prevent this: from happening (notice the S86Powers\pconfig.yml file in the plugins dir)
@Dmaxwell16
Heh this is the second time this bug's been reported, suppose I should work on that... I'll see what I can do.
I have this on my server and there seems to be a bug with the Aeroblade, anytime i try to use it its as if the gust of wind is still happening where i shot it originally so ill Throw the gust then the mob or player will fly but if they try to go back to where they were its as if they get hit by the aeroblade again and it stays there until i change the power or log off its my favorite power id love if this was fixed :D
@RandomSomething98
I'll see what I can do.
@ehwllmac
Grappling Hook's range is dependant on how far the fishing rod can go, I don't know any easy way to change this. I can change the reel-in velocity however.
Hello, I just recently started using this awesome plugin and would like for there to be a new power. The power could be something new or could be replaced with "grappling hook". If replaced call it the same thing, just call it the same with some tweaks. I would say, if you can, to simply increase the fishing rod's velocity and range, because its not really that much reach on it except for maybe up to 10 - 15 blocks. Maybe if you could double that? I think this would be amazing, if possible. Thanks for taking the time to read this post.
Okay, but would it be possible to make the beacon ranges not universal? Or perhaps universal by default, and then be able to edit the beacon's area in the config file?
@RandomSomething98
A beacon's range can be changed in the plugins/S86 Powers/pConfig.yml file. This is universal though; it affects all beacons. The area of effect for a beacon is always spherical.
Neutralized regions are meant to be more permanent than beacons, outside of most players' control. The area of effect for a neutralized beacon is always cuboid.
Is it possible to make a beacon able to enable or disable WorldGuard areas? Or could you add a way to configure the beacon's range? Maybe when you make it, it asks you to click on 2 corners of the area which will be protected. I don't use WorldGuard, so it would be a great amount of help if you could make it so. :)
@RandomSomething98
I like it, added.
I, again, had a idea for a power.
Instant Cover-
A defensive power. If a fired projectile hits the player with this power, it instantly creates a small wall that can work as cover. It is 2 wide and 3 tall.It disappears after a determined amount of time. It could be a glowstone wall. The direction it is facing depends on where the attacker is.
@RandomSomething98
PvP - Sorry, overlooked that part of your previous post. His copy should be unable to target you while you're hidden. That said, if your copy has died or has yet to trigger, you're no longer hidden. If it's targetting you while your copy is active, then yeah there's a problem. I'll take a look at it.
Bloodbend - The power is only supposed to trigger when you right-click an entity. Unfortunately slimes especially have a weird hitbox, so even though you were clicking the door the hit was triggered, causing the power to kick in. You can either assign an item in pConfig.yml, or open the door using left-click.
On a related note I've witnessed first-hand that Soul Shatter can trigger if you open a door using right-click while holding an ender pearl, even though the power is supposed to only trigger with left-click. I don't believe this is an issue in S86 Powers itself, but it probably presents itself with it more often than other plugins would.
I also had a bug occur while using Blood Bend. I had a BUNCH of slimes out my door. I tried opening the door to confront them, but I was using Blood Bend through the door instead. It took a bunch of clicking to open or close the door. This could be solved by not opening the door with your hand, but it is still quite an annoyance.
OK thanks. But it was his copy that could hit me before i was exposed. I'd think that to make it more for escaping rather than php, it maybe should activate when the player's health is below a certain point. But I still think that his copy attacking me is a little farfetched. I guess I could make the cool down for longer to balance it out for now.
@RandomSomething98
Economy - Plan is to offer support for multiple currencies. Currently the currencies in mind are emeralds, xp, and iConomy money.
Spawn Glitch - I'm guessing the glitched copies also couldn't be harmed or moved in any way? Inactive copies are caused by an error in packet creation. Normally, Diversion summons a Pig Zombie at your location, then applies a player entity packet onto it to make it look like you. Problem is if the Pig Zombie doesn't spawn or is somehow despawned, the packet will sometimes still be created but with no entity to attach itself to. These glitched copies are the result. Unfortunately, restarting the server is the only way I know to get rid of them.
Attacking - Copies are coded to only attack whatever attacked you. Since all Creepers can do is explode, the copies never get any initiative to attack them. Large slime are actually difficult and sometimes impossible for other entities to hit, and small slimes can't damage anything. You're actually not supposed to be able to attack while your copy is active (I forgot to code this part) as the power is meant to provide a means of escape, not aide in attacking an enemy.
PvP - The person who requested Diversion wanted to use it as a way to escape confrontations. A sharp eye can see through it, but most casual players will assume the copy to be the player and remain focused on it while the real player can escape. There actually is a cooldown in Diversion, but it's hard to notice: after a copy is created, another one can't be created for something like 10 seconds. The only way you'd notice this is if your attacker managed to hit you, kill your copy, then hit you again within that timeframe, which is rare. If you increase the "diversion-duration" option in pConfig.yml, you'll notice this cooldown occurring more often. As far as a cost goes, I can implement a consumable item or something.
Oh hey, I was having a weird bug using diversion. I was on a superflat map, being mobbed by slimes and spiders, when my diversion spawned, it's head was at an odd angle, and it wasn't moving. AT ALL. I became exposed, and it was still there. Then I was attacked some more. I ended up having 6-8 of these clones, all doing this. Though the head angles were different. Eventually, my new clones started working again, but the old ones stayed until I turned off the server. I have a pic I took of one. Though I can't find a way to paste it to save my life. :P
Also, speaking of diversion, they seem to be fairly useless at a creeper, and they only attack 1 stage of slime. Sorta annoying that I have to fight the smaller slimes while he's making 1 of them turn into small slimes every 10 seconds. Too slow.
And finally, I pvp'd my friend. We both had diversion, and overall, it didn't end well, our clones fought, and his clone won and attacked me while I was still supposed to be invisible, and of course, he kept doing that, and I died. Can there be a way to balance diversion more, Like, maybe it takes some of your health in order to have a clone. And then maybe there should be a cool down for using diversion too.