Cleanup
This commit is contained in:
@@ -530,7 +530,7 @@ public class UnitTypes implements ContentList{
|
|||||||
range = 70f;
|
range = 70f;
|
||||||
itemCapacity = 70;
|
itemCapacity = 70;
|
||||||
health = 400;
|
health = 400;
|
||||||
buildSpeed = 0.6f;
|
buildSpeed = 0.5f;
|
||||||
engineOffset = 6.5f;
|
engineOffset = 6.5f;
|
||||||
hitsize = 8f;
|
hitsize = 8f;
|
||||||
}};
|
}};
|
||||||
|
|||||||
@@ -29,7 +29,6 @@ abstract class BuilderComp implements Unitc{
|
|||||||
@Import float x, y, rotation;
|
@Import float x, y, rotation;
|
||||||
|
|
||||||
Queue<BuildPlan> plans = new Queue<>();
|
Queue<BuildPlan> plans = new Queue<>();
|
||||||
transient float buildSpeed = 1f;
|
|
||||||
transient boolean building = true;
|
transient boolean building = true;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -115,9 +114,9 @@ abstract class BuilderComp implements Unitc{
|
|||||||
BuildEntity entity = tile.ent();
|
BuildEntity entity = tile.ent();
|
||||||
|
|
||||||
if(current.breaking){
|
if(current.breaking){
|
||||||
entity.deconstruct(this, core, 1f / entity.buildCost * Time.delta() * buildSpeed * state.rules.buildSpeedMultiplier);
|
entity.deconstruct(this, core, 1f / entity.buildCost * Time.delta() * type().buildSpeed * state.rules.buildSpeedMultiplier);
|
||||||
}else{
|
}else{
|
||||||
if(entity.construct(this, core, 1f / entity.buildCost * Time.delta() * buildSpeed * state.rules.buildSpeedMultiplier, current.hasConfig)){
|
if(entity.construct(this, core, 1f / entity.buildCost * Time.delta() * type().buildSpeed * state.rules.buildSpeedMultiplier, current.hasConfig)){
|
||||||
if(current.hasConfig){
|
if(current.hasConfig){
|
||||||
Call.onTileConfig(null, tile.entity, current.config);
|
Call.onTileConfig(null, tile.entity, current.config);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ public enum Gamemode{
|
|||||||
rules.attackMode = true;
|
rules.attackMode = true;
|
||||||
rules.waves = true;
|
rules.waves = true;
|
||||||
rules.waveTimer = true;
|
rules.waveTimer = true;
|
||||||
}, map -> map.teams.contains(state.rules.waveTeam.id) && !map.rules().pvp),
|
}, map -> map.teams.contains(state.rules.waveTeam.id)),
|
||||||
pvp(rules -> {
|
pvp(rules -> {
|
||||||
rules.pvp = true;
|
rules.pvp = true;
|
||||||
rules.enemyCoreBuildRadius = 600f;
|
rules.enemyCoreBuildRadius = 600f;
|
||||||
|
|||||||
@@ -97,6 +97,8 @@ public class Rules{
|
|||||||
public static class TeamRule{
|
public static class TeamRule{
|
||||||
/** Whether to use building AI. */
|
/** Whether to use building AI. */
|
||||||
public boolean ai;
|
public boolean ai;
|
||||||
|
/** TODO Tier of blocks/designs that the AI uses for building. [0, 1]*/
|
||||||
|
public float aiTier = 0f;
|
||||||
/** If true, blocks don't require power or resources. */
|
/** If true, blocks don't require power or resources. */
|
||||||
public boolean cheat;
|
public boolean cheat;
|
||||||
/** If true, resources are not consumed when building. */
|
/** If true, resources are not consumed when building. */
|
||||||
|
|||||||
Reference in New Issue
Block a user