Made it so that buildings are not counted in the total population count, and that the player can still place those, even when the maximum population has been reached.
This commit is contained in:
parent
932aeb6e82
commit
1fd249a0d2
@ -39,11 +39,11 @@ public class Ally : Entity
|
||||
public override void LevelStart()
|
||||
{
|
||||
base.LevelStart();
|
||||
ResourceManager.Instance.CurrentPopulation += PopulationCost;
|
||||
if(this is not Building) ResourceManager.Instance.CurrentPopulation += PopulationCost;
|
||||
}
|
||||
public override void LevelDestroy()
|
||||
{
|
||||
base.LevelDestroy();
|
||||
ResourceManager.Instance.CurrentPopulation -= PopulationCost;
|
||||
base.LevelDestroy();
|
||||
if (this is not Building) ResourceManager.Instance.CurrentPopulation -= PopulationCost;
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user