is like FloodMicro
with some of the movement from my test bot, SandboxFlattener
put back into it (and alas, some removed again), and a somewhat effective deviant GuessFactorTargeting
gun. This is probably my first all-around effective bot. FloodMicro
was somewhat good at beating good bots and bad at beating bad bots, and of course it lost to most elite bots. FloodNano
was almost stupidly simple, and lost to a lot of really basic bots, but it also beats a lot of really good bots (actually, among these bots that it beats is FloodMini
, I'll come up with some way to hit him, though... maybe...). FloodMini
is both hard to hit and hard to consistently dodge, so it should beat less advanced bots fairly handily and it also beats a lot of more effective bots.
- version 1.0 - codesize 1499 without colors. I'll find room for them again sometime, but I had to make room for saving data, and colors and one other thing in the movement just sort of had to go.
- version 1.1 - codesize 1492 without colors. I trimmed down some code, commented up the MiniBullet? class for people (which I admit is now more cryptic anyways), and managed to fit back in the additional distancing code that I wanted to (so now it's basically exactly the same as Teancum). I also fixed a bug that Rozu found in the wall-avoidance code (which also stops me from getting backed against a wall), which is a big fix I think (especially for FloodMicro, which depends only on movement).
- placed 5th in the Pro League at the Robocode Outpost, season 5, behind SandboxDT, Princess, Cigaret, and (narrowly) Dalek. It also was second only to SandboxDT in total bullet damage.
- fell to 13th or so in season 6. Darn luck...
- Opened at the EternalRumble at 36. Hopefully it will learn a little and grow off that (if I don't end up updating it too much like PEZ seems to do).
- placed 2nd for MiniBots in tobe's MiniBot challenge. It was mostly propelled to its place with a pitiful win over Eva01, but it beat HumblePieLite, almost tied Avipes, killed BlackSwans, and narrowly beat Aspid (who got first) to keep the title, while not losing to anyone by much. Cigaret had a really tough time with a lot of bots...
- version 1.2 - codesize 1499 without colors. I cut down some stuff a bit, and managed to reduce a few repeat calculations between FloodMini and the MiniBullet? class to make it more efficient. Changed some sizes on my stat buffer so it wouldn't waste any file space, and I added a dimension to my stat buffer to capitalize on bots that have weak movement close to the walls. Seems to do better against a lot of bots (hint to all you developers of robots with names such as Cigaret, Dalek, Aspid and Fenrir). Hopefully it will make a difference in the standings.
- took 4th in the Pro league of the Robocode Outpost, season 7. In doing this, it managed to get second in bullet damage and beat Cigaret, both Aspids, both GlowBlows, Marshmallow (who is supposed to be a statist nightmare in the current version, 1.5.4), Avipes, and Tron.
- #12 on the EternalRumble!!!!! That's exciting. rozu estimated 11th I think, so I blame it on him. He must be a roboprophet like we suspected. Sorry, rozu. The 25-place jump put it 6th among Minibots. Hopefully an upcoming upgrade on Teancum will do the same thing.
- #4 among MiniBots in 1-on-1 at the MiniBot Challenge, behind Lacrimas and the GlowBlows. Unlike those above it I think, FloodMini went completely undefeated this round, beating Lacrimas and GlowBlowAPM, as well as Cigaret, Spark, and Avipes. Second time in a row I've faced Avipes and HumblePieLite. (I hope everyone enjoys my play-by-play of the MiniBot Challenge). This same week, FunkyChicken won the nano division, also undefeated, against many of the other top bots in its division.
- Tobe forgot to update to FloodMini 1.3 for competition 20030705, but 1.2 still got 7th place and lost only 1 battle to DuelistMini.
- #2 in the Pro league of the Robocode Outpost, season 10, right behind SandboxDT :-) It's success in this league, I believe, is attributable to it's aggressive nature, tending to get up close to a number of bots, so that it's gun consistantly scores more damage than almost any other bot, even if its survival is a little lower.
- Version 1.3 - codesize 1491 without colors. Found a few bytes here and there, sacrificed a few movement bytes here and there, improved the movement a little as well, including getting rid of a mathematical bug in my wall backing code. It worked most of the time, and especially when I was REALLY getting backed up to a wall, but I found it working on TeancumPassive. I also decided that FloodMini's LateralVelocity segments weren't telling the whole story, and added segmentation for acceleration. This seems to raise its hitrate against pretty much everyone and makes it a stronger bot all around. I also loosened the segmentation a little bit to make fewer distance and LateralVelocity segments than before. I think this is a potential top-10 version.
- Starts the RO Pro division at #3 :-) Even though that's down one spot from last week, I think it will stay there more consistently now, unless FloodHT prevents him ;-)
- Maintains 3rd place in season 12, right behind FloodHT, collecting his traditional 'hardest hitter' award, owning bullet damage. 5th in season 13, 6th in season 14, 3rd in season 15, always winning bullet damage somehow, by a reasonable margin. Kind of like SandboxLump in the old days, but smaller. Where ever he belongs, he's in the right division for 1-on-1.
- Starts the EternalRumble by jumping up 8 spots to #5. In this respect, Rozu's prediction was exactly right. However, he mispredicted one thing - he said he didn't think I could put myself between the Cigarets, which is exactly what I did. CigaretBH skipped ahead of Cigaret this time with me in between, and FloodHT came in above Chameleon, for FloodMini to end up exactly at 5th. Of course, secretly, I'm sure Rozu was subconsciously thinking about this the whole time. This also makes FloodMini the #1-ranked MiniBot on the ER! I think that's spectacular, of course ;-) It also occurs to me that there are a lot more Megabots in the top 10 now than there were a couple weeks ago, with Chameleon, Tron, and FloodHT getting in there. FloodMini actually beat Chameleon and Cigaret (FloodHT didn't beat Chameleon), did pretty well overall (didn't completely embarrass himself) against DT and HT, lost considerably to BH... really was strong overall, though. Rozu was also right about it not beating Princess, but this apparently didn't hurt him too bad. Beating Chameleon was something FloodHT had problems with, and so was Gouldingi, which FloodMini really trashed.
- Finally got to compete in the MiniBot challenge (20030802) and won it! It lost to Cigaret, Smoke, and DuelistMiniMelee, though, which I don't quite get :-p (well, I do, it probably had never seen them before...), but it beat Fhqwhgads, who beat all three of those bots.
- version 1.4 - There were many projects that I entitled "FloodMini 1.4", and this one ended up being it. Mostly it's tuning of the gun (trying to get the best 'big picture' possible) and addition of some Strategy elements (ramming disabled opponents, closing in when I'm ahead so I don't allow comebacks, not firing when my gun is far from turned, etc). I tried to make this FloodMini a significant improvement over the last, but that didn't work, so hopefully I just made it a little better. I think it's about even overall against Cigaret 1.31.
- Got 2nd in the last MiniBot Challenge, but then came back to win the MiniBot Grand Final by a large margin. My guess is that Iiley had several bots in there that beat each other (like I think that Lacrimas is supposed to beat Cigaret, but wasn't as successful of a bot in general), which is what created such a large margin (and the fact that I knocked the living trash out of Avipes, which qualified in the Mini division). It did well, and beat every competitor it had, but it didn't do that well.
- Held its ground in the ER in spite of all the new entries - stayed in 5th place, just ahead of the new Cigaret. Also behind CigaretST, BlestPain, and Sedan, but passed up the new Chameleon, CigaretBH, and FloodHT (although it only beat CigaretBH, out of those 3).
What's special about it?
Call it a hunch, but I think we can consider this "Kawigi
's official first good bot".
Great, I want to try it. Where can I download it?
How competitive is it?
In my tests, it does very well. It saves data between matches, too, which makes it more competitve over a bunch of short spurt-like rounds. It's not too slow to learn, either, and it's a good early-round robot (due to its movement).
How does it move?
. The movement is based on SandboxFlattener
, my test bot. It is less tweaked than FloodMicro
, which I think is good - the test bot was pretty well tweaked, and a few of the things I added or changed going to FloodMicro
were just not worth keeping.
How does it fire?
A sort of deviant version of GuessFactorTargeting
. Someone (it might have been Nano
) told me that some Duelist
bots do this, too - I have my stats divided on distance (which is pretty standard) and the absolute value of their LateralVelocity
. I have distance factors segmented every 100 pixels (10 of them, I just make one segment for 900 and further), LateralVelocity
divided into 3 segments. And then I have 31 guess factors ranging from asin(-9/bulletv) to asin(9/bulletv). I take all the stats using power 3 wave-style bullets, but my opinion is if the guess-factor is translated into an angle using the bullet velocity as I just said, the stats are valid for other powers of bullets, at least at reasonably close range. All stats are also taken relative to the sign of the bots lateral velocity (or last sign of it if the enemy's lateral velocity is zero). I believe that SandboxDT
does it this way too, and logically, it should help it learn twice as fast against most competitive opponents.
As of version 1.2, the statistics are also segmented on the opponent's relationship to the wall - one segment if they will hit the wall if they continue at their current velocity and direction for something like 10 turns, and another segment if they won't. Almost every bot except SandboxDT (1.81 and later) is weaker in this segment, and it was enough to get me to start beating some generally better bots like Cigaret.
As of version 1.3, the statistics are segmented on acceleration - I use actual change in velocity instead of change in lateral velocity for this, because I just felt like it. One segment for staying at roughly the same speed, one for accelerating, one for decelerating. I think this gives the LateralVelocity segments more meaning, and helps me tell a real story, especially when the opponent only slows down when he's changing directions.
For the sake of size, and because I've found it a little unstable, I've never used rolling averages in FloodMini. I also fire a wave every turn and laugh at all the top bots who don't react to bullet fire the way I do and allow me to learn about 16 times faster against them. FloodStationary? only fires a wave when he fires a bullet, so as to be a better diagnostic tool.
It reacts to bullets being fired by its opponent by changing direction and speed. It doesn't react to every bullet like FloodNano
, but it should react to about the same number as FloodMicro
. The movement does have some weaknesses, which may be fixed by a future attempt at a similar movement, but it is (in general) strong, and it is meant to particularly be aimed at making GuessFactorTargeting
less effective. This is ironic, since it uses GuessFactorTargeting
itself, and it is probably less effective at hitting itself than it needs to be (run it a few rounds against the other Flood series, GouldingiHT
, or MakoHT
to see what I mean).
How does the melee strategy differ from one-on-one strategy?
I have not made it work intelligently in Melee
, so I expect its primary strategy would be to lose, whereas its OneOnOne
strategy is to win.
Just a note about using it in melee battles - it will load up data from one bot, and if it doesn't crash every battle with an exception (which it may, starting with version 1.3), it will possibly corrupt that data. Of course, it won't save over the data unless it actually wins a round.
How does it select a target to attack/avoid in melee?
I suppose it would aim at guess factors on the very edges of the range and always hit someone other than who it's looking for if it hits at all.
What does it save between rounds and matches?
It saves its guess factors and its DynamicDistancing
factors. I'm not sure if I've ever read up on another bot that saves defensive information between matches. Can anyone think of one?
Where did you get the name?
Just like FloodMicro
, but twice as big :-p The test-robot for this basic movement concept was SandboxFlattener
, named as such to flatten out that SandboxLump
into a beach to make it hard to hit by GuessFactorTargeting
. What flattens out a pile of sand like nothing? A flood, of course...
Can I use your code?
Sure. Especially if you're working on Wave
, check out MiniBullet?
and how I use it in FloodMini
- it's a fairly effective wave-style virtual bullet class that could easily be applied to either and could also be easily made more versatile. I thought about only including that in the source, but then I realized that half of a class is in how its used externally (especially if you keep cutting down code). If you are making deviants of it (I didn't comment it very well), the 1.41 that is hard-coded in is supposed to be an estimate for asin(10/11), my internal max firing angle offset.
What's next for your robot?
After I see how it does for a little while, I may tweak it a little, or I may leave it alone. Or I may find a bug. I almost uploaded it a day earlier before figuring out that somewhere in my code-trimming I created a bug, which I luckily finally found today.
I like to think that they're all problem bots, and I'm the WhiteWhale
. Realistically, I think that FloodMini
1.3 is capable of beating any current robot except for SandboxDT
, and will probably beat most robots most of the time.
What other robot(s) is it based on?
. I suppose SandboxDT
, since I borrowed some aiming concepts from Paul Evans
, but not in actual code. I was originally actually going to make this a pattern-matcher, but I had a bug in the MiniBullet?
class that I didn't figure out until after I converted it all to statistical targeting.
Comments, questions, feedback:
I know for sure Fermat saved defensive information between matches. Try shooting him with a circular targeter. :p -- Kuuran
Marshmallow has done this since Kawigi showed us how to serialize in a zip stream. Princess does it. And it's the only thing Mako saves between matches as well. I, like you Kawigi sure take movement seriously. =) -- PEZ
Nihil also saved defensive data...a lot of.... HoD
Yes, I think segmenting on closeness to walls can be very good. Marshmallow used to do it, but since I only have half-solved the issue with many-segments=>slow-learning I had to remove it. So Cigaret is vulnerable in that segment huh? Maybe that was why Lacrimas had such en edge on it. (Since Lacrimas fed it's pattern matcher with this information.) -- PEZ
Congrats on the #12 ranking! -- PEZ
Congrats again. You now have two bots before any of mine. I must work harder. -- PEZ
Congratulations!! Great work Kawigi.~;] -- iiley
I readed FloodMini's source code,and known that it stored 5580 int and 40 double for every opponents,and one data file is about 2.5KB,My testing bot CigaretST stored 2583 float for every opponents,but one data file is large as 5KB,i know int and float is all 32bit number(is that right?),2583 float should my about 1/2 of 5583 int,but i get double size of 2583 int's size.This is a large problem for me to improve my gun,is there any guy know the reason?Kawigi? Thanx in advance. -- iiley
Maybe ints are better gzipped than floats? -- PEZ
Oh~~ints,mybe i would have a try on ints.It seems that ints can be gzipp to 1/4 of floats can be. -- iiley
Have you confirmed this in a test? That would help me a lot, because I currently save doubles and should, without losing precision, be able to use longs. And since I don't save nearly as many cells as any of you this should make my data files really small. Or, leave room for more segmentation of course. -- PEZ
Yes,of course,those my true testing.You can have a look on my CigaretST's datas.But i cannot sure is the reason is between int and float.Maybe FloodMini's data is more compressable.~;] -- iiley
Woah, longs? I think ints are more compressible the way I use them, because the first two bytes of every one of them is usually 0's, and quite often the third byte, too. That's because I'm using a count of hits to the bucket instead of an average. If you were to just directly convert doubles to longs in a way that would create extremely large numbers, I think that would still be wasteful. FloodHT 0.9 will use a combination of ints and bytes to store data even smaller ;-) -- Kawigi
produces this error message from time to time: :-( --Dummy
kawigi.sbf.FloodMini 1.4: Exception: java.lang.ArrayIndexOutOfBoundsException
at java.lang.Thread.run(Unknown Source)
Ah, I suppose I don't bound my distance factor there. Oops. It should only happen at a distance of 1100 or more, though. -- Kawigi
IIRC, the scan range of a radar is 1200, so you might want to use that as your maximum distance. --Dummy
Yeah, that's way better than using getBattleFieldWidth?() like I usually do. =) -- PEZ
Well, I suppose I could do that. What I would normally do however, is cap it off (group the furthest few segments into one segment), but when I went from using distance to using bullet flight time, I lost the built in way I used to bound it. The 1100 might sound aribitrary, but it's the distance a power-3 bullet travels in 100 ticks, and I have 10 segments of 10 ticks each. -- Kawigi