Ants vs. SomeBees
Introduction
In this project, I have combined functional and object-oriented programming paradigms to implement the required functionalities for a tower defense game called “Ants vs. SomeBees.” The player assumes the role of the ant queen, responsible for populating the colony with brave ants. These ants have the crucial task of protecting their queen from the invasion of evil bees seeking to take over the territory.
The game is composed of a series of turns. During each turn, new bees may enter the ant colony, followed by the placement of new ants to defend the colony. Finally, all insects (ants, followed by bees) take individual actions. Bees attempt to either move towards the end of the tunnel or sting ants that obstruct their path. On the other hand, ants perform various actions based on their type, such as collecting food or hurling leaves at the bees. The game concludes when either a bee reaches the ant queen or the entire bee fleet has been defeated.
Ant army
Each ant possesses unique attributes that make them special. The following is a list of ants along with their special traits.
Harvester Food cost: 2 Armor: 1 |
Thrower Food cost: 3 Armor: 1 |
Short Thrower Food cost: 2 Armor: 1 |
Long Thrower Food cost: 2 Armor: 1 |
Fire Thrower Food cost: 5 Armor: 3 |
Hungry Food cost: 4 Armor: 1 |
Ninja Food cost: 5 Armor: 1 |
Wall Defender Food cost: 4 Armor: 4 |
Body Guard Food cost: 4 Armor: 2 |
Tank Operator Food cost: 6 Armor: 2 |
Scuba Thrower Food cost: 6 Armor: 1 |
The Queen Food cost: 7 Armor: 1 |
Laser Shooter Food cost: 10 Armor: 1 |
Final result
Here is the demo of the game once all of the ant combatants have been implemented (it may take a little bit of time to load in your browser).