레이블이 center인 게시물을 표시합니다. 모든 게시물 표시
레이블이 center인 게시물을 표시합니다. 모든 게시물 표시

2011년 8월 17일 수요일

[Game Center] How to post a score to the Game Center? Here is is!


For using game center, your app should be on the Itunesconnect and enable Game Cener.

If you did that, here is what you have to do now.

It is very simple. Try the following codes.



GKScore* score = [[[GKScore allocinitWithCategory:@"game category name"]autorelease];
            score.value = totalTime*100;
            
            [score reportScoreWithCompletionHandler:^(NSError* error)
             {
                 if(error != NULL)
                 {
                 }
             }];



It it very easy to post your score but... not much players want to even create account on GameCenter;;

I myself in My App am using both GameCenter and Cocoslive leader boards.

Result?

2000 people in cocoslive leader board.

and 

2 people in GameCenter leader board including me.


Have a good day~ :p

2011년 8월 16일 화요일

[IPhone Dev] Objective C - Singleton

That's the one im using!

+ (GameManager *)sharedGameManager
{
    static GameManager *singletonClass = nil;
    
    if(singletonClass == nil)
    {
        @synchronized(self)
        {
            if(singletonClass == nil)
            {
                singletonClass = [[self alloc] init];
            }
        }
    }
    
    return singletonClass;
}

Mayday Timeattack - Free on Appstore



[IPhone Dev]"This game is not recognized by Game Center" Problem

Straight to the point.

When get "This game is not recognized by Game Center" alert view when you are trying to add Game Center in you app on the device

but works on the simulator, well you are in no problem.

Just remove your app from the device and run on the device again.

It will work. Just got the problem and solved this problem after looked at this thread.

Thanks to Paul.


Mayday Timeattack - Free on Appstore


and now small talk :p

i used cocos2d and cocoslive for 
my game.

But i decided to go for Game Center. 

I haven't tried the "Campaign" from the admob site but i will try it layer.

Anyway looks like somehow they promote itself by "friends thing".

So.. i will update it with Game Center and see how it goes :p

Good day guys~