Jump to content

Colony: Difference between revisions

255 bytes added ,  8 years ago
Line 48: Line 48:
* workers += min(capacity, r_breed * r_worker * const)
* workers += min(capacity, r_breed * r_worker * const)
* warriors += r_breed * r_warrior * const
* warriors += r_breed * r_warrior * const
* food += max(0, min(capacity, (r_food * r_worker - level) * (workers+warriors) * const)), Gathering and eating, if r_food*r_worker kept at level or above the food increase, else it decreases.
* food += max(0, min(capacity, (r_food * r_worker - level) * (workers+warriors) * const)), Gathering and eating, if r_food*r_worker kept at level or above the food increase, else it decreases. Level could be 0.5, 0.4, or something...


Transform workers to warriors and vice versa
Transform workers to warriors and vice versa
Line 55: Line 55:


Starving:
Starving:
* if (food <= 0) workers -= ?, warriors -= ?
* if (food == 0) workers -= ?, warriors -= ?, or maybe x = x * 0.99 - const ?
* if (workers + warriors < 1) colony is dead
* if (workers + warriors < 2) colony is dead


Decaying...
Decaying.  
* if (capacity > 10) capacity pt at  decreases if not maintained? ~1%
* food turn bad, slowly decreases? -= const similar to setting 1%?
* food turn bad, slowly decreases? ~1%
Decaying both inhabited and not inhabited
* if (capacity > 10) capacity slowly decreases if not maintained? -= const similar to setting 1%?
* if (capacity < 2) nest is broken and destroyed. If inhabited the ants are killed.