Diamond

From RoboWiki
Jump to: navigation, search
Diamond
Diamond collage thumb200.png
Full Size
Author(s) Voidious
Extends AdvancedRobot
Targeting Dynamic Clustering,

Displacement Vectors, GuessFactors

Movement Minimum Risk,

DC/GF-Wave Surfing

Current Version 1.8.28
Code License zlib
Download
Source
Sub-pages:
Version History - DiamondHawk
Youtube has a video of Diamond in action: click here to watch

Background Information

What's special about it?
Oh, nothing, really. Well, since you asked...
How competitive is it?
Very! #2 in Melee behind Neuromancer, #2 in 1v1 behind DrussGT.

Strategy

How does it move?
In melee, it uses a Minimum Risk Movement, evaluating a bunch of points around itself and choosing the best one. I'm always tweaking the parameters, but some of them are:
  • Stay far away from other bots.
  • Stay perpendicular to other bots.
  • Don't be the closest bot to any other bots (to avoid being targeted).
  • Weight risks by energy and bullet damage factors.
  • Some randomizing based on past locations.
In 1v1, it uses Wave Surfing with Dynamic Clustering.
  • Predicts where he would intersect the enemy wave if he orbits clockwise, counter-clockwise, or slams on the brakes. Calculate the danger for this position based on where we've detected enemy bullets.
  • For each predicted spot on the first wave, branch from that position and predict clockwise/counter-clockwise/stop on the second wave. Take the lowest danger.
  • Weight the wave dangers by time to impact and bullet power.
  • Multiply in a distancing factor.
  • Choose the safest of the 3 movement options.
How does it fire?
The gun uses Dynamic Clustering for data analysis - i.e., k-nearest neighbors to find similar states, and kernel density among those states to settle on a firing angle.
In Melee, it uses displacement vectors for recording and reconstructing firing angles - I think that makes more sense than GuessFactors since enemies aren't necessarily moving relative to you, and it's a lot simpler and more efficient than real Play It Forward. In 1v1, it uses GuessFactors with precise MEA. It uses precise intersection and interpolates missed scans when necessary.
I also experiment with gun stuff quite a bit with WaveSim. My latest experiments involve using a RetroGirl/Gun for the first few shots of a 1v1 battle.
How does it select a target to attack/avoid in melee?
As of 1.30, it no longer does. It aims at everyone on the battle field at once and tries to hit as many enemies as possible. (Big thanks to Shadow/Melee Gun for the excellent idea.)
How does the melee strategy differ from one-on-one strategy?
In 1v1, it switches to a Wave Surfing movement and to its 1v1 Virtual Guns.
What does it save between rounds and matches?
Nothing between matches. Between rounds, it saves all its targeting and movement data, which includes general info about each enemy, a bunch of kd-trees, and maps of the trees' data points to displacement vectors and GuessFactors.

Additional Information

Where did you get the name?
Diamond is the ex-superhero name of the main character in Powers, my favorite comic book series. I like to name all my bots after warriors of some sort, but I'd be lying if I said I didn't just think it sounds cool.
Can I use your code?
Yes, it's released under the zlib license. You can find it in the JAR and I put v1.8.28 up at GitHub/Voidious/Diamond.
What's next for your robot?
I'd love to take the 1v1 throne. A lot. =) But I'm probably retired from writing Robocode bots.
Does it have any White Whales?
DrussGT
What other robot(s) is it based on?
I tried to start with a clean slate on this one. But I've taken plenty of ideas from the wiki and utility code from a few places.
Personal tools