RuneHive-Game
Loading...
Searching...
No Matches
com.runehive.content.staff.PlayerManagement Enum Reference

Handles the player management. More...

Inheritance diagram for com.runehive.content.staff.PlayerManagement:
Collaboration diagram for com.runehive.content.staff.PlayerManagement:

Public Member Functions

 PlayerManagement (String string)
Public Member Functions inherited from com.runehive.content.staff.ActionEffect
void handle (final Player player)
 Handles the execute of the staff panel action.

Static Public Member Functions

static void confirm (Player player, Runnable runnable)
static PlayerManagement forOrdinal (int ordinal)

Public Attributes

 CHANGE_USERNAME
 CHECK_BANK
 CLEAR
 COPY
 COPY_ME
 DEMOTE
 JAIL
 KICK
 LINKED_ACCOUNTS
 MOVE_HOME
 MUTE
 PNPCS
 PROMOTE
final String string
 TELEPORT_TO
 TELEPORT_TO_ME
 UNJAIL
 UNMUTE

Detailed Description

Handles the player management.

Author
Daniel

Definition at line 32 of file PlayerManagement.java.

Constructor & Destructor Documentation

◆ PlayerManagement()

com.runehive.content.staff.PlayerManagement.PlayerManagement ( String string)

Definition at line 336 of file PlayerManagement.java.

336 {
337 this.string = string;
338 }

References string.

Referenced by forOrdinal().

Here is the caller graph for this function:

Member Function Documentation

◆ confirm()

void com.runehive.content.staff.PlayerManagement.confirm ( Player player,
Runnable runnable )
static

Definition at line 340 of file PlayerManagement.java.

340 {
341 DialogueFactory factory = player.dialogueFactory;
342 factory.sendStatement("Are you sure you want to execute this action?");
343 factory.sendOption("Confirm action", runnable, "Nevermind", factory::clear);
344 factory.execute();
345 }

References com.runehive.game.world.entity.mob.player.Player.dialogueFactory, com.runehive.content.dialogue.DialogueFactory.execute(), com.runehive.content.dialogue.DialogueFactory.sendOption(), and com.runehive.content.dialogue.DialogueFactory.sendStatement().

Here is the call graph for this function:

◆ forOrdinal()

PlayerManagement com.runehive.content.staff.PlayerManagement.forOrdinal ( int ordinal)
static

Definition at line 347 of file PlayerManagement.java.

347 {
348 for (PlayerManagement management : values()) {
349 if (management.ordinal() == ordinal) {
350 return management;
351 }
352 }
353 return null;
354 }

References PlayerManagement().

Here is the call graph for this function:

Member Data Documentation

◆ CHANGE_USERNAME

com.runehive.content.staff.PlayerManagement.CHANGE_USERNAME
Initial value:
=(PlayerRight.getColor(OWNER) + "Change Username") {
@Override
public void handle(Player player) {
if (PlayerRight.isOwner(player) && player.managing.isPresent()) {
Player other = player.managing.get();
player.send(new SendInputMessage("Enter their new username", 12, input -> {
if (ProfileRepository.exist(input)) {
player.dialogueFactory.sendStatement("The name " + input + " is already taken.").execute();
return;
}
other.setUsername(input);
other.updateFlags.add(UpdateFlag.APPEARANCE);
player.dialogueFactory.sendStatement("You have successfully changed their username.").execute();
}));
}
}
}
This class represents a character controlled by a player.
Definition Player.java:125
Handles the profile repository, used for gathering important information for all created profiles.
static boolean exist(String name)
Checks if a profile is registered to the parameter.
Sends a chatbox input prompt that accepts full text with spaces.
void handle(final Player player)
Handles the execute of the staff panel action.

Definition at line 313 of file PlayerManagement.java.

313 {
314 @Override
315 public void handle(Player player) {
316 if (PlayerRight.isOwner(player) && player.managing.isPresent()) {
317 Player other = player.managing.get();
318
319 player.send(new SendInputMessage("Enter their new username", 12, input -> {
320 if (ProfileRepository.exist(input)) {
321 player.dialogueFactory.sendStatement("The name " + input + " is already taken.").execute();
322 return;
323 }
324 other.setUsername(input);
325 other.updateFlags.add(UpdateFlag.APPEARANCE);
326 PlayerSerializer.save(other);
327 player.dialogueFactory.sendStatement("You have successfully changed their username.").execute();
328 }));
329 }
330 }
331 },;
override fun handle(player:Player)

◆ CHECK_BANK

com.runehive.content.staff.PlayerManagement.CHECK_BANK
Initial value:
=(PlayerRight.getColor(MODERATOR) + "Check Bank") {
@Override
public void handle(Player player) {
if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
Player other = player.managing.get();
long totalValue = other.bank.containerValue(PriceType.VALUE);
long vaultCoins = other.bankVault.coinsContainer;
long vaultBM = other.bankVault.bloodMoneyContainer;
player.interfaceManager.openInventory(60000, 5063);
player.send(new SendItemOnInterface(InterfaceConstants.WITHDRAW_BANK, other.bank.tabAmounts, other.bank.toArray()));
player.send(new SendItemOnInterface(InterfaceConstants.INVENTORY_STORE, other.inventory.toArray()));
player.send(new SendString("", 60_079));
player.dialogueFactory.sendInformationBox(other.getName() + "'s Bank:", "Bank Value: " + (totalValue), "Bank Vault (Coins): " + (vaultCoins), "Bank Vault (BM): " + (vaultBM)).execute();
}
}
}
The class that contains helpful information on interfaces.
The OutgoingPacket that sends a string to a Players itemcontainer in the client.
static boolean isModerator(Player player)
Checks if the player is a management member.

Definition at line 176 of file PlayerManagement.java.

176 {
177 @Override
178 public void handle(Player player) {
179 if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
180 Player other = player.managing.get();
181 long totalValue = other.bank.containerValue(PriceType.VALUE);
182 long vaultCoins = other.bankVault.coinsContainer;
183 long vaultBM = other.bankVault.bloodMoneyContainer;
184
185 player.interfaceManager.openInventory(60000, 5063);
186 player.send(new SendItemOnInterface(InterfaceConstants.WITHDRAW_BANK, other.bank.tabAmounts, other.bank.toArray()));
187 player.send(new SendItemOnInterface(InterfaceConstants.INVENTORY_STORE, other.inventory.toArray()));
188 player.send(new SendString("", 60_079));
189 player.dialogueFactory.sendInformationBox(other.getName() + "'s Bank:", "Bank Value: " + (totalValue), "Bank Vault (Coins): " + (vaultCoins), "Bank Vault (BM): " + (vaultBM)).execute();
190 }
191 }
192 },

◆ CLEAR

com.runehive.content.staff.PlayerManagement.CLEAR
Initial value:
=(PlayerRight.getColor(OWNER) + "Clear Account") {
@Override
public void handle(Player player) {
if (PlayerRight.isOwner(player) && player.managing.isPresent()) {
Player other = player.managing.get();
confirm(player, () -> {
other.bank.clear();
other.inventory.clear();
for (int index = 0; index < Skill.SKILL_COUNT; index++) {
other.skills.setLevel(index, index == 3 ? 10 : 1);
other.skills.setMaxLevel(index, index == 3 ? 10 : 1);
}
other.skills.setCombatLevel();
other.updateFlags.add(UpdateFlag.APPEARANCE);
});
}
}
}
Represents a trainable and usable skill.
Definition Skill.java:18
static final int SKILL_COUNT
The amount of available skills.
Definition Skill.java:90
static void confirm(Player player, Runnable runnable)

Definition at line 276 of file PlayerManagement.java.

276 {
277 @Override
278 public void handle(Player player) {
279 if (PlayerRight.isOwner(player) && player.managing.isPresent()) {
280 Player other = player.managing.get();
281
282 confirm(player, () -> {
283 other.bank.clear();
284 other.inventory.clear();
285
286 for (int index = 0; index < Skill.SKILL_COUNT; index++) {
287 other.skills.setLevel(index, index == 3 ? 10 : 1);
288 other.skills.setMaxLevel(index, index == 3 ? 10 : 1);
289 }
290
291 other.skills.setCombatLevel();
292 other.updateFlags.add(UpdateFlag.APPEARANCE);
293 });
294 }
295 }
296 },
val index

◆ COPY

com.runehive.content.staff.PlayerManagement.COPY
Initial value:
=(PlayerRight.getColor(ADMINISTRATOR) + "Copy") {
@Override
public void handle(Player player) {
if (PlayerRight.isAdministrator(player) && player.managing.isPresent()) {
Player other = player.managing.get();
player.playerAssistant.copy(other);
player.updateFlags.add(UpdateFlag.APPEARANCE);
player.message("<col=FF0D5D>You have copied " + other.getName() + ".");
}
}
}
static boolean isAdministrator(Player player)
Checks if the player is a privileged member.

Definition at line 252 of file PlayerManagement.java.

252 {
253 @Override
254 public void handle(Player player) {
255 if (PlayerRight.isAdministrator(player) && player.managing.isPresent()) {
256 Player other = player.managing.get();
257
258 player.playerAssistant.copy(other);
259 player.updateFlags.add(UpdateFlag.APPEARANCE);
260 player.message("<col=FF0D5D>You have copied " + other.getName() + ".");
261 }
262 }
263 },

◆ COPY_ME

com.runehive.content.staff.PlayerManagement.COPY_ME
Initial value:
=(PlayerRight.getColor(OWNER) + "Copy Me") {
@Override
public void handle(Player player) {
if (PlayerRight.isOwner(player) && player.managing.isPresent()) {
Player other = player.managing.get();
other.playerAssistant.copy(player);
other.updateFlags.add(UpdateFlag.APPEARANCE);
player.message("<col=FF0D5D>You have X-copied " + other.getName() + ".");
}
}
}

Definition at line 264 of file PlayerManagement.java.

264 {
265 @Override
266 public void handle(Player player) {
267 if (PlayerRight.isOwner(player) && player.managing.isPresent()) {
268 Player other = player.managing.get();
269
270 other.playerAssistant.copy(player);
271 other.updateFlags.add(UpdateFlag.APPEARANCE);
272 player.message("<col=FF0D5D>You have X-copied " + other.getName() + ".");
273 }
274 }
275 },

◆ DEMOTE

com.runehive.content.staff.PlayerManagement.DEMOTE
Initial value:
=(PlayerRight.getColor(ADMINISTRATOR) + "Demote") {
@Override
public void handle(Player player) {
if (PlayerRight.isAdministrator(player) && player.managing.isPresent()) {
Player other = player.managing.get();
other.right = PlayerRight.PLAYER;
other.updateFlags.add(UpdateFlag.APPEARANCE);
other.dialogueFactory.sendStatement("You were demoted by " + player.getName()).execute();
player.message("You have demoted " + other.getName() + ".");
}
}
}

Definition at line 239 of file PlayerManagement.java.

239 {
240 @Override
241 public void handle(Player player) {
242 if (PlayerRight.isAdministrator(player) && player.managing.isPresent()) {
243 Player other = player.managing.get();
244
245 other.right = PlayerRight.PLAYER;
246 other.updateFlags.add(UpdateFlag.APPEARANCE);
247 other.dialogueFactory.sendStatement("You were demoted by " + player.getName()).execute();
248 player.message("You have demoted " + other.getName() + ".");
249 }
250 }
251 },

◆ JAIL

com.runehive.content.staff.PlayerManagement.JAIL

Definition at line 84 of file PlayerManagement.java.

84 {
85 @Override
86 public void handle(Player player) {
87 if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
88 Player other = player.managing.get();
89
90 confirm(player, () -> {
91 DialogueFactory factory = player.dialogueFactory;
92 factory.sendOption("Jail by day", () -> {
93 factory.onAction(() -> player.send(new SendInputAmount("How long do you want this jail to last for?", 2, input -> {
94 other.punishment.jail(Integer.parseInt(input), TimeUnit.DAYS);
95 factory.clear();
96 })));
97 }, "Jail by hour", () -> {
98 factory.onAction(() -> player.send(new SendInputAmount("How long do you want this jail to last for?", 3, input -> {
99 other.punishment.jail(Integer.parseInt(input), TimeUnit.HOURS);
100 factory.clear();
101 })));
102 }, "Jail by minute", () -> {
103 factory.onAction(() -> player.send(new SendInputAmount("How long do you want this jail to last for?", 3, input -> {
104 other.punishment.jail(Integer.parseInt(input), TimeUnit.MINUTES);
105 factory.clear();
106 })));
107 }, "Jail forever", () -> {
108 factory.onAction(() -> {
109 other.punishment.jail(9999, TimeUnit.DAYS);
110 factory.clear();
111 });
112 });
113 });
114 }
115 }
116 },

◆ KICK

com.runehive.content.staff.PlayerManagement.KICK
Initial value:
=(PlayerRight.getColor(MODERATOR) + "Kick") {
@Override
public void handle(Player player) {
if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
Player other = player.managing.get();
confirm(player, () -> {
World.kickPlayer(other);
player.message("<col=FF0D5D>You have force kicked: " + other.getName() + ".");
});
}
}
}
Represents the game world.
Definition World.java:46
static void kickPlayer(Player other)
Definition World.java:217

Definition at line 71 of file PlayerManagement.java.

71 {
72 @Override
73 public void handle(Player player) {
74 if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
75 Player other = player.managing.get();
76
77 confirm(player, () -> {
78 World.kickPlayer(other);
79 player.message("<col=FF0D5D>You have force kicked: " + other.getName() + ".");
80 });
81 }
82 }
83 },

◆ LINKED_ACCOUNTS

com.runehive.content.staff.PlayerManagement.LINKED_ACCOUNTS
Initial value:
=(PlayerRight.getColor(MODERATOR) + "Linked Accounts") {
@Override
public void handle(Player player) {
if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
Player other = player.managing.get();
List<String> list = ProfileRepository.getRegistry(other.lastHost);
if (!list.isEmpty()) {
for (int index = 0; index < 50; index++) {
String name = index >= list.size() ? "" : list.get(index);
player.send(new SendString(name, 37111 + index));
}
player.message("<col=FF0D5D>There are " + list.size() + " accounts linked to " + Utility.formatName(other.getName()) + ".");
player.send(new SendString("Profiles:\\n" + list.size(), 37107));
player.send(new SendString(other.getName(), 37103));
player.interfaceManager.open(37100);
}
}
}
}
static List< String > getRegistry(String host)
Gets all the registered accounts to a specific host.
Handles miscellaneous methods.
Definition Utility.java:27
static String formatName(final String input)
Definition Utility.java:645

Definition at line 193 of file PlayerManagement.java.

193 {
194 @Override
195 public void handle(Player player) {
196 if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
197 Player other = player.managing.get();
198 List<String> list = ProfileRepository.getRegistry(other.lastHost);
199
200 if (!list.isEmpty()) {
201 for (int index = 0; index < 50; index++) {
202 String name = index >= list.size() ? "" : list.get(index);
203 player.send(new SendString(name, 37111 + index));
204 }
205
206 player.message("<col=FF0D5D>There are " + list.size() + " accounts linked to " + Utility.formatName(other.getName()) + ".");
207 player.send(new SendString("Profiles:\\n" + list.size(), 37107));
208 player.send(new SendString(other.getName(), 37103));
209 player.interfaceManager.open(37100);
210 }
211 }
212 }
213 },

◆ MOVE_HOME

com.runehive.content.staff.PlayerManagement.MOVE_HOME
Initial value:
=(PlayerRight.getColor(MODERATOR) + "Move Home") {
@Override
public void handle(Player player) {
if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
Player other = player.managing.get();
other.move(Config.DEFAULT_POSITION);
other.instance = Mob.DEFAULT_INSTANCE;
other.pvpInstance = false;
other.message("<col=FF0D5D>You have been force teleported home by " + player.getName() + ".");
}
}
}
The class that contains setting-related constants for the server.
Definition Config.java:24
static final Position DEFAULT_POSITION
The default, i.e.
Definition Config.java:197
Handles the mob class.
Definition Mob.java:66

Definition at line 58 of file PlayerManagement.java.

58 {
59 @Override
60 public void handle(Player player) {
61 if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
62 Player other = player.managing.get();
63
64 other.move(Config.DEFAULT_POSITION);
65 other.instance = Mob.DEFAULT_INSTANCE;
66 other.pvpInstance = false;
67 other.message("<col=FF0D5D>You have been force teleported home by " + player.getName() + ".");
68 }
69 }
70 },

◆ MUTE

com.runehive.content.staff.PlayerManagement.MUTE

Definition at line 130 of file PlayerManagement.java.

130 {
131 @Override
132 public void handle(Player player) {
133 if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
134 Player other = player.managing.get();
135
136 confirm(player, () -> {
137 DialogueFactory factory = player.dialogueFactory;
138 factory.sendOption("Mute by day", () -> {
139 factory.onAction(() -> player.send(new SendInputAmount("How long do you want this mute to last for?", 2, input -> {
140 other.punishment.mute(Integer.parseInt(input), TimeUnit.DAYS);
141 factory.clear();
142 })));
143 }, "Mute by hour", () -> {
144 factory.onAction(() -> player.send(new SendInputAmount("How long do you want this mute to last for?", 3, input -> {
145 other.punishment.mute(Integer.parseInt(input), TimeUnit.HOURS);
146 factory.clear();
147 })));
148 }, "Mute by minute", () -> {
149 factory.onAction(() -> player.send(new SendInputAmount("How long do you want this mute to last for?", 3, input -> {
150 other.punishment.mute(Integer.parseInt(input), TimeUnit.MINUTES);
151 factory.clear();
152 })));
153 }, "Mute forever", () -> {
154 factory.onAction(() -> {
155 other.punishment.mute(9999, TimeUnit.DAYS);
156 factory.clear();
157 });
158 });
159 });
160 }
161 }
162 },

◆ PNPCS

com.runehive.content.staff.PlayerManagement.PNPCS
Initial value:
=(PlayerRight.getColor(OWNER) + "Transform") {
@Override
public void handle(Player player) {
if (PlayerRight.isOwner(player) && player.managing.isPresent()) {
Player other = player.managing.get();
player.send(new SendInputAmount("Enter NPC ID:", 4, input -> {
int id = Integer.parseInt(input);
if (id == 0)
id = -1;
other.playerAssistant.transform(id);
player.message("<col=FF0D5D>You have turned " + other.getName() + " into " + NpcDefinition.get(id).getName() + ".");
}));
}
}
}
static NpcDefinition get(int id)
Gets a npc definition from the definition array.

Definition at line 297 of file PlayerManagement.java.

297 {
298 @Override
299 public void handle(Player player) {
300 if (PlayerRight.isOwner(player) && player.managing.isPresent()) {
301 Player other = player.managing.get();
302
303 player.send(new SendInputAmount("Enter NPC ID:", 4, input -> {
304 int id = Integer.parseInt(input);
305 if (id == 0)
306 id = -1;
307 other.playerAssistant.transform(id);
308 player.message("<col=FF0D5D>You have turned " + other.getName() + " into " + NpcDefinition.get(id).getName() + ".");
309 }));
310 }
311 }
312 },

◆ PROMOTE

com.runehive.content.staff.PlayerManagement.PROMOTE
Initial value:
=(PlayerRight.getColor(ADMINISTRATOR) + "Promote") {
@Override
public void handle(Player player) {
if (PlayerRight.isAdministrator(player) && player.managing.isPresent()) {
Player other = player.managing.get();
player.dialogueFactory.sendOption("Helper", () -> {
other.right = PlayerRight.HELPER;
other.updateFlags.add(UpdateFlag.APPEARANCE);
other.dialogueFactory.sendStatement("You were promoted to helper by " + player.getName()).execute();
player.message("You have promoted " + other.getName() + " to helper.");
}, "Moderator", () -> {
other.right = PlayerRight.MODERATOR;
other.updateFlags.add(UpdateFlag.APPEARANCE);
other.dialogueFactory.sendStatement("You were promoted to moderator by " + player.getName()).execute();
player.message("You have promoted " + other.getName() + " to moderator.");
}, "Administrator", () -> {
other.right = PlayerRight.ADMINISTRATOR;
other.updateFlags.add(UpdateFlag.APPEARANCE);
other.dialogueFactory.sendStatement("You were promoted to administrator by " + player.getName()).execute();
player.message("You have promoted " + other.getName() + " to administrator.");
}).execute();
}
}
}

Definition at line 214 of file PlayerManagement.java.

214 {
215 @Override
216 public void handle(Player player) {
217 if (PlayerRight.isAdministrator(player) && player.managing.isPresent()) {
218 Player other = player.managing.get();
219
220 player.dialogueFactory.sendOption("Helper", () -> {
221 other.right = PlayerRight.HELPER;
222 other.updateFlags.add(UpdateFlag.APPEARANCE);
223 other.dialogueFactory.sendStatement("You were promoted to helper by " + player.getName()).execute();
224 player.message("You have promoted " + other.getName() + " to helper.");
225 }, "Moderator", () -> {
226 other.right = PlayerRight.MODERATOR;
227 other.updateFlags.add(UpdateFlag.APPEARANCE);
228 other.dialogueFactory.sendStatement("You were promoted to moderator by " + player.getName()).execute();
229 player.message("You have promoted " + other.getName() + " to moderator.");
230 }, "Administrator", () -> {
231 other.right = PlayerRight.ADMINISTRATOR;
232 other.updateFlags.add(UpdateFlag.APPEARANCE);
233 other.dialogueFactory.sendStatement("You were promoted to administrator by " + player.getName()).execute();
234 player.message("You have promoted " + other.getName() + " to administrator.");
235 }).execute();
236 }
237 }
238 },

◆ string

final String com.runehive.content.staff.PlayerManagement.string

Definition at line 334 of file PlayerManagement.java.

Referenced by PlayerManagement().

◆ TELEPORT_TO

com.runehive.content.staff.PlayerManagement.TELEPORT_TO
Initial value:
=(PlayerRight.getColor(MODERATOR) + "Teleport To") {
@Override
public void handle(Player player) {
if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
Player other = player.managing.get();
player.move(other.getPosition());
player.instance = other.instance;
player.pvpInstance = other.pvpInstance;
}
}
}

Definition at line 33 of file PlayerManagement.java.

33 {
34 @Override
35 public void handle(Player player) {
36 if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
37 Player other = player.managing.get();
38
39 player.move(other.getPosition());
40 player.instance = other.instance;
41 player.pvpInstance = other.pvpInstance;
42 }
43 }
44 },

◆ TELEPORT_TO_ME

com.runehive.content.staff.PlayerManagement.TELEPORT_TO_ME
Initial value:
=(PlayerRight.getColor(MODERATOR) + "Teleport To Me") {
@Override
public void handle(Player player) {
if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
Player other = player.managing.get();
other.move(player.getPosition());
other.instance = player.instance;
other.pvpInstance = player.pvpInstance;
other.message("<col=FF0D5D>You have been force teleported to " + player.getName() + ".");
}
}
}

Definition at line 45 of file PlayerManagement.java.

45 {
46 @Override
47 public void handle(Player player) {
48 if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
49 Player other = player.managing.get();
50
51 other.move(player.getPosition());
52 other.instance = player.instance;
53 other.pvpInstance = player.pvpInstance;
54 other.message("<col=FF0D5D>You have been force teleported to " + player.getName() + ".");
55 }
56 }
57 },

◆ UNJAIL

com.runehive.content.staff.PlayerManagement.UNJAIL
Initial value:
=(PlayerRight.getColor(MODERATOR) + "Un-Jail") {
@Override
public void handle(Player player) {
if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
Player other = player.managing.get();
other.punishment.unJail();
other.dialogueFactory.sendStatement("You have been unjailed!").execute();
other.message("<col=FF0D5D>You have been unjailed by: " + player.getName());
player.message("<col=FF0D5D>You have unjailed: " + other.getName());
}
}
}

Definition at line 117 of file PlayerManagement.java.

117 {
118 @Override
119 public void handle(Player player) {
120 if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
121 Player other = player.managing.get();
122
123 other.punishment.unJail();
124 other.dialogueFactory.sendStatement("You have been unjailed!").execute();
125 other.message("<col=FF0D5D>You have been unjailed by: " + player.getName());
126 player.message("<col=FF0D5D>You have unjailed: " + other.getName());
127 }
128 }
129 },

◆ UNMUTE

com.runehive.content.staff.PlayerManagement.UNMUTE
Initial value:
=(PlayerRight.getColor(MODERATOR) + "Un-Mute") {
@Override
public void handle(Player player) {
if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
Player other = player.managing.get();
other.punishment.unmute();
other.dialogueFactory.sendStatement("You have been unmuted!").execute();
other.message("<col=FF0D5D>You have been unmuted by: " + player.getName());
player.message("<col=FF0D5D>You have unmuted: " + other.getName());
}
}
}

Definition at line 163 of file PlayerManagement.java.

163 {
164 @Override
165 public void handle(Player player) {
166 if (PlayerRight.isModerator(player) && player.managing.isPresent()) {
167 Player other = player.managing.get();
168
169 other.punishment.unmute();
170 other.dialogueFactory.sendStatement("You have been unmuted!").execute();
171 other.message("<col=FF0D5D>You have been unmuted by: " + player.getName());
172 player.message("<col=FF0D5D>You have unmuted: " + other.getName());
173 }
174 }
175 },

The documentation for this enum was generated from the following file: