mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
Alerts ChatBot: Support trigger on weather change
This commit is contained in:
parent
1d52d1eadd
commit
81a9955081
8 changed files with 147 additions and 19 deletions
|
|
@ -3294,6 +3294,26 @@ namespace MinecraftClient
|
|||
////handler.SetUserUUID(UUID);
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Used for a wide variety of game events, from weather to bed use to gamemode to demo messages.
|
||||
/// </summary>
|
||||
/// <param name="reason">Event type</param>
|
||||
/// <param name="value">Depends on Reason</param>
|
||||
public void OnGameEvent(byte reason, float value)
|
||||
{
|
||||
switch (reason)
|
||||
{
|
||||
case 7:
|
||||
|
||||
DispatchBotEvent(bot => bot.OnRainLevelChange(value));
|
||||
break;
|
||||
case 8:
|
||||
DispatchBotEvent(bot => bot.OnThunderLevelChange(value));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue