For those of you who were involved in the
'Degrees of Rotation' thread and have seen my
Ants program, You might be interested in this.
I've completely started over, only this time i've added a scent radius around the food and kept the code nice and readable.
(though i'm still not used to declaring all my variables
every time i use them... especially if they are temporary and only used in one circumstance.)
Anyways, I'm working on adding a monitoring form (instead of having the population and whatnot shown on the main form where the ants are)
It's not as complete as the other version, (not that that was anywhere near complete to begin with) but a lot of the basics are there. I still need to add intelligence levels and farming/carrying capabilities to it.
There does seem to be one major glitch that i'm having trouble locating, and it's the cause of most of the ant deaths. sometimes when they know where food is, they try to get to it and appear to be blocked somehow. they just sit there and move left and right (or up and down) in a (for some reason) futile effort to reach the food they seek, even though it may be only a few pixels away.




Reply With Quote