UPGRADE YOUR SKILLS: Learn advanced Swift and SwiftUI on Hacking with Swift+! >>

Tapp position on screen and graphical elements, what to lear ??

Forums > SwiftUI

Hi,

I am quite new to SWIFT and SWIFTUI and I would like to make a scoring app for shooting. For that I want to draw a target on the screen and save the position of the impact.

Supposing the bullseye is 5 and the next ring is 4 points I wanted to talke the position tapped on the screen by the user and apply the following logic.

If you typed on the surface and the position is not on A then it's B so 4 points else is 5 points. (yes, I know it copuld be also a miss, but I will consider that also if I know how to imoplement the otehr stuff)

My question is what tools/ classes/ modules I have to look for to relize that?

I suppse someing with drawing and tap position on screen.

Thank you!

2      

While you might be able to do it using SwiftUI. I would probably look at SpriteKit which will give you better graphic and touch

This is a good project to follow Project 14: Whack-a-Penguin

Hope that somw help

Nigel

2      

Hacking with Swift is sponsored by Essential Developer

SPONSORED Join a FREE crash course for mid/senior iOS devs who want to achieve an expert level of technical and practical skills – it’s the fast track to being a complete senior developer! Hurry up because it'll be available only until April 28th.

Click to save your free spot now

Sponsor Hacking with Swift and reach the world's largest Swift community!

Archived topic

This topic has been closed due to inactivity, so you can't reply. Please create a new topic if you need to.

All interactions here are governed by our code of conduct.

 
Unknown user

You are not logged in

Log in or create account
 

Link copied to your pasteboard.