Post

Replies

Boosts

Views

Activity

Reply to dynamic name for variables swift
You can really do this "Super Directly" But for a property in a class (or struct even in Swift), you can use @selector, to fetch the VALUE of the property, using a String, if you use Setters/Getters... But no you can't really CREATE a variable with on the fly, but as others have said USE A DICTIONARY! For instance var myOnTheFlyHeap: [String : Any] = [ : ], or [String : Any?] and just throw something in! myOnTheFlyHeap["person1"] = "Johnny Appleseed" Laters...
Jan ’22
Reply to Controller not working in macOS 12.3
Xcode 13.3 Yes sir. I have a Steel Series on my macOS 12.3 and an Xbox Controller on my iPhone 15.4. With the iPhone 15.4 the Virtual Controller Comes up, and works, then when connecting the Xbox the VC goes away and the Xbox Controller works. With my MBP 16 M1Pro macOS 12.3, the observation methods get registered, but NEVER get called... I cannot trigger the "didConnects" Whether turning on before launch after launch etc Been looking for some NEW PLIST entry can't find anything...glad I am not the only, cause now I can go to something else...thanks ¯_(ツ)_/¯
Mar ’22
Reply to Controller not working in macOS 12.3
I still have a weird issue, but like I said on my iPhone, my Xbox controller will connect, and then make the Virtual Controller disappear indicating that the Controller is connected (at least). But nothing functions from the Xbox controller. Then turn off controller and Virtual Controller comes back on... (the controller is there in the debug info, Mac too if I am not mistaken).
Mar ’22