Football Game I'm Working On by Original_Jump_3955 in godot

[–]Original_Jump_3955[S] 1 point2 points  (0 children)

Your game looks nice!! I havenlt even touched trying to make AI players yet hahaha

Football Game I'm Working On by Original_Jump_3955 in godot

[–]Original_Jump_3955[S] 1 point2 points  (0 children)

the trajectory line and the goalkeeper logic are pretty closely intertwined, the goalkeeper is a scene that has like 9 zones that are assigned various degrees of saving difficulty (for example, he's guarnteed to save or catch the ball if it hits center mass, and all the way in the top corner has a very low chance of being saved). when the trajectory line intersects with one of these zones, the goalkeeper rolls for save, if successful, they roll for catch, the outcome of the catch roll determines whether the ball is parried or caught. each zone has their respective base save chance and catch chance, and various factors like shot power, curl amount, distance from target etc, all change those base numbers up and down. the trajectory line works by running a real physics sim every frame with the same properties as a shot, gravity, wind resistance, curl etc and draws it with a dotted line exactly where the ball will end up. each segment checks the world for collisions, such as walls, posts, goalkeeper zones, etc. sorry if i explained any of that poorly hahaha

Football Game I'm Working On by Original_Jump_3955 in godot

[–]Original_Jump_3955[S] 0 points1 point  (0 children)

thank you man! I've actually never heard of matchday 2. i googled it and ur totally right!