Post

Replies

Boosts

Views

Activity

Reply to How to hide the scroll bar in a SpriteView when Digital Crown is used
A friend of mine gave me the solution! To stop the scroll bar appearing when using the digital crown, set isContinuous to true in the .digitalCrowRotation. Here is my latest code which no longer shows the scroll bar: struct GameScreen: View {   @EnvironmentObject var screenController: ScreenController   @State private var crownPosition = 0.0   var body: some View {     GeometryReader { reader in       SpriteView(scene: GameScene(size: reader.size, crownPosition: $crownPosition))         .focusable()         .digitalCrownRotation($crownPosition, from: 0, through: 400, by: 4, sensitivity: .medium, isContinuous: true, isHapticFeedbackEnabled: false)     }   } } I hope this helps others.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Jun ’22
Reply to SpriteKit - How do I learn to use this?
Paul Hudson also covers integrating SpriteKit with SwiftUI - which is something I am doing for all my new games. I use SwiftUI for the surrounding menus and setting screens and SpriteView for my SpriteKit screen. https://www.hackingwithswift.com/quick-start/swiftui/how-to-integrate-spritekit-using-spriteview
Topic: App & System Services SubTopic: Core OS Tags:
Oct ’22