Botters of the Galaxy (CC02) - Feedback & Strategies

If you are talking about brutaltester, i’m looking for a way to extract a runnable compatible referee. If you want to just run the referee in local (with the viewer) to play a game, the new structure of referees is far better since you have only 2 lines of code to edit.

37 Legend - Doctor Strange / Ironman

About the game

What is nice

  • New type of game never seen in CG, actually very original!
  • Good opportunities to develop many different strategies
  • I think easy for beginners as it is not necessary to know AI algorithms to master as heuristic perform well

What can be improved

  • Really two much rules that discouraged a lot of persons to play this contest -> like others already said i think this type of game will be very fun in multiplayer but too complex for a 10 day contest (although i do not want contests last more than 10 days). Rules could be introduced step by step using leagues
  • Wood leagues not well used : two much rules from the beginning. boss wood 1 and 2 really strong to begin and wood 3 too low!
  • The main goal of a moba is to kill the enemy camp, it was really weird the tower has so much life that this strategy is currently “never” used (Egaetan you did it well!!!)
  • Graphics seems like we play an alpha game!!! You should take time to improve it before scheduling a date. A lot of bugs, no sprite for shield, no debug mode so only the hardcore gamers can performed using other tools or console to know what’s going on…
  • Referee code is really horrible! code review? providing it is a great idea but with that quality it does not help beginners to improve (sorry for the 3 players which worked on it)

Note
AntiSquid , Illedan and Wildum, do not take all that critics for you. Nevertheless, i really loved this contest and you did a great job, thanks a lot! It was just really difficult to introduce it to new players as it was really complex for them to begin.

Strategy

I played long range since the beginning to avoid losing health and reach bronze. Then, melee strategies appeared but even if “hero rush” seems to be really simple to implement i persisted in my way as i thought it could pay later on.

I used heuristics with a priority strategy and some states computed at the start of each game to adapt my heroes behaviours.

States

  • KillDeny : default behaviour, my heroes will try to kill/deny enemy units staying behind my troops and apply also power combo strategies
  • Survive : enter in survive mode when too low in life, go to a bush or to the tower, buy potions and heal with doctor
  • Flee : used only against melee strategy with rush hero to flee in my camp and use my tower to kill those “bad guys”
  • Groot : used to kill some groots to earn money, at the beginning of the game, when someone use the “groot friend” strategy or when nothing to do as i’m close to the enemy tower waiting for it

Then by priority order

  • fleeGroot : when attacked by a groot not targeted, choose to flee if he can run back or target the enemy heroes or to kill him otherwise
  • goKillGroot : choose to kill groot for money and use doctor shield to avoid damage
  • survive : used in survive or flee mode to avoid dying and heal
  • protect : if a hero is in danger doctor can try to cast shield on him
  • stepBehindTroopsAttack : if one of my hero is in the first line he will move behind my troops using moveAttack to attack pursuers
  • kill : try to kill hero in solo or in cooperation and then units. try to kill in range and try also to kill after creeps attacked
  • buy : try to buy some items sorted by Sum K * features / cost, for ironman i privileged mana regen and damage, and for doctor mana regen and max mana to maximize their spells
  • deny : like killing but for my creeps
  • power : a lot of power strategies like Pulling hero in my creeps, fireball on heroes or groots, burning, healing…
  • move : follow my creeps
    If no action then “wait”

It is really similar to Ferguson strategy. I have also a security range i maintained but i think i have to fix some bugs to never use “attack” and prefer “move attack” to control my position as i lost some life stupidly for a unit kill.

At the end i see some coop bugs where i decided to kill a unit denied just before by a hero and mine move to its latest position facing enemy creeps… I think it’s a referee bug but i could have managed it using “move attack”

Thanks for this contest, i’m waiting for the next one!

EDIT: for multiplayer game it would be nice to raise the limit file size of 100ko to allow players to implement strategies with all the heroes and unique hero (a hero could be chosen only once) would be nice in legend!

2 Likes

@Magus, I’m using my own testing environment, some form of a local league for the code hub. I would love an officially supported engine option (or maybe an alternative maven build if that’s easier) to run games (without visualisation) which would simply return a winner (or order for 3+ player games) and errors. So in essence, to be able to do something like:

java -jar engine.jar -run seed bot1 bot2 [bot3...]

Previously I was able to achieve that by implementing MultiReferee class with a play method that executes the bot processes, writes to their stdin and reads stdout. I’m sure the BrutalTester must be doing something similar and could benefit from the official support too.

Can you please list more details about this?

1 Like

Wish list for the future viewer:

  • A debug mode: units displayed by just a colored circle. Spells displayed by colored shapes too. With health bars.

  • Graphic assets for all spells (shields but also charge/jump. In a replay between a Hulk and a Dr Strange, it’s hard to tell if you are looking at a CHARGE or a PULL). I know you can just read the output but because of the … “lag” between the viewer and the output it’s really really annoying.

  • For me, the first problem of the viewer is that we have nothing to know who is hitting who. The units just hit the air and another unit lose some HP. The damage tooltip is really small and most of the time i was not able to see it. So i just see units hitting the sky :smiley: Just add a graphical assets for the unit projectile. For melee unit i don’t really know what you can add.

5 Likes

Before I give my opinion, let me congratulate the three creators @wildum @Illedan and @AntiSquid, the two additional testers @csj and @nmahoude and the three winners @Saelyos @ValGrowth and @reCurse .

The - (I remember a French teacher in school tell me to always finish with pros if you like a thing…)

  • Instability: too many bugs. I guess we needed one more week for tests. CG is faulty there; we were late on the toolkit stability and then couldn’t test the game enough. The amount of different complex rules didn’t help…

  • Complexity: too many rules, big statement, big stub, big referee. Hey, I play HoTS, do you expect me to like items, denying and last hitting? :stuck_out_tongue: Seriously though, we could have made a better onboarding (more wood leagues) to slowly introduce every rules and make the game more digestable.

The +

  • The team: the 3 creators were incredible. I can tell you that they worked a lot to produce the best game they could. They hot-fixed most of the bugs pretty quickly. They streamed. They did support on chat/forum…

  • The type of game: I understand complaints about the asymmetric character of the game. While it can hurt a bit the top competition, I find it great because it’s very different from what we have on CG.

I finished at rank 51 in Legend (2nd time \o/) and even reached the 2nd place on Friday afternoon. I wish I could code during the weekend and aim for top 20, but I stopped coding on Thursday night (family stuff). The creators must find my ranking funny because I told them on Monday I didn’t really like the game. Let me explain…

I forced myself during the first weekend to code a first AI and get to bronze but I was close to give up because it felt overwhelming. There was no way I could handle everything (not that I needed to). Ellipses in the statement didn’t help.
Finally, I managed to get Bronze and decided to try a few spells. I went directly for Valkyrie (isn’t she great?) and Dr Strange for the PULL-SPEARFLIP combo. Objective was to one-shot squishy targets. I continued with this start because it was very efficient vs Ironman-DrStrange which was the meta.
I think I was one of the first (if not the first) to make it work efficiently. I didn’t care at all for LH or jungle. This got me top 100 on Wednesday. Prioritizing Dr over Ironman (dat %$* BLINK) and playing backwards vs full melee got me to top 5 on Friday.

I liked the game; it was fun. And I’ll be happy to play it more when we release it (soon).

@freecode unless told otherwise, I’ll give your T-Shirt to @Petras2 (rank 22)

8 Likes

I ended 22th in legend

Thanks for the contest AntiSquid, Illedan, Wildum and Freecode for giving me that T-Shirt(it’s my first contest in legend a well as a T-shirt)(I was one place bellow from the T-Shirt range ).

It will be very interesting to see what kind of strategies will develop when the contest goes live again in multi.
So I will briefly tell my strategy that got me so high up(in my opinion).

My Strategy:(I used Strange+Ironman)

First of all I have a function isSafe(), that just returns true/false.
I’m not safe, if I’m in range of towers, infront of my units or my dist to my unit is > than to enemy Units(heroes, troops).

If I’m not safe I just go to a bush that is closest to my tower.
If I’m safe I go behind my troops :

How I select behind what troop to hide :

First, it has to have at least one more troop in its range and I choose the one that is closest to the enemy tower.

How I choose where to stand behind him :
int vx = (troop that my unit is targeting).x - (my chosen troop).x;
int vy = (troop that my unit is targeting).y - (my chosen troop).y;
vx,vy /= distance between those troops;
vx,vy= -1;*
vx,vy=my_troop_movement_speed;*

I almost always use MOVE_ATTACK x y (closest enemy or deny).
My deny algo is dumb just check if I can deny, then deny, same with last hitting.
But if I can deny and last hit, first of all, I deny.
My spells:
I use all of them except burning for Ironman. ( I thought it was not worth my mana.)
1. I use blink, always when I can, if to_go_dist > bling.range, I use it.(restores mana.)
2. Aoheal - I only use on my heroes.(Prefered if 2 heroes are together. )
3. Fireball - always. (Sometimes to lure groots to enemy)
4. Pull - always, if I have at least one unit nearby.(Prefered Strange or lower Hp hero.)
5. I use shield, after I have been puled by Strange or both enemy heroes are attacking me.

Store :

I buy items which has mana > 70, that’s it + I always leave one spot free - for potions.
I buy mana potions - only on ironman.
I only buy mana potions and regular items just for Ironman(Because fireballs are OP. )
I buy health, if my health < maxHealth * 0.7f && item.health + myHealth < maxHealth.
That’s all about it(1k lines of code)
There was some more hard coded strategies to avoid Hulk or Groots.

Sum up :
It was a heuristic friendly contest, even though after mean max I got into sims and I wanted a sim contest with a grid. But I still enjoyed it. I once again thank Freecode for giving his T-Shirt to others! It was really frustrating as I was 0.06 score away from him if I recall correctly… :smiley:

5 Likes

Hey, I still can’t realise that I won :slight_smile:

Here’s my PM : https://github.com/Saelyos/BottersOfTheGalaxy
If you have any questions about it, feel free to ask !

13 Likes

Thinking about change my nickname to freeTShirt…
Sure, as I said that was a goal to stop - give it to @Petras2, he said he will wear it with care LOL
btw I really think it’s really a @Wildum one, even if he is a creator, I don’t agree that they shouldn’t take part:)

@pb4 - tactics… I’ll describe, to be honest I don’t remember everything in details, I even did push on a server bunch of changes without any testing:
0. I used attack_nearest to attack creeps or heroes. Imagine, attack nearest and with this I reached legend!

  1. Always stay behind my creeps. If no creeps between my hero and enemy tower - RUN to my tower
  2. I had one formula only - ‘toughness’, which I compare for my hero versus enemy (separately). Both my doctor strange and ironman always RUN to my tower if they see that enemy will win the potential fight
  3. If I fight versus 2 melee heroes, RUN back to tower if distance from it is more than ~500. Just RUN.
  4. I sorted items by damage and did buy new until I had 3. didn’t sell anything, last place I used to take health if less then 1/3 of hp
  5. I used skills just if no cooldown and some enemy in range. Just on cooldown!

All these I wrote very fast, and was even on the 1st place with it.
That several things which I added to run into legend:

  1. Stupid abuse with groots to beat legend boss. Just fireball to some Groot closer to enemy than to my hero. Funny part here: till that time I didn’t yet read/store bushes and spawn location :slight_smile:
  2. Changed items sort by damage to sort by max mana.
  3. Gave the different location for heroes near my tower - this way when they start to RUN back they always become on different ‘lanes’. And then combining with attack_nearest they keep separately.

I think that I spent on writing two posts and read answers on forum more time than I spent to write that code :confused:

When I saw that I got 3rd place again with this ‘strategy’ in legend, I really decided to stop because it looks only @reCurse tried to play this game serious.

Criticism: my main concern I did describe in previous post. The game is completely unbalanced (with abuses, meh) and has very complicated rules for the contest.
And it was a serious problem with visualization - hard to see if any skill is used, was not clear who attacks whom, units stacks etc.

I understand that guys spent a lot of time on creating it, but for me it was not fun and not challenging, sorry :frowning:

8 Likes

Again. Thanks for sharing.

We wanted to visualize cooldowns … actually i will detail all the things we went through in a blog post, hopefully.

I was…
2 nights without sleep…

4 Likes

What do you mean by exactly by “serious” ?

While i agree with you for most of the points, i don’t think “abusing” of a strategy is not serious playing. For example if we look back at codebuster, Recar won with a “secret tactics” he hide during the whole contest. And i don’t think we can say that Recar is not a serious player :smiley:

2 Likes

I wrote up a full post-mortem of my experience in the competition.

Dissecting my Rusty Superhero Bots — A contest post-mortem

I talk about my experience on the stream, how I apporoached the coding, and a followup about using Rust.

6 Likes

Magus answered for me :smile:. I will add:

  • differents sprites for melee and range units to distinguish them
  • sprites for all spells, some color adjust for example or an icon with opacity on a hero for shield, particles or horizontal lines animation for ironman blink
  • sprite evolution when groot go stronger
  • a debug mode with only circle colors for unit and their range, move line, something to know target

As i said before, the game is very fun but the viewer is really important to understand what’s going on and currently only hardcore gamers will spend some times analysing logs. I think we could have more players with a better viewer and rules introduced slower

1 Like

Thanks @wildum @Illedan and @AntiSquid a lot for the contest, especially seeing the amount of work you guys put in it. It is very exciting to see challenges that change so much every times.

I finished 9th in legend. It is my best rank so far :slight_smile:

For me this contest was a bit unusual. At the start I was unmotivated seeing the complexity, I was convinced that only heuristics would be successful, and I always do very badly on those kinds of game in the past. Anyway, I decided to try doing full simulation, and worked on it quite slowly. Near the end of the contest (Saturday) I finally had my simulation and minimax algo working, and from then, I really enjoyed the game. It is the first time where I did not felt stuck, and I succeeded in constantly improving my bot. I only regret not having enough time to tests all the ideas I had in the end and not being able to keep up with all the strategies that where being submitted by other players until the last moment.

Seeing the complexity (of the rules but also of the resulting interactions), I think 10 days was too short but I think it could be a great multi.

One tiny remark: it would have been nicer IMHO if we were provided the full state…

My bot algorithm was a minimax (me playing first, with alpha beta pruning and reusing best actions previously found). I used a full simulation but I ignored the missing hidden states except the groot aggressiveness (I did not have time to try to recover them). To increase the search depth I used a very limited set of moves for each hero and I restricted my search by doing a minimax for each of my hero using only the closest enemy hero. I used previously found actions for the heroes not under search. The average depth I was reaching was around 3 simultaneous turns (I only reached about 2 to 4k simulations per 50ms, no optimization). The simulation was a straight forward port of the java code to C++.

I chose Hulk and Doctor Strange as heroes and never really tried anything else. My only motivation in choosing them was that I though that the parameter of their skills seemed easier to guess :wink: (no complicated position to compute).

My eval was dead simple, I simply summed up all the properties of every unit with a coefficient per property with the right sign. I simply chosen 10^x values using my intuitions and nearly never changed them (not enough time). Starting from Gold, I also took into account the sum of the potential damages of all the unit in range for each hero. That improved my bot a lot. My eval was symmetric between me and my opponents.

Due to the low number of simulations I could do, I used two set of moves: a limited set for the first depths (2 depths for me, only 1 for my opponent), and a very limited set for the remaining depths. In the end (legend), I decided to never attack the towers nor the groots. When I attacked a unit (hero/lane unit), I always used ATTACK_NEAREST except for skills where I targeted only heroes and, for some, the center of both heroes. I used BUY when possible and always kept one place empty for potions. I never used SELL. The only pure MOVE was to go back to the safe tower.

If you have any questions, feel free to ask !

8 Likes

For multi, try to use MOVE_ATTACK. With this command you can improve your farm, hitting the enemy Lane unit after your Lane units. It improved a lot my farm…

Hi ! I didn’t receive the t-shirt email yet. Is it only me or is it delayed for some reason? My wife is pregnant and the CG t-shirt will be the first gift I give to my soon-to-be-born child :slight_smile:

Thanks !

4 Likes

ahah. They should be sent this afternoon. Also @Saelyos has decided to give the T-Shirt to the next person in the ranking, hence @KimOlegan (rank 23)

@AntiSquid When will multiplayer/bot-programming version be available?

If you don’t want to wait, see here.

4 Likes