Fall Challenge 2023 - Bugs and questions

:slight_smile: could you please share step guide how to run this locally, sorry i am new to npm

anyone have advice for avoiding uglies? Previously Iā€™ve tried moving in the direct opposite direction and Iā€™ve also tried applying a small repelling force to the target x, y based on their position but both end up with me still colliding with them occasionally. Iā€™ve noticed the Silver AI moves very efficiently around them.

1 Like

Where are you struggling?

  • Ensure you have Node.js installed (Download | Node.js). It will bring npm as package manager out of the box.
  • Navigate to src/main/resources/view.
  • Follow the steps as I already descriped
1 Like

Can anyone confirm that epsilonRound() is useless in this line? Or am I missing something?

Yeah. You can ignore it and stick with round().

1 Like

Shouldnā€™t Y be 2,275 in step 43?

Game: Coding Games and Programming Challenges to Code Better

Itā€™s unfortunate because I moved the drone in a position where I thought it would be safe, but I ended up in the monster attack range, so no matter how I move next, my drone enters in emergency mode.

I met the same situation, even the creature speed show -225 but the creature canā€™t go any further than y = 2500.

For y = 2500 :

the collision code does not take into account the snap to map borders

So my drone already has a target in mind before it runs collision checking. It tries that path first and checks the whole path, not just end points given in the turns. If that fails (Comes within 500 of monster) then it tries 1 degree to each side and adds a degree iteratively. Eventually it finds a close path that is still close to my original target. I am sure there is something better but this has gotten me into the 30s a few times as far as placing goes.

Great thanks this is what i was looking for. I was worried this approach may run into the per-turn time limit but I guess Iā€™ll have to try it out. Iā€™ve been working on calculating line-circle intersections and then tangent points, etc. but i think this is overcomplicating things

You probably will. I did. I made a spreadsheet to break down collisions in 600 steps because I was having some odd results and I found out for just a very small step or two out of the 600 steps the collision was resulting a hit. When trying to code this behavior if i put too many steps and too many small angle checks (Going by half degrees, etc) It would fail. Currently with python I am able to check 360 degrees, 1 degree at a time, and am breaking down each turn into 200 steps. This doesnā€™t time out even with 3 fish chasing both subs at the same time. There are probably smarter and better ways to do it faster, but I had to use numpy. I have found a few cases where I actually needed more than 200 steps or less than a 1 degree angle to find an escape route so it could be handy, I just couldnā€™t figure it out.

After uglies collide, the speed drops from 270 units to 200 units. I couldnā€™t find this information in the description. If they collide again, does the speed decrease even more?

Nope. Thatā€™s an error in the referee, where the fishes speed is used instead of the uglies one, but thatā€™s a constant so it will stay 200 even after multiple collisions.

1 Like

I think it is possible that a drone can still drive without having itā€™s engine on (i.e. sending a WAIT action) if the bottom of the map is reached in a previous turn via a MOVE action. This is due to the conditional logic here:

else if (drone.pos.getY() < HEIGHT - 1) {
    Vector sinkVec = new Vector(0, 1).mult(DRONE_SINK_SPEED);
    drone.speed = sinkVec;
}

I stumbled upon it while reimplementing the referee logic, because I intuitively left out the else condition and simply asumed a sinking drone if itā€™s not in emergency mode or actively moving.

I am not sure if the observation is really that relevantā€¦ But effectively, you can sink to the border of the map, then issue one move action changing only the x-axis and enjoy fearless (type 2) fish afterwards if you only issue Wait actions from there on (while moving with the previous speed vector). Thatā€™s at least not conformant with the spec because ā€œengine onā€ is tied to the issued actionā€¦

There is an error in description of Bronze league and probably above.
It says:
Initialization Input
First line: creatureCount an integer for the number of creatures in the game zone. Will always be 12.
While creatureCount includes monsters, so itā€™s not 12 anymore.

2 Likes

I view on the helper tooltip a speed of monster (13,200) so itā€™s not the 270 speed has write in the documentation
Why ? have you the same issu ? (i have a screenshoot but i can post because iā€™m new userā€¦)

The answer was only a few messages above:

Thatā€™s an error in the referee, where the fishes speed is used instead of the uglies one

I am definitely missed some skills about algorithm with decision tree/simulation to make the good decision at y = [6500 ; 7500]. I saw other bots make their decision to: score the point, kill fishs and/or continue to scans.

I got the tree to calculate score depending of actions (scores with drone order and if a fish was killed), I also got simulation of fish positions. But I cannot make the two work together in one algo. I am curious to read your writeups at the end. In general, in challenge, I lake in advanced IA algorithm code to pass legend (also if you have books/articles advices to improve in IA agorithm conception, I will take it :eyes:).

1 Like

:wave: Hi to all and :clap: Congratulations to @MSz for the :1st_place_medal: Winner place :statue_of_liberty: !
and :handshake: Bravo to @reCurse and @zasmu for the :2nd_place_medal:nd and :3rd_place_medal:rd place on the Podium.
I have to say that I admire the struggles of all those who have managed to become legends ā€¦
=> god job to you all :+1: , and nice replays to study :mag: !