blob: 91b647e5f8edf9a1a3e8269b4a54f7ca96ca58ac (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
package me.Danker.features;
import me.Danker.commands.ToggleCommand;
import me.Danker.utils.Utils;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.StringUtils;
import net.minecraftforge.client.event.ClientChatReceivedEvent;
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
public class GolemSpawningAlert {
@SubscribeEvent
public void onChat(ClientChatReceivedEvent event) {
String message = StringUtils.stripControlCodes(event.message.getUnformattedText());
if (!Utils.inSkyblock) return;
if (message.contains(":")) return;
if (ToggleCommand.golemAlertToggled) {
if (message.contains("The ground begins to shake as an Endstone Protector rises from below!")) {
Utils.createTitle(EnumChatFormatting.RED + "GOLEM SPAWNING!", 3);
}
}
}
}
|