mirror of
https://github.com/ClassiCube/MCGalaxy.git
synced 2025-09-18 03:39:04 -04:00
Fix getting pushed in /ref mode even with -push MOTD (Thanks Scav)
This commit is contained in:
parent
b7b5f82c4a
commit
74b90ab030
@ -207,8 +207,14 @@ namespace MCGalaxy {
|
||||
motd = Chat.Format(motd, this);
|
||||
OnSendingMotdEvent.Call(this, ref motd);
|
||||
|
||||
// change -hax into +hax etc
|
||||
if (Game.Referee) motd = motd.Replace('-', '+');
|
||||
// Change -hax into +hax etc when in Referee mode
|
||||
// (can't just do Replace('-', '+') though, that breaks -push)
|
||||
if (Game.Referee) {
|
||||
motd = motd
|
||||
.Replace("-hax", "+hax" ).Replace("-noclip", "+noclip")
|
||||
.Replace("-speed","+speed").Replace("-respawn", "+respawn")
|
||||
.Replace("-fly", "+fly" ).Replace("-thirdperson", "+thirdperson");
|
||||
}
|
||||
byte[] packet = Packet.Motd(this, motd);
|
||||
Send(packet);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user