Post

Replies

Boosts

Views

Activity

Reply to How can I have an SKSpriteNode follow the same path back and forth?
Actually someone gave me an easier answer on StackOverflow. This is a quote from the link below There is a method called reversed() which you could use. Below I have given your action a name of "youraction" let youraction = SKAction.follow(iconPath0, asOffset: false, orientToPath: false, duration: 1) let reverseaction = SKAction.reversed(youraction) yourspritenode.run(reverseaction) Alternatively, you can just use reversed after the action name to run it in reverse: yourspritenode.run(youraction.reversed()) https://stackoverflow.com/questions/66354936/how-can-i-have-an-skspritenode-follow-the-same-path-back-and-forth/66357189#66357189
Feb ’21
Reply to Did Xcode 12.4 get rid of "storyboards" by default?
Do I need to repeat? When you choose Storyboard as Interface` when creating a new project, you can find AppDelegate.swift or ViewController.swift. And then you can remove what you think is not needed for you. Well then, and please remember that when you first saw my posts, I had just started Xcode and Swift (mid June 2020?). If I go without SwiftUI, do I lose anything? I was watching a tutorial that showed the changes in how to create a text object, and the syntax even seemed more simplified (i.e. changing textcolor). But will I lose any new functionality (enduser wise) by not using SwiftUI? And yes, I have dedicated all day to watching WWDC presentations, and SwiftUI tutorials. I just fear in my time away from Xcode, I missed out on something I shouldn't have. Thanks
Feb ’21
Reply to Did Xcode 12.4 get rid of "storyboards" by default?
Hey OOper, You've helped me a lot before. I don't want to use storyboards, but things have changed in 12.4. For instance there's no more AppDelegate.swift file. I would start at class ViewController: UIViewController before. Now there's struct ContentView: View which I don't recall when in started learning in late 2020. Has something drastically changed? Is it that I never used SwiftUI? I am still working on my game, which I started in Xcode 11.x, so no worries. But I wanted to start a new, non-gaming app, and I guess I need a reference point where to start at so I know where to go. I hope this makes sense.
Feb ’21
Reply to Am having problems adding a user-defined setting
Preprocessor defines are specified in build settings under "Other C flags". You would add something like -DMYSCENE. Huh, there it doesn't work. I found Other C Flags, selected DEBUG clicked to ADD CONDITIONAL SETTING and it didn't work from there. To be safe I tried it with and without the -D I even used cut and paste so there would be no typo errors I know Xcode has been under quite a few changes, am using version 12.1 (in was that makes a difference)
Nov ’20
Reply to Am having problems adding a user-defined setting
In Swift, they are compilation conditions, and defined by SWIFTACTIVECOMPILATIONCONDITIONS. Hope you don't mind, but while it works, I still want to make sure I put it where I should. Project -> Build Settings -> All > (search) "Active Compilation" select Active Compilation Conditions click + select Add Conditional Setting under Debug there is now this additional line : Any Architecture | Any SDK ______________ MYSCENE_______________ MYSCENE Again, does work, but it wouldn't be my first time get the result I want but doing it incorrectly p.s. I can only add one. I try to add a second one, and it overwrites the first. Can't see how to insert it.
Nov ’20