SteamWar/BauSystem
Archiviert
13
0

Add Comments to scripts

Dieser Commit ist enthalten in:
YoyoSource 2020-12-10 21:30:31 +01:00
Ursprung da3e49b54b
Commit 6dcda0f509

Datei anzeigen

@ -47,6 +47,7 @@ public class ScriptListener implements Listener {
BookMeta meta = (BookMeta) item.getItemMeta(); BookMeta meta = (BookMeta) item.getItemMeta();
for(String page : meta.getPages()){ for(String page : meta.getPages()){
for(String command : page.split("\n")){ for(String command : page.split("\n")){
if (command.startsWith("#")) continue;
Bukkit.getLogger().log(Level.INFO, player.getName() + " dispatched command: " + command); Bukkit.getLogger().log(Level.INFO, player.getName() + " dispatched command: " + command);
Bukkit.getServer().dispatchCommand(player, command); Bukkit.getServer().dispatchCommand(player, command);
} }