mirror of
https://github.com/songoda/EpicBosses.git
synced 2025-01-06 23:37:33 +01:00
Added %player% variable to the death event command.
This commit is contained in:
parent
898306aed4
commit
5156e3ae7c
@ -90,7 +90,10 @@ public class BossDeathListener implements Listener {
|
|||||||
if (commands != null) {
|
if (commands != null) {
|
||||||
if (activeBossHolder.getSpawningPlayerName() != null)
|
if (activeBossHolder.getSpawningPlayerName() != null)
|
||||||
commands.replaceAll(s -> s.replace("{spawner}", activeBossHolder.getSpawningPlayerName()));
|
commands.replaceAll(s -> s.replace("{spawner}", activeBossHolder.getSpawningPlayerName()));
|
||||||
if (event.getKiller() != null) commands.replaceAll(s -> s.replace("{killer}", event.getKiller().getName()));
|
if (event.getKiller() != null) {
|
||||||
|
commands.replaceAll(s -> s.replace("{killer}", event.getKiller().getName()));
|
||||||
|
commands.replaceAll(s -> s.replace("%player%", event.getKiller().getName()));
|
||||||
|
}
|
||||||
commands.forEach(serverUtils::sendConsoleCommand);
|
commands.forEach(serverUtils::sendConsoleCommand);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user