Talk:Melee Strategy

From Robowiki
Revision as of 02:13, 18 November 2007 by AaronR (talk | contribs) (Talk:MeleeStrategy moved to Talk:Melee Strategy: See InterCaps discussion on talk page.)
Jump to navigation Jump to search
Credits - Melee Strategy
Old wiki page: MeleeStrategy
Original author(s): Kawigi

Page title change (re: InterCaps)

I think this page should be "Melee Strategy" and that the MR page should be "Minimum Risk Movement". Obviously we should have redirects because people will still use them as one word, but I think we might as well be consistent. The big reason for doing it on the old wiki was that UseMod automatically made it an internal link if you made it all one word with InterCaps like that, but MediaWiki doesn't, so there's no good reason to do it. Are others cool with this change? --Voidious 20:43, 17 November 2007 (UTC)

Well I agree, it's just that it'll take some time to get used to seeing "Wave Surfing" instead of WaveSurfing :) -- Starrynte 21:03, 17 November 2007 (UTC)

From old wiki's MeleeStrategy page

General

Watch this space for more! -- Kawigi

Indeed very good reading. A real melee-movement (read: AntiGravityMovement or MinimumRiskMovement) goes up to #3 on my prioritylist, a one-on-one PM-gun just has to wait a little longer. -- GrubbmGait

Again thanks! This is a candidate for the "best Robowiki page ever" title. -- PEZ

You're welcome. Added a bit more content (can you tell I'm having trouble focusing on work?). -- Kawigi

Quote: 'Add any other tips that seem to work for you ' End Quote.
What other tips, are there any tips left somewhere. This is the most informative page I have seen sofar. Although most information can be found elsewhere scattered on this wiki, this is the best concentration of useful information I've seen. It feels like I have still to write my first melee-bot. You have my vote. -- GrubbmGait

Oh, there are plenty more development tests which can be applied to melee, I'm sure I haven't exhausted them all (or even remembered all of the ones I've used). Also, is there some place where you're voting for best pages? I think if this is one of the best pages, it's because (at least when I started trying to do it) there just is a lack of information about melee here. There's a few people who are really good at it, but not alot of idea-sharing and implementation sharing. In fact, before I released Coriantumr and Shiz, I think Nimrod and TheArtOfWar were the only top-10 melee bots that were even open-source (and I think most people are a little intimidated trying to read TheArtOfWar's code, simply because of it's mass and complexity). So I guess this is a tribute to the black hole and the prying I did to get information out of the top melee guys when I was newer to it. -- Kawigi

A real pleasure to read this page. -- rozu

Indeed. It's not only because melee info was so scarce before. This page is so well written and composed too. You should consider a writer's career Kawigi. =) -- PEZ

Well, I do think I write clearly (and not all of this is easy to explain!), and an extra read over the more complicated parts usually reveals a better way to explain something. While clear writing is a forte, however, conciseness isn't, so if I get to really trying to explain something (example: the old FloodHT hype page), you should expect to read something long, clear, and often full of rambling and rants. I think that both my clarity and verbosity are partly a result of being an educated native English-speaker (in "programming" circles, this isn't critical, but some people do still have trouble expressing themselves effectively in English. That's why we don't have a big clear disertation like this on what "Wave" pattern-matching is - I'm almost positive Iiley has written one in Chinese on his site, though).

Another thing I've sacrificed for the sake of clarity and organization is order - some of you read this all the way through the first time I posted it, and I've added things to it since then, not necessarily at the end. The diff functionality of the wiki helps reduce the disadvantages of this, though :-) At any rate, I think that this page has stablized a bit, and the last set of links I added will be what really makes it more in-depth. -- Kawigi

Minor Strategy Discussion

Early in the development of Ugluk I noticed that he was doing well in melee. His movement was not complicated either.. it was basically going top speed with a slight weave and bouncing of walls at 45 degrees. While he didn't favor corners or avoid the center of the map, he lived quite a while because in order to remain a favorable target his enemies would have to chase him at top speed like a ram bot, which isn't a popular movement style. It also means he would present himself as a target option to other robots as he went on his way, but with infrequent full circle radar sweeps by the enemy Ugluk had a low chance of being chosen as the most favored target at any point. While the movement has been overhauled a few times, I try to give Ugluk an opportunity to shake pursuers in melee while not actively finishing off an opponent. --Martin Alan Pedersen

How do you make a bot that's shooting at you shoot at another bot (besides moving away from the shooting bot)? --Starrynte

A lot of bots just target the closest bot, so making another bot the closest would be one way. Some bots take energy into account, so shooting at another bot close to it might make it target that one. Really, though, there's only so much you can do... (You could also just try to kill that bot. =))-- Voidious

My latest melee movement is a pretty sound minimum risk implementation. One thing I am observing is that it is pretty weak in the very beginning. If you look at a melee round by how many opponents are left at the time, there is a large portion of it spent with 9 opponents. If your movement can't handle the opening of the round, you are going to get eliminated much more than your share. Right now in testing against the 9 best author's best bots, I am getting more than my share of Last Man Standing, but I am also getting killed first twice as much as the average. I may introduce a new opening movement and then switch after the first person dies. (I've broken it down even further in the past, but with duel style movements.) -- Martin

Right now, Smash is thrashing between enemies a little too much. Does anyone know how to fix? (code is posted at Starrynte/Smash) --Starrynte

There are two good ways to prevent this that I've seen. The first is not to switch targets unless your previous target dies or is at least 10% (for example) more desireable than the current target. In practice, this usually means until someone else is 10% closer to you than your previous target. The other way (which I believe Coriantumr does, but I can't remember for sure) is to realize that it only matters if you thrash too much if you do it right before you were going to fire - so only switch targets if your gun won't cool for another 4 or 5 turns. -- Kawigi

Ok...thnx Kawigi --Starrynte

WaveSurfing as MinimumRiskMovement

Megathanks for making this page Kawigi! Good reading. I'm not sure I agree I wouldn't put the different stages into code. Some of the ChironexFleckeri versions did that even. CF also segments it's movement and targeting stats on this. Even if the latest version only separates the melee stages from the duel one. But that's mostly a codesize issue. It seems CF is using MinimumRiskMovement as you describe it. Though I think that name is too general. I would say WaveSurfing is minimum-risk too. -- PEZ

I definitely think that WaveSurfing is a simulation-involved form of MinimumRiskMovement, in fact, I've even tried (unsuccessfully, but I think I know what my mistakes were) to implement a flattening movement with minimum-risk concepts. As for not coding the different stages, I'm specifically referring to movement - I would encourage targeting based on those phases, because segmentations are all about the observation of different movement patterns in your enemy. Since robots who weren't even coded to care how big the battle is move differently with 4 robots than with 8, it's very reasonable to segment on that. As far as coding it in movement, I think that's dangerous, mostly because it can unnecessarily specialize your bot. I think I remember David Alves saying that he preferred using fluid functions to if statements if he could help it, and this is a good example - if you have a risk function that you want to emphasize some feature more when you have more bots, you can put getOthers() into the function, or if it's something that isn't relative to specific bots, you can make it not scale to getOthers() (what I mean is that if your risk function has a part that involves iterating enemies and a part that doesn't, if you don't multiply the part that doesn't by getOthers(), it will automatically have more bearing with fewer bots on the field, because the total numbers will be smaller). -- Kawigi

I totally understand what David means by fluid functions rather than if statements. I think many of my bots are extremes of that. Aristocles, Pugilist and CassiusClay all have very little of conditionals and work without special cases as much as they can. However, optimal melee behaviour between 10 and 4 bots might not represent a fluid change of state. I say "might" since I have very little experience with this. -- PEZ

I guess that I'm more of the opinion that a fundamentally sound movement implementation will act optimally (albeit differently) in these very different cases, because the goals are primarily the same. Added a few more sections. -- Kawigi

Wave/PM

I don't think there is such a thing as Wave-PM. Unless the mega-failure Resin counts. =) -- PEZ

That's because semantically, you think of any gun for which the shot bearing is calculated from a wave as statistical. Iiley didn't think that way (and I agree with him on this). His gun was very much a pattern matcher (just as much as NanoLauLectrik's gun) - It matched a single pattern. It wasn't a pattern projector - the way it actually calculated the bearing to fire at was unrelated to the pattern, it was the bearing of a wave fired at the point in time of the end of that pattern. -- Kawigi

No, I don't, sementically, think of any gun using waves for shot bearings as statistical. Resin should prove this. And Ali/BumbleBee uses a very Cigaret like gun. Very similar actually. (Though that's a coincident if there ever were one.) It's still statistical. As is Cigaret's. In theory you could take any PM gun and use GFs for projection instead of pattern-replay. It would still be a PM gun. If Cigaret's gun is a PM gun then so are all my Tityus derived guns and FloodMini's too. The only difference is that FloodMini stores the segmented data for much faster access. Look at how the latest version of ChironexFleckeri stores its GF's and you will see a gun that could be tweaked to act exactly like Cigaret's only order of magnitudes faster.All Cigaret is doing is asking "what GF did the enemy end up at last tick that looked like this one?". That's what CFis asking too. FloodMini makes it "ticks" (plural) and uses the most common answer. Where, going from FloodMini to Cigaret, does things turn PM? But hey, remove this babbling! It's now cluttering your excellent melee strategy page. =) -- PEZ

Where, going from FloodMini to Cigaret, does things turn PM? - at the point where it's storing the last 3500 ticks of arbitrary information (plus whatever has been collected this round) and comparing each consecutive group of 72 ticks with the last 72 ticks to find the closest match, it turns into a PM (actually, it looks like he compares every 6th tick back 12 times, probably for performance reasons). Note: Feel free to move this to another, more appropriate page :-) -- Kawigi

I think the important difference between PM and Statist is the sorting. Pure PM sort every pattern to a single unique pattern, and Statist sort all patterns to be a certain number of kind(That's the segments). So in PM, there is not probability or factor, but statist is, PM search the closest match but Statist search the big probability(factor). So in this case, Cigaret's gun are pure PM. FloodMini's are pure statistical. Some combine way search the certain number of closest matchs and then segment it to count the factors was both PM and Statistical(maybe that was how Shadow gun does).

Well now, friends, very excited seen that you are focus into melee, and this is a cool page, Kawigi, great down. Maybe more melee discussing will be added on. The last version of BlestPain i tried to add the Lacrimas 1v1 movement strategy to melee, so BlestPain becamed a melee bot. But it did not good. I's hard to write a good melee movement. But when i saw PEZ and some other robocode friends are try to implement WaveSurfing in melee, i am waiting and see, I am cowered, when i was impelmenting Pear, i plan to implement WaveSurfing melee movement in it, but you know Pear's 1v1 was not enough good yet. Well however, maybe i will have a try.~:] -- iiley

WaveSurfing in Melee

Yeah, I think I knew that BlestPain was trying to do WaveSurfing in melee. It's not a bad thought, really, but it has two downfalls:

  • You don't quite know who's aiming at you in the first place (although I've hinted that you can make a conservative guess)
  • There are too many dang bullets sometimes.

That's not to say it won't work, though.

I hope the net effect of this page is that more discussion, development and general competition will happen in melee. -- Kawigi

Yup, i don't quite know who's aiming at me in the first place, so i can't think of every one are aiming me, i assume every robot target the closest enemy, then i just surf one bot's bullets. So there is not many dang bullets, but it is not very precision but most robots are targeting ther closest enemy in rumble. However, BlestPain are not real a sufer, it's Lacrimas's dodge movement, so it did not very good. If i want to improve it, i should base on Pear, but Pear's movement can hardly turn to melee, months ago, I'm think of just dodge enemy's bullet(The Highest of Factors) by Anti-Gravity, it must be easy to implemented than sufering(Many bullet may be easy to dodge than many Waves). -- iiley

GrudgeBot

I was thinking of making a GrudgeBot, a bot that holds a grudge against the first bot it sees in a melee battle and proceeds every round there after to go after that same bot, ignoring all the others (cept for movement of course) till the bot it has a grudge against is gone. I was gonna do this for the sheer evil of it, but at the same time the bot wouldn't be much of a contender, but instead be a bot that drags down all the other bots. (Sorry i'm having one of those mornings where you just wanna make something truely evil) -- Chase-san

Melee PM

MeleePatternMatcher doesn't seem to work yet. Any ideas? (post on MeleePatternMatching page) --Starrynte