battle-snake / battle_snake

AI Programing Competition Game Server
GNU Affero General Public License v3.0
12 stars 11 forks source link

Question about Collisions #33

Open exzizt opened 6 years ago

exzizt commented 6 years ago

Are head-on collisions resolved first, then all other collisions are considered equal and resolved next?

For example:

image

If 7 and 9 have a head-on, 9 will kill 7--if the brown snake moves right, will it survive since 7 is killed in the head-on collision? Or, will it and 7 die in this case?

What I mean by all other collisions except head-ons being equal is, for example, brown and 7 both turn right--will they both die (brown collides with 7 and 7 collides with itself), or are self-collisions resolved first, therefore brown will survive?

Thanks for your help.

daniel-swu commented 6 years ago

All collisions are evaluated together, so there is order dependent operations. So in your example brown will still die.

exzizt commented 6 years ago

Thank you.

brandonb927 commented 6 years ago

@exzizt we've moved development work over to https://github.com/sendwithus/battlesnake-server/ and further issues should be addressed over there. Reach out if you have questions or issues at all!

Cheers 🍻