This commit is contained in:
@@ -34,6 +34,9 @@ public class Logic implements ApplicationListener{
|
||||
public Logic(){
|
||||
|
||||
Events.on(BlockDestroyEvent.class, event -> {
|
||||
//skip if rule is off
|
||||
if(!state.rules.ghostBlocks) return;
|
||||
|
||||
//blocks that get broken are appended to the team's broken block queue
|
||||
Tile tile = event.tile;
|
||||
//skip null entities or un-rebuildables, for obvious reasons
|
||||
|
||||
@@ -65,6 +65,8 @@ public class Rules{
|
||||
public float unitBuildSpeedMultiplier = 1f;
|
||||
/** How much damage any other units deal. */
|
||||
public float unitDamageMultiplier = 1f;
|
||||
/** If true, ghost blocks will appear upon destruction, letting builder blocks/units rebuild them. */
|
||||
public boolean ghostBlocks = true;
|
||||
/** Whether to allow units to build with logic. */
|
||||
public boolean logicUnitBuild = true;
|
||||
/** If true, world processors no longer update. Used for testing. */
|
||||
|
||||
Reference in New Issue
Block a user