Hello, I run a prison server and I am going to be adding a Prestige plugin. I have already created a working prestige plugin but I need some help with the prefix. I am using essentials chat and groupmanager Basically at the moment here is how chat looks like <[G] PlayerName> MESSAGE (Non Donor) <[G] PlayerName [Donor]> MESSAGE (Donor) I need this to work for both of these like this <[G] PlayerName> [Prestige 1] MESSAGE (Non Donor) <[G] PlayerName [Prestige 1] [Donor]> MESSAGE (Donor) How would I do something like this?
but it could be all kinds of diffrent suffixes from when they donate, I would need to allow the donor suffix to change to there donor rank when they donate but also keep prestige suffix Maybe there is some way I can hook my plugin into essentials and just add in essentials config chat {PRESTIGE}? If so can someone send me a tutorial EDIT by Moderator: merged posts, please use the edit button instead of double posting.
http://jd.bukkit.org/rb/apidocs/org/bukkit/event/player/AsyncPlayerChatEvent.html Take a look at this method. Joshuak52
this is the system I have for rankup its much easier for me. Code:java PermissionUser user = PermissionsEx.getPermissionManager().getUser(sender.getName());String currentRank = user.getPrefix(); if(currentRank.equalsIgnoreCase("&7&l[&5&lPRESTIGEC&7&l]&2")){RegisteredServiceProvider<Economy> rsp = Bukkit.getServer().getServicesManager().getRegistration(Economy.class);Economy econ = rsp.getProvider();EconomyResponse r = econ.withdrawPlayer(sender.getName(), PrestigeD);if(r.transactionSuccess()){Bukkit.broadcastMessage(prefix+"§6Congradulations! "+sender.getName()+" §ais now PrestigeD!");Bukkit.dispatchCommand(Bukkit.getConsoleSender(), "pex user "+sender.getName()+" group set prestiged");}else{sender.sendMessage("§cYou don't have Enought Money to rankup right now!");}