Disabled team switch outside of sandbox/PvP
This commit is contained in:
@@ -196,6 +196,8 @@ public class PlayerListFragment{
|
|||||||
}).row();
|
}).row();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//there's generally no reason to team switch outside PvP or sandbox, and it's basically an easy way to cheat
|
||||||
|
if(state.rules.pvp || state.rules.infiniteResources){
|
||||||
t.button("@player.team", Icon.redo, bstyle, () -> {
|
t.button("@player.team", Icon.redo, bstyle, () -> {
|
||||||
var teamSelect = new BaseDialog(Core.bundle.get("player.team") + ": " + user.name);
|
var teamSelect = new BaseDialog(Core.bundle.get("player.team") + ": " + user.name);
|
||||||
teamSelect.setFillParent(false);
|
teamSelect.setFillParent(false);
|
||||||
@@ -223,6 +225,7 @@ public class PlayerListFragment{
|
|||||||
|
|
||||||
dialog.hide();
|
dialog.hide();
|
||||||
}).row();
|
}).row();
|
||||||
|
}
|
||||||
|
|
||||||
if(!net.client() && !user.isLocal()){
|
if(!net.client() && !user.isLocal()){
|
||||||
t.button("@player.admin", Icon.admin, Styles.togglet, () -> {
|
t.button("@player.admin", Icon.admin, Styles.togglet, () -> {
|
||||||
|
|||||||
Reference in New Issue
Block a user