3
0
Fork 0

Added Region placeholder for Webhook, bumped to v2.1.1

This commit is contained in:
stijnb1234 2020-08-17 12:59:40 +02:00
parent fb9346e814
commit 30497cd335
2 changed files with 3 additions and 1 deletions

View file

@ -6,7 +6,7 @@
<groupId>nl.SBDeveloper</groupId>
<artifactId>ThemeParkPlus</artifactId>
<version>2.1</version>
<version>2.1.1</version>
<packaging>jar</packaging>
<name>ThemeParkPlus</name>

View file

@ -23,9 +23,11 @@ public class StatusChangeListener implements Listener {
if (title == null) return;
String rideName = ChatColor.stripColor(ConfigUtil.makecolored(e.getAttraction().getName()));
String regionName = ChatColor.stripColor(ConfigUtil.makecolored(e.getAttraction().getRegion().getName()));
String statusAfter = ChatColor.stripColor(ConfigUtil.makecolored(StatusManager.getName(e.getAfter())));
title = title.replaceAll("%RideName%", rideName);
title = title.replaceAll("%Region%", regionName);
String copy = ThemeParkPlus.getSConfig().getFile().getString("DiscordWebhook.Embed.Copyright");
String copyimg = ThemeParkPlus.getSConfig().getFile().getString("DiscordWebhook.Embed.CopyrightImage");
Integer color = ThemeParkPlus.getSConfig().getFile().getInt("DiscordWebhook.Embed.Colors." + e.getAfter().toString());