Locust Invasion (CSCI-261 Elements of Computer Programming)

Michael A. Sanchez, Aliyah Lindsey, and Cong Lin

One day farmer Rasamny went to the field and stumbled upon bird eggs. He first thought about eating the bird eggs, but saw in the newspaper the coming of the locust swarm. The locust swarm appears once every seventeen years, and this year would be the seventeenth. Knowing this, he set out on his mission to train these birds to protect his farm. Since his farm is the most valued food provider for Delaware State University, without his crops the students would be unhealthy and starve.

The locust leader has already begun planning the invasion on the farmland. Just like years prior, the locust had sent a scout to survey the landscape. The scout returned with both good and bad news. The good news being that the vegetation in the field was growing amazingly; but the bad news being that the farmer had a defense of three birds watching the farm. Now that the leader had discovered this, he formulated a plan. “Listen up; we shall invade as a group us! We will not start at full speed in order to fool these avian creatures. Although the more of us there are the faster we can destroy this farm. One of the other locusts asks, “What happens if we fall behind or get separated?!” The locust leader replied, if you are not following me, do what you have to in order to survive and complete the mission of eating the vegetation.

It was not only the locusts that were making their plans. The three birds were also formulating plans. The leader of the other two birds, “Cid,” suggested a keen strategy to take out the locust. “The locust will be the most vulnerable when they are trying to eat the vegetation on the farm. We will chase them down if they get too close to the vegetation. Just know the easiest time to take out part of the group will be when they do not expect us! We must also remember that we must stay near the vegetation in order to protect it; we shall go back and forth between vegetation to ensure they are safe. If it so happens that we fail to protect the vegetation and only one crop is left, we will abandon it and just aim to eliminate the locusts instead.”

With both sides thinking up plans how will it all end? Now will the locust be able to make it to the growing vegetation, or will the birds fend them off and kill them all? Only time will tell which side will succeed over the other, and the fate of Rasamny's farm is close at hand.

Instructions: Use left arrow key to rotate left and right arrow key to rotate right; use up arrow key to accelerate and down arrow key to slow and stop.
Download the executable jar file: Locust Invasion
If applet viewer does not function properly (chances are it will not), please download the executable jar file from the above link.

Applet failed to run. No Java plug-in was found.

Made with Greenfoot -
For license information see: