Make it possible to walk on the floor in prefight stage
Signed-off-by: Lixfel <agga-games@gmx.de>
Dieser Commit ist enthalten in:
Ursprung
ab4852c717
Commit
aeda617a55
@ -58,6 +58,7 @@ public class Config {
|
|||||||
public static final int ArenaMinZ;
|
public static final int ArenaMinZ;
|
||||||
public static final int ArenaMaxX;
|
public static final int ArenaMaxX;
|
||||||
public static final int ArenaMaxZ;
|
public static final int ArenaMaxZ;
|
||||||
|
public static final boolean GroundWalkable;
|
||||||
|
|
||||||
//schematic parameter
|
//schematic parameter
|
||||||
public static final boolean OnlyPublicSchematics;
|
public static final boolean OnlyPublicSchematics;
|
||||||
@ -154,6 +155,7 @@ public class Config {
|
|||||||
BorderFromSchematic = worldconfig.getInt("Arena.BorderFromSchematic");
|
BorderFromSchematic = worldconfig.getInt("Arena.BorderFromSchematic");
|
||||||
AlignWater = worldconfig.getBoolean("Arena.AlignWater");
|
AlignWater = worldconfig.getBoolean("Arena.AlignWater");
|
||||||
WaterDepth = worldconfig.getInt("Arena.WaterDepth");
|
WaterDepth = worldconfig.getInt("Arena.WaterDepth");
|
||||||
|
GroundWalkable = config.getBoolean("Arena.GroundWalkable");
|
||||||
|
|
||||||
SchematicType = de.steamwar.sql.SchematicType.fromDB(config.getString("Schematic.SchematicType"));
|
SchematicType = de.steamwar.sql.SchematicType.fromDB(config.getString("Schematic.SchematicType"));
|
||||||
IgnorePublicOnly = config.getBoolean("Schematic.IgnorePublicOnly");
|
IgnorePublicOnly = config.getBoolean("Schematic.IgnorePublicOnly");
|
||||||
|
@ -70,14 +70,12 @@ public class PlayerMoveListener extends BasicListener {
|
|||||||
boolean inArenaY = to.getY() + 1.8 <= Config.upperArenaBorder;
|
boolean inArenaY = to.getY() + 1.8 <= Config.upperArenaBorder;
|
||||||
|
|
||||||
if(to.getY() <= Config.underArenaBorder) {
|
if(to.getY() <= Config.underArenaBorder) {
|
||||||
if(player.getGameMode() == GameMode.SPECTATOR){
|
if(player.getGameMode() == GameMode.SPECTATOR || team == null)
|
||||||
reset(event, DENY_ARENA);
|
reset(event, DENY_ARENA);
|
||||||
}else if(FightSystem.getFightState() == FightState.RUNNING || FightSystem.getFightState() == FightState.ENTERN)
|
else if(FightSystem.getFightState().infight())
|
||||||
player.damage(2);
|
player.damage(2);
|
||||||
else if(team != null){
|
else if(!Config.GroundWalkable)
|
||||||
player.teleport(team.getSpawn());
|
player.teleport(team.getSpawn());
|
||||||
}else
|
|
||||||
reset(event, DENY_ARENA);
|
|
||||||
}else if(team != null && !inArenaY){
|
}else if(team != null && !inArenaY){
|
||||||
reset(event, DENY_ARENA);
|
reset(event, DENY_ARENA);
|
||||||
}
|
}
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren