nanomunchers
Class NanoSimulator
java.lang.Object
nanomunchers.NanoSimulator
- public class NanoSimulator
- extends java.lang.Object
Simulates the battle of the nanomunchers.
Makes Life and Death decisions
- Author:
- David Kaplin
Method Summary |
java.util.Vector |
feedSimulation()
Feeds the game information to the simulation
move by move, frame by frame. |
void |
prepareSimulation()
Removes any duplicates
ensures all bots are alive and registered with the simulation. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
NanoSimulator
public NanoSimulator(NanoSimulation sim,
Graph board,
NanoBotWrangler wrangler,
java.util.Vector players)
- Parameters:
sim
- To be updated with new framesboard
- where the game will take placewrangler
- in charge of ownership of nanobotsplayers
- that will be in this game.
prepareSimulation
public void prepareSimulation()
- Removes any duplicates
ensures all bots are alive and registered with the simulation.
feedSimulation
public java.util.Vector feedSimulation()
- Feeds the game information to the simulation
move by move, frame by frame.
Based on the current and future positions of
nanomunchers decides whether or not they live or die.
- Returns:
- The results of the simulation