XHawk87 / CreateYourOwnMenus

A Bukkit plugin to allow server owners to design and create their own menus in-game
6 stars 8 forks source link

Add Placeholder Support #21

Open Peda1996 opened 5 years ago

Peda1996 commented 5 years ago

It would be nice if Placeholder support would be added (note to me)

XHawk87 commented 5 years ago

Would you mind expanding on that description a bit so the rest of us can understand and help?

Peda1996 commented 5 years ago

Ah yea sorry,

i would like to add the support of placeholders in menues. Therefore when the menu is opened, the certain placeholder is replaced. I would like to use: https://www.spigotmc.org/resources/placeholderapi.6245/

Peda1996 commented 5 years ago

Added Placeholdersupport in my branch: commit aff80f086687af54f378fd384f0726d5f7b820e4

only problem is, that i couldn't resolve the functionality of the menugrabber, also my quick fix for only playercommands is now working better

brodycritchlow commented 4 years ago

The only bad thing with adding placeholdersupport, is that if its saying like %balance%, what command would you do.

I think the java code would be confused and most likely either cause a very fatal error, or just completly shutdown.

This is just my experience from plugins trying to add placeholders.

Peda1996 commented 4 years ago

I haven't had any crash or fatal errors since I implemented this feature.. And well, it might be implemented in a hacky way, but we'll in this case it works as expected..