I am very new to mobile programming have this mobile project that has the player drawing a circle over an enemy or anywhere and in code it would require me to find the middle of that circle and launch a mortar projectile there.
This is a top down action game and the scale of the player to enemies is like a human to a middle sized dog (maybe up to waist) and these are seen from a UAV.
So basically I would like the code to flow this way:
User draws circle (Circle will be traced with a line preferably)
OPTIONAL: Able to draw only over enemy (This will many issues I’m guessing because I’m going to have a lot of enemies on screen at a time)
The code finds the middle of the circle (Probably getting start/end point and adding the radius to it I’m not sure)
Save that coordinate for bomb target and show an point on screen as target.
I know gestures like circles are not easy but I don’t need a super accurate or complex one because the middle point is the more important one.