Edit your scenario -- put in a description:
What is does or demonstrates.
What to look for that indicates state of Actors (when infected; what turned image means, etc.
First, get rid of the two brackets between 'prepare();' and 'Greenfoot.setSpeed(25);'.
Next, assign an image to the 'InfectWorld' class (even if it a blank image).
NOTE: Would it not have been easier to use a for loop as such:
for (int uninf = 0; uninf < 36; uninf++)
{
int myX = Greenfoot.getRandomNumber(15);
int myY= Greenfoot.getRandomNumber(13);
UnInfected uninfected = new UnInfected();
addObject(uninfected, myX, myY);
}
This would add all your UnInfecteds!
We really should be 'discussing' in 'DISCUSS', instead of where commentary on Infect should be.
I'll start a discussion named 'On fixing Infect' -- let us discuss there.
Mik suggested having the people procreate and age and see what rate of infection would kill off the population. I say that is a good idea! Use the scale() method to 'grow' the images; with a variable to keep track of the age of the person. You could use this variable to adjust the chance of infection (the young are less likely to catch the infection). Also, the age could be used to make the un-infected die off even when not infected (chance of dying increases as age increases).
A new version of this scenario was uploaded on Tue Jun 28 03:33:55 UTC 2011
2011/6/11
2011/6/11
2011/6/11
2011/6/11
2011/6/11
2011/6/11
2011/6/11
2011/6/11
2011/6/11
2011/6/11
2011/6/12
2011/6/13
2011/6/14
2011/6/14
2011/6/17