Author Topic: Flixel and GC?  (Read 4081 times)

Quickfeet

  • New Member
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Flixel and GC?
« on: Tue, Apr 10, 2012 »
Having quite a difficult time trying to get GC to work with my flixel project? I emailed Semi Secret they said they were swamped and told me to come here for help.....Any Suggestions on how to get it working in my app???

initials

  • Contributor
  • ****
  • Posts: 378
  • Karma: +0/-0
  • Initials
    • View Profile
    • Initials Blog. Code and other things.
Re: Flixel and GC?
« Reply #1 on: Thu, Apr 12, 2012 »
Download Apple's demo.

Bring in the relevant files into your project.
Create a new instance of the GameCenterManager in FlxG.
Make some methods like [FlxG submitAchievement];

I'll try to get a demo out, but I am swamped at the moment, so I wouldn't count on it happening soon.
Initials: Super Lemonade Factory, Super Lemonade Factory Part Two, Above The Clouds, Revvolvver, Four Chambers of the Human Heart

test84

  • Key Contributor
  • *****
  • Posts: 1328
  • Karma: +0/-0
  • ت
    • View Profile
    • My personal site.
Re: Flixel and GC?
« Reply #2 on: Thu, Apr 12, 2012 »
I'm sorry just out of curiosity, are you talking about Garbage Collection here?
blog, twitter, Check out my award winning game, Rot Gut:

initials

  • Contributor
  • ****
  • Posts: 378
  • Karma: +0/-0
  • Initials
    • View Profile
    • Initials Blog. Code and other things.
Re: Flixel and GC?
« Reply #3 on: Thu, Apr 12, 2012 »
I assumed it was GameCenter.

If OP is talking about garbage collection, it works just like other Obj-C.
Code: [Select]
[object release]
Initials: Super Lemonade Factory, Super Lemonade Factory Part Two, Above The Clouds, Revvolvver, Four Chambers of the Human Heart

Quickfeet

  • New Member
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Re: Flixel and GC?
« Reply #4 on: Tue, Apr 17, 2012 »
No I was referring to Game Center. I tried putting in the Apple demo, I get no issues but nothing happens. Not sure why nothing's happening.

tokyotron

  • Member
  • **
  • Posts: 27
  • Karma: +0/-0
    • View Profile
Re: Flixel and GC?
« Reply #5 on: Sun, Feb 3, 2013 »
Late but, with GC leaderboards you generally need a UIViewController to "add" the default leaderboard controller onto, or something like that. With Flixel we don't use UIViewControllers really so that made orientation etc problematic when I tried just adding my own UIViewController. So instead I decided to implement my own leaderboard interface. It's not rocket science, I just grab the GC leaderboard data and then create a new flixel screen in which I output that data.

This is the published game: http://forums.flixel.org/index.php/topic,7050.msg39277.html#msg39277

JasonHPickering

  • New Member
  • *
  • Posts: 3
  • Karma: +0/-0
    • View Profile
Re: Flixel and GC?
« Reply #6 on: Tue, Feb 26, 2013 »
has anyone tried using this. I am still trying to get it to work, and I am a bit lost.

initials

  • Contributor
  • ****
  • Posts: 378
  • Karma: +0/-0
  • Initials
    • View Profile
    • Initials Blog. Code and other things.
Re: Flixel and GC?
« Reply #7 on: Mon, Mar 25, 2013 »
I have gamecenter working in my game. You need to add it to the view in FlxGame and then have some functions in FlxG to handle it.

Have a look through Mode and SLF

https://github.com/initials/Mode-iOS

https://github.com/initials/SLF_SOURCE

Initials: Super Lemonade Factory, Super Lemonade Factory Part Two, Above The Clouds, Revvolvver, Four Chambers of the Human Heart