I'm a noobie in Swift. I would like to pass an instance of GameViewController or GameScene to a HelperClass as follows. In java I could use Object
for this. How is this done in Swift?
func getHighscores(leaderboardID: String, caller: **whatTypeHere**) {
...
}
so basically I want to notify the right caller when I get the highscores from the GameCenter.
As I understand you want "caller" to be any type you want. In this case you need to use "AnyObject" type here. Documentation
Collected from the Internet
Please contact [email protected] to delete if infringement.
Comments