🛡️ Survival First! Outsmart and Outlast
Your goal in Robocode isn’t just to win with brute force — it’s to survive longer than everyone else. Think like a strategist, not just a shooter.
🔍 Brainstorming Tactics
Here are some smart moves to stay alive longer:
- 💡 Energy Awareness – Fire smaller bullets (low power) when your energy is low. Don’t run out of juice while trying to get a knockout.
- 🏃 Constant Motion – Never stop moving. A stationary tank is an easy target.
- ↪️ Perpendicular Turning – When you’re scanned or hit, turn 90° to the enemy. It helps you dodge future shots.
- 🧱 Wall Smoothing – Near the edges of the arena, curve your path slightly to avoid getting trapped.
- 🎲 Random Dodge – Mix up your movements with random speeds and turns so enemies can’t predict you.
✏️ Your Task: Draw these tactics as a flowchart or decision tree. Sketch on paper how your robot might switch between them depending on the situation.
🔍 Robot Research
In your project folder, look inside Robocode/robots
.
You’ll find .java
files for many robots. These files are:
- Well-documented – with helpful comments explaining what each part does
- Tactic-rich – showing real strategies like movement styles, radar locking, and targeting logic
🧠 Open them up and take notes! Can you find examples of the tactics we listed above? Can you spot any new ideas worth stealing for your bot?
Learning from others is how pros get ahead — don’t reinvent the tank!
💬 Discussion
- What was the most clever movement or behavior you saw in the example bots?
- Did any robots show off defense instead of offense?
- Would you rather be fast and dodgy, or slow and powerful?
Let’s share ideas together before we start coding tomorrow!