Page 1 of 2 12 LastLast
Results 1 to 40 of 51
  1. #1
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default Game Center & Unreal Script

    Hello Community,

    I'm trying to figure out how to get game center working with my game. I did as follows:

    1. setup application settings in frontend
    2. created a new app on my Apple Dev account
    3. Created a single achievement and leader board
    4. Checked out the "Chicken Coup" scripts and setup
    5. checked out the documentation here http://udn.epicgames.com/Three/GameC...ml#Leaderboard technical details
    6. Proceeded to imitate chicken coup's code
    7. Also checked this fellow out http://forums.epicgames.com/threads/...me-Center-Help


    As you might have guessed things did not really work out. On my iPad, when I launch the game and call the necessary functionality that opens a leaderboard nothing seems to happen.

    Does anyone know a more detailed, guide I can read or look at that will help me set up the game center properly in my game? Does anyone know what I may be doing wrong?

  2. #2
    MSgt. Shooter Person
    Join Date
    Apr 2011
    Posts
    70

    Default

    I have the same problem. Any one can help us out?.

  3. #3
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    It doesn't seem like it. I left it alone for a while and worked on other systems, now I'm going to try again, haven't heard a reply since then.

  4. #4
    MSgt. Shooter Person
    Join Date
    Sep 2011
    Posts
    480
    Gamer IDs

    PSN ID: eshwarlion

    Default

    U should maybe use the onlinesubsytemGamecenter and refer it to ur gameinfo class.

  5. #5
    MSgt. Shooter Person
    Join Date
    Sep 2011
    Posts
    480
    Gamer IDs

    PSN ID: eshwarlion

    Default

    Or u can use gamespy

  6. #6
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    Hey Blaklion,

    That is what we are trying to do, but we can't get the onlinesubsystemgamecenter to work. The PC's OnlineSub always seems to be null. Since this is an iOS game we want to stick to using GameCenter only. Could you clarify what you meant here: "refer it to ur gameinfo class".

    Thanks

  7. #7
    Technical Writer - UDN
    Join Date
    Aug 2006
    Posts
    3,820
    Gamer IDs

    Gamertag: ffejnosliw

    Default

    Can you try adding OnlineSubsystemGameCenter to the end of the EditPackages list in BaseEngine.ini in the Engine\Config directory and see if things work as expected?

  8. #8
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    Hey ffejnosliw,

    Thanks for the reply, I already had it in there

    Code:
    [UnrealEd.EditorEngine]
    ...
    EditPackagesInPath=..\..\Development\Src
    EditPackages=Core
    EditPackages=Engine
    EditPackages=GFxUI
    EditPackages=GameFramework
    EditPackages=UnrealEd
    EditPackages=GFxUIEditor
    EditPackages=IpDrv
    EditPackages=OnlineSubsystemPC
    EditPackages=OnlineSubsystemGameSpy
    EditPackages=OnlineSubsystemLive
    EditPackages=OnlineSubsystemSteamworks
    EditPackages=OnlineSubsystemGameCenter 	;I added this
    It didn't make a difference.

  9. #9
    Technical Writer - UDN
    Join Date
    Aug 2006
    Posts
    3,820
    Gamer IDs

    Gamertag: ffejnosliw

    Default

    And you have bDisableGameCenter=false set in your iPhoneEngine.ini, correct?

    Code:
    [OnlineSubsystemGameCenter.OnlineSubsystemGameCenter]
    bDisableGameCenter=false

  10. #10
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    Yup

    Code:
    [OnlineSubsystemGameCenter.OnlineSubsystemGameCenter]
    bDisableGameCenter=false
    UniqueAchievementPrefix=<bundleId.achievements_>
    UniqueCategoryPrefix=<bundleId.leaderboard_>
    A quick question on that note, (just to be sure). I have my bundle setup like the documentation specified (com.something.somthingElse) but on my iOS Dev Portal in some places the bundle id is preceded by a short alpha numeric string. So its <alphanumericstring>.com.something.somethingelse . Is the bundleID only the com.----.----- or should I also include the alpha numeric but before .com? In the itunes connect section, when I created the app it shows only com.----.----

  11. #11
    Technical Writer - UDN
    Join Date
    Aug 2006
    Posts
    3,820
    Gamer IDs

    Gamertag: ffejnosliw

    Default

    Adding OnlineSubsystemGameCenter and setting bDisableGameCenter=false should be all that is necessary to get it working. I just tested it myself in the September UDK.

    Are you testing this on the device and not being shown the login screen when you start the game?

  12. #12
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    Yes,

    When the game launches, nothing happens, I don't get any notification from GameCenter, and if I try to do anything with the system nothing works since OnlineSub is none.

  13. #13
    Technical Writer - UDN
    Join Date
    Aug 2006
    Posts
    3,820
    Gamer IDs

    Gamertag: ffejnosliw

    Default

    Did you confirm the OnlineSubsystemGameCenter.u file was created in the Script directory? The mobile provision UDK is using is definitely for an app id with GameCenter enabled?

  14. #14
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    gameCenter.jpg

    and yes the OnlineSubsystemGameCenter.u is being created, when I compile i see it compiling it. In my provision portal when I go to the App section I see "In App: Enabled" & "GameCenter : Enabled"

  15. #15
    MSgt. Shooter Person
    Join Date
    Sep 2011
    Posts
    480
    Gamer IDs

    PSN ID: eshwarlion

    Default

    No no u should say in ur gameinfo class which online subsytem to use by saying


    OnlineSubSytem= ur subsystem

    And now u told which subsytem to use but does not mean it will do all the networking for u. U should add ur own classes like replication infos and such to tell HOW to use the subsystem. Now u get the concept?

  16. #16
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    Hey Blaklion,

    Thanks for the help, unfortunately I'm finding it hard to understand what you mean exactly. I'm only trying to get the "GameCenter Welcome Screen" to show up whenever I run the app on one of our iOS devices. I know we need to write how it will handle everything later, I only want to "enable" game center so to speak and that doesn't seem to work for me even though I did all the necessary steps outlined.

    I didn't understand what you meant by pointing "OnlineSubSystem" to my subsystem.

  17. #17
    Technical Writer - UDN
    Join Date
    Aug 2006
    Posts
    3,820
    Gamer IDs

    Gamertag: ffejnosliw

    Default

    You shouldn't have to assign anything to anything.

    Can you try (or have you tried) creating a new map from one of the templates, set SimpleGame as the Gametype, and then install to device? Does that show the welcome screen?

  18. #18
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    Hello again,

    Thanks a lot for taking the time to help me out with this. I tried placing "EpicCitadel" onto one of our iOS devices and it still didn't show the login screen. I even tried a different registered device thinking that might make a difference.

  19. #19
    Technical Writer - UDN
    Join Date
    Aug 2006
    Posts
    3,820
    Gamer IDs

    Gamertag: ffejnosliw

    Default

    All I can think of is your mobile provision isn't set up right, you didn't set the right bundle identifier in the info.plist overrides, something isn't right in your .ini files, or...I don't know. I did a clean install, made the two .ini file changes, set up the provisioning, installed to device, and ran the game. Everything worked as expected and the welcome screen was displayed.

  20. #20
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    There has to be something I'm missing. I just created a new provision and still the problem persists.
    Could you possibly list the steps you took to setup everything?

    I created a new App,
    Created a new provision for it - it shows "Game Center Enabled"
    Went into itunes connect
    Created a new app, filled out the details, enabled game center, do I upload an executable?
    Went into UTFrontend - added the provision - edited Info.plist
    Put the first 2 names,
    Put the bundleID: com.-----.----------
    went into the IphoneEngine.ini
    added the info
    bDisableGameCenter = false
    Full recompile
    OnlineSubsystemGameCenter compiles
    Pop it over on the ipad, run the game... nothing.

  21. #21
    Technical Writer - UDN
    Join Date
    Aug 2006
    Posts
    3,820
    Gamer IDs

    Gamertag: ffejnosliw

    Default

    Nothing there looks crazy. I'm not setting anything up in iTunes Connect mainly because I don't have a Mac, but that shouldn't affect the welcome screen showing up I wouldn't think. If your app id shows GameCenter enabled and you use the provision for that app id and make sure to make the two .ini changes, it should just work. I tried it through Unreal Frontend, through the editor, with Epic Citadel and other games, etc. It worked every time. I will ask tomorrow if anyone can think of anything that could cause it not to show, but they confirmed it to be working today as well.

    You could try a clean install (to a new location) and just make the minimal changes and run it and see what happens to rule out any outside factors. By that I mean do not add your content or code or anything. Just change the .ini files, add your provision, and use Epic Citadel.

    Just out of curiosity what version of iOS are you running?

  22. #22
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    I'm not sure which version it is. We have multiple but they are all reasonably up to date. They all have gamecenter to begin with and run dungeon defender/chicken coup pretty well with all the features.

    By the way, You don't really need a Mac to use iTunes Connect, you can set it up through their website: https://itunesconnect.apple.com/WebO.../wo/25.0.0.9.1

  23. #23
    Technical Writer - UDN
    Join Date
    Aug 2006
    Posts
    3,820
    Gamer IDs

    Gamertag: ffejnosliw

    Default

    I should probably know that since I wrote the docs about submitting apps, but it's been so long since I messed with that stuff and it's 3:30am so my brain isn't at full capacity. I'll probably sleep now. Give the clean install a try and see if you can reproduce the same results.

  24. #24
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    Alright ffejnosliw,

    Thanks for all the spectacular help, I'll give the fresh install a run and let you know what happens, goodnight.

  25. #25
    Technical Writer - UDN
    Join Date
    Aug 2006
    Posts
    3,820
    Gamer IDs

    Gamertag: ffejnosliw

    Default

    Any update on this?

  26. #26
    MSgt. Shooter Person
    Join Date
    Apr 2011
    Posts
    70

    Default

    Quote Originally Posted by DanielH View Post
    Yes,

    When the game launches, nothing happens, I don't get any notification from GameCenter, and if I try to do anything with the system nothing works since OnlineSub is none.
    This is what you need to do to get the Game Center Wellcome(apart from ini and including package):

    Go to itunesConnect and clcik in your app(Identifiers):

    Copy the com.xxxx.gamename(Bundle ID, no numbers in front)
    Copy the Aapp id(in my case, numbers)
    And copy the name of the app(on top).

    With this info, open FrontEnd>application settings>edit info .plist overrides>
    There fill the data:
    Display Name: the name of the app in itunes connect
    Bundle name: i putted there my app id numbers
    Bundle indentifier: put the com.xxxxx.yourgamename (from itunes connect without numbers on front).

    With this made, rebuild with frontend, deploy to iOS Device.
    Open Gamecenter, disconnect your gamecenter user. Run your app. It should ask you to log to game center(if not, is beacause misspelling in info .plist), then select Register(or something like that, i dont remember now, dont select your REAL gamecenter user, create a new one, "Sand Box").
    After compleeting this, you should recieve the "wellcome playerxxx" every time you open your game.
    I could get to this point, but after that, i cant get the game to show the Gamecenter multiplayer UI in game to invite other player.
    Any questions, feel free to ask.
    And tell me if you get any progress.
    And SORRY FOR MY ENGLISH(not my native language, as you can se, hehe)
    Last edited by RobyLP; 10-18-2011 at 04:15 PM.

  27. #27
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    Thanks for the info RobyLP,

    It still didn't help. ffejnosliw, I'm going to try a fresh install of UDK-September and try EpicCitadel.

  28. #28
    MSgt. Shooter Person
    Join Date
    Sep 2011
    Posts
    480
    Gamer IDs

    PSN ID: eshwarlion

    Default

    Not going to help either. Just go up on udn and search up networking and replication

  29. #29
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    Fresh install,

    Did the 2 ini changes, tried epicCitadel - did not work.

    Tried again with SimpleCourtyard, nothing. I didn't add any of our packages or code or anything, just did those 2 ini changes and setup UTFrontend :-/

    This is very strange.

  30. #30
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    Hey Blaklion,

    I'm not sure what networking and replication have to do with anything. I'm not trying to make a multiplayer game, only access gamecenter to store achievements and leaderboard information. For now though, simply seeing the login screen would be good enough.

  31. #31
    MSgt. Shooter Person
    Join Date
    Apr 2011
    Posts
    70

    Default

    Quote Originally Posted by DanielH View Post
    Fresh install,

    Did the 2 ini changes, tried epicCitadel - did not work.

    Tried again with SimpleCourtyard, nothing. I didn't add any of our packages or code or anything, just did those 2 ini changes and setup UTFrontend :-/

    This is very strange.
    Just in case, did you enter Apple Developer Center>iOS Provisioning portal>App Ids and enabled Gamecenter there?
    This is an important step, also. Dont use the standard Wilcard AppID, make a new one.

  32. #32
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    Yup, did that and the AppID is a bunch of numbers, not a wild card.

  33. #33
    Technical Writer - UDN
    Join Date
    Aug 2006
    Posts
    3,820
    Gamer IDs

    Gamertag: ffejnosliw

    Default

    This leads me to believe it is the provision/app id not being set up or added correctly or something to do with the device itself (though I know you have tried it on multiple devices).

  34. #34
    Palace Guard

    Join Date
    Jun 2007
    Location
    Christchurch
    Posts
    3,513

    Default

    Were you able to sign into GameCenter when the game started?
    Last edited by Solid Snake; 10-18-2011 at 06:33 PM. Reason: Grammar

  35. #35
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    It has to be something really small and really stupid that is being overlooked...
    ffejnosliw and RobyLP and Blaklion thanks a gigaton for all the help, I've taken up enough of all your time. We'll just keep at it till we figure out what exactly is going on. If I discover anything I'll be sure to post it here.

    Thanks again for all the help

  36. #36
    MSgt. Shooter Person
    Join Date
    May 2006
    Posts
    61

    Default

    The provisioning stuff shouldn't actually matter - it should say "This application is not recognized by Game Center" or whatever if the provisioning/app-ID is messed up.

    If this:
    OnlineSub = class'GameEngine'.static.GetOnlineSubsystem();
    returns None, then that indicates one of the following:

    OnlineSubsystemGameCenter.u is not in the .ipa
    --> rename your .ipa to .zip, open it, and verify it's in the CookedIPhone directory)


    [OnlineSubsystemGameCenter.OnlineSubsystemGameCente r]
    bDisableGameCenter=true
    --> Look in UDKGame\Config\IPhone\Cooked\IPhone-UDKEngine.ini to double check, this is the file that's used


    Your phone is less than iOS 4.1
    --> Verify in the Settings app


    Hope something here helps!
    Josh
    Josh Adams | Programmer | Epic Games

  37. #37
    MSgt. Shooter Person
    Join Date
    Aug 2010
    Posts
    239

    Default

    Thanks for the info Josh,

    I'll be sure to post here if the problem is remedied in case anyone else is suffering from it.

  38. #38
    MSgt. Shooter Person
    Join Date
    Apr 2011
    Posts
    70

    Default

    Quote Originally Posted by Solid Snake View Post
    We're you able to sign into GameCenter when the game started?
    I get Gamcenter log in, the famous "Wellcome Playerxxx ****SANDBOX****". Lets hope DanielH gets there soon!!!
    (DanielH read this post, it says yo use May build, but August should work too: http://forums.epicgames.com/threads/...1#post28759669)

    Now we need to move on, we want to enable GameCenter Multiplayer.
    I use Krussel's code in my playercontroller, but I cannot get standard GameCenter Multiplayer UI(like in Infinity Blade, when you press the Multiplayer Button).
    My game starts and nothing happens, i mean, it plays like a standard single player. I dont ever get the Gamecenter UI to appear on screen, like Epic documentation says.
    I may be missing something here, some function to call the GC UI. The code I'm using is at the end of this post.
    My router is fine, beacause i can play Infinity blade beetween my iPhone 4 and my iPad 2.

    I get logs on my mac like this(I guess it is connected to GC??):

    Oct 18 19:06:59 unknown UDKGame[3578] <Info>: 19:06:59.186007 com.apple.AVConference: GKSConnSettings: set server: {
    "gk-cdx" = "17.155.5.253:4398";
    "gk-commnat-cohort" = "17.155.5.237:16386";
    "gk-commnat-main0" = "17.155.5.236:16384";
    "gk-commnat-main1" = "17.155.5.236:16385";
    }

    What is missing here to make the GC Multiplayer UI to pop in the game screen?? (sorry I'm not very good at UnrealScript)
    Code:
    class HKPlayerController extends UTPlayerController;
    
    // These don't need to be filled in with data but they cannot be none or ShowMatchmakingUI will crash
    var OnlineGameSearch SearchSettings;
    var OnlineGameSettings GameSettings;
    
    simulated event PostBeginPlay()
    {
        super.PostBeginPlay();
        SearchSettings = new class'OnlineGameSearch';
        GameSettings = new class'OnlineGameSettings';
    // OnlineSuppliedUIInterface(OnlineSub.GetNamedInterface('SuppliedUI')).ShowMatchmakingUI(0, SearchSettings, GameSettings); JUST TO TEST, NOT WORKING HERE
    }
    
    
    function ClearCreateOnlineGameDelegates()
    {
        OnlineSub.GameInterface.ClearCreateOnlineGameCompleteDelegate(OnCreateOnlineGameComplete);
    }
    function OnCreateOnlineGameComplete(name SessionName,bool bWasSuccessful)
    {
        local string URL;
        local string MapName;
    	local string GameTypeName;
        if(!bWasSuccessful) {
            ClearCreateOnlineGameDelegates();
            `Log("OnCreateOnlineGameComplete was NOT successful");
            return;
        }
        MapName = WorldInfo.GetMapName(true);                   // Retrieve Map Name
    	GameTypeName = PathName(WorldInfo.GetGameClass());      // Retrieve Game Type
        URL = MapName $ "?game=" $ GameTypeName $ "?listen";    // Make URL
    
    //  URL = "map01" $ "?game=MyGame.MyDeathmatch" $ "?listen";      Old Krussel Script
    
        `Log("Resulting URL is ("$URL$")");
        ClientTravel(URL, TRAVEL_Absolute);
    
        ClearCreateOnlineGameDelegates();
    }
    
    
    function ClearJoinOnlineDelegates()
    {
        OnlineSub.GameInterface.ClearJoinOnlineGameCompleteDelegate(OnInviteJoinComplete);
    }
    function OnJoinOnlineGameComplete(name SessionName,bool bWasSuccessful)
    {
        local string URL;
    
        if(!bWasSuccessful || OnlineSub == none || OnlineSub.GameInterface == none ) {
            ClearJoinOnlineDelegates();
            `Log("OnJoinOnlineGameComplete was not Successful, OnlineSub = OnlineSub.GameOnteface = none");
            return;
        }
    
        if (OnlineSub.GameInterface.GetResolvedConnectString(SessionName,URL))
        {
            // allow game to override
            URL = ModifyClientURL(URL);
    
            `Log("Resulting url is ("$URL$")");
            // Open a network connection to it
            ClientTravel(URL, TRAVEL_Absolute);
        }
        ClearJoinOnlineDelegates();
    }
    
    function OpenNativeMatchmakingUI()
    {
        local OnlineSuppliedUIInterface OSI;
    
        if(OnlineSub == none)
            OnlineSub = class'GameEngine'.static.GetOnlineSubsystem();
    
        if(OnlineSub == none)
            return;
    
        if(OnlineSub.GameInterface == none)
            return;
    
        OSI = OnlineSuppliedUIInterface(OnlineSub.GetNamedInterface('SuppliedUI'));
        if (OSI == none)
            return;
    
        OnlineSub.GameInterface.AddCreateOnlineGameCompleteDelegate(OnCreateOnlineGameComplete);
        OnlineSub.GameInterface.AddJoinOnlineGameCompleteDelegate(OnInviteJoinComplete);
        OSI.ShowMatchmakingUI(0,SearchSettings, GameSettings);
    }
    
    defaultproperties
    {
    
    }
    I'm using July, August & Setpember UDK, no luck.
    Last edited by RobyLP; 10-19-2011 at 09:16 PM. Reason: For Better Understanding

  39. #39
    MSgt. Shooter Person
    Join Date
    Sep 2011
    Posts
    480
    Gamer IDs

    PSN ID: eshwarlion

    Default

    U should add some function bool where wen successfully logged in it shows the welcome back thing

  40. #40
    MSgt. Shooter Person
    Join Date
    Apr 2011
    Posts
    70

    Default

    Quote Originally Posted by blaklion View Post
    U should add some function bool where wen successfully logged in it shows the welcome back thing
    Hi, I did not understand, i edited my previous post for better understanding...


 
Page 1 of 2 12 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Copyright ©2009-2011 Epic Games, Inc. All Rights Reserved.
Digital Point modules: Sphinx-based search vBulletin skin by CompletevB.com.