Forum

Please or Register to create posts and topics.

PlayerStatueBuilderX (My first spigot plugin!)

Although I've programmed before, I never thought I'd be able to make anything I could use while playing Minecraft, much less a plugin for a Spigot server. Well, that changed a couple months ago. Lukecreative and I were on Uncovery and he mentioned how he could make plugins for his own server. I began to look into it, and, well, the rest is history. In short, PlayerStatueBuilderX is a plugin for a Spigot server that creates a player statue based off of a player's skin. All skin formats are supported.

And here are the results!

https://imgur.com/a/m3HXHHj

https://github.com/SkyTechBytes/PlayerStatueBuilder/releases

https://www.spigotmc.org/resources/playerstatuebuilderx.73715/

(Wanted to post this in the general Minecraft forum category but it wouldn't let me, so here it is in off-topic)

Okay, that's all... have a nice day

Uploaded files:
  • 2019-12-24_14.56.38.png
riedi73 has reacted to this post.
riedi73

Really cool!

If you can get the following features into it, I will enable it here on the server:

  • Respect Worldguard building rights (i.e. cannot place any blocks outside permissions)
  • Works only if all required blocks are in the player inventory. (optional: If not, build partially and then later be able to place the rest.)
  • Optional: Tell the user the required blocks and checks if in inventory before building
  • Command respects Permissions

Thanks for taking a look! I've made a small update to the code and it should respect WorldGuard and it now has permissions (I haven't released the .jar yet-- needs more testing). The required blocks feature is a bit more tricky, however, as the plugin will overestimate the number of blocks due to overlap. Additionally, some skins might have more block types than can fit in the player's inventory.

As long as the plugin can place blocks without re-placing them, it can just tell you a list and then you re-fill your inventory and re-run the process until all blocks are placed.

But anyhow, if it respects worldguard we can enable it also in the flatlands.

Okay, I've been able to work a lot of the aforementioned issues out. Instead of requiring exactly the correct type of block, the plugin only requires the following types of blocks: oak planks, terracotta, or white wool. The plugin counts exactly how many of each type of block are in the statue (which required staging the statue in a nested Hashmap to prevent overlap but I digress)-- it's just that if you needed red terracotta before, you'd now only need regular terracotta. Same goes for the wool and planks. To prevent people from "farming statues", the cost of the plugin automatically "coloring" your statue is equivalent to 1 diamond for every 16 blocks. I have tested it with worldguard (finding the bounds of the statue is easier with the staging feature) on my own server and it should never infringe on protected areas (there is maybe 1 block of buffer on each side too).  Permissions-wise, the plugin now has 4 new permissions so hopefully that works. The plugin also will never overwrite blocks based on default permissions.

OPs bypass all resource, block-overwrite, and WorldGuard restrictions by default.
All players can run the command by default (change the permissions to prevent that from happening).

The complete details of the update are here: https://github.com/SkyTechBytes/PlayerStatueBuilder/releases/tag/1.2 

Please note that there is no cooldown for the command so if you plan to use it in the flatlands, some limiting feature would be needed.

The plugin now also has a built-in cooldown feature for 5 minutes after each successful statue creation per-player (and a configuration file that can change the cooldown, among other things):

https://github.com/SkyTechBytes/PlayerStatueBuilder/releases/tag/1.3