Search Unity

[Released] IOS Native Unity3D Plugin

Discussion in 'Assets and Asset Store' started by lacost, Apr 22, 2013.

  1. gregory_igromatic

    gregory_igromatic

    Joined:
    Feb 1, 2014
    Posts:
    25
    Sorry if the topic was covered before. Is there (or planned) support for text-to-speech?
     
  2. BenoitFreslon

    BenoitFreslon

    Joined:
    Jan 16, 2013
    Posts:
    136
    Hello,

    iOS Native 6.1: the native Facebook share has a blank text message when the popup prompts.

    string text = "test";
    IOSSocialManager.instance.FacebookPost (text, myTexture);

    I don't know if it's a security reason.

     
  3. loyalpenguin

    loyalpenguin

    Joined:
    Mar 5, 2013
    Posts:
    16
    Hello, I'm trying to implement realtime multiplayer into my game. When I run the example I am able to send the invitation and accept the invitation. But when the game starts the application no longer receives input. You can't even press the disconnect button in the top left. I'm thinking this has to do with the Game Center View that is displayed, because if you cancel the Game Center view and return to the app, the app no longer receives input as well. I did implement a timer inside of the example to send data automatically without having to touch, and it is sending data successfully from one device to the other. My test devices are an iPhone 5s and iPad Mini Retina. I'm using Xcode 6.3.2 and Unity 5.0.2.
     
  4. lacost

    lacost

    Joined:
    May 30, 2012
    Posts:
    1,604
    Sorry for slow reply @acidduck . Feel free to contact me via e-mail if you have something urgent, and you can alwasy contact the support team as well.


    That's right, after purchase you should use this method (but note that you need to use production verification server url when your app goes live).
    It will validate last purchase that was made with the app, and you will get validation result.
    Cheers!
     
  5. lacost

    lacost

    Joined:
    May 30, 2012
    Posts:
    1,604
    Hello.
    This is not very popular feature for the game development so the answer is no unfortunately.
    But you can always hire us if you need any specific functionality.

    Hey @badben this is known issue, its actually connected with the FB issue on IOS 8.3, have a look:
    http://stackoverflow.com/questions/29925810/slservicetypefacebook-setinitialtext-is-not-working

    Hey @loyalpenguin actually I am currently working on the very big Game Center API update (plugin version will be realized to 7) so I want to ask you wait a bit to the next week update, you will get completly new documentation and very rich turn-based and real-time multiplayer API

    Cheers!
     
  6. richardzzzarnold

    richardzzzarnold

    Joined:
    Aug 2, 2012
    Posts:
    79
    There seems to be some kind of error in IOS Native plugin.
    The iAd banner positioning screws up when orientation changes.
    I have implemented it in a game with a banner set at lower center .
    The plugin seems to not update Screen.width or Screen.height info so if you start the game in landscape and then rotate to portrait the banner will be in the middle of the screen ( it seems to think it is still in landscape mode)
    This is a major flaw.
    Also , if I have my game locked into landscape orientation but hold the device in portrait mode, the banner will not appear.
    So it seems to be a unusable at this stage IMO
     
  7. lacost

    lacost

    Joined:
    May 30, 2012
    Posts:
    1,604
    Hello, thanks for the report. I guess we already get similar one, via e-mail, so we are on it! The fix will be released this weekends.

    Cheers!
     
  8. cesarpo

    cesarpo

    Joined:
    Jun 8, 2013
    Posts:
    98
    Hi, I'm wondering if there is a way for the plugin to populate the products list of: IOSInAppPurchaseManager.instance.products, with some fake data so I can test it on the editor.
     
  9. lacost

    lacost

    Joined:
    May 30, 2012
    Posts:
    1,604
    Hello, I guess this is what you looking for. It will fire fake events (store initialized, product bought etc) in editor.
     
  10. lacost

    lacost

    Joined:
    May 30, 2012
    Posts:
    1,604
    Hey @richardzzzarnold thx again for the report, issues if fixed. The fix will be released with the 7.1 version.
    Cheers!
     
  11. Martin_Gonzalez

    Martin_Gonzalez

    Joined:
    Mar 25, 2012
    Posts:
    283
    Hi lacost.
    This plugin has support for IL2CPP? Should i have any specific version of Unity? Im working with 4.6.3
    Thanks!
     
  12. cesarpo

    cesarpo

    Joined:
    Jun 8, 2013
    Posts:
    98
    Yeah, I have that enabled, and all the events work properly, but the list in
    Code (csharp):
    1. IOSInAppPurchaseManager.instance.products
    is empty.
     
  13. redbull5988

    redbull5988

    Joined:
    Sep 28, 2013
    Posts:
    2
    #if (UNITY_IPHONE && !UNITY_EDITOR && PUSH_ENABLED) || SA_DEBUG_MODE

    privatebooltokenSent = false;

    voidFixedUpdate () {
    if (!tokenSent) {

    byte[] token = NotificationServices.deviceToken;
    //Debug.Log(NotificationServices.deviceToken);
    if(token != null) {

    IOSNotificationDeviceTokent = newIOSNotificationDeviceToken(token);
    IOSNotificationController.instance.OnDeviceTockeReceivedAction (t);
    tokenSent = true;


    Destroy (gameObject);
    }
    }
    }

    #endif

    Can't get deviceToken in Iphone5s. please help me!!!
     
  14. axxxj

    axxxj

    Joined:
    Nov 18, 2013
    Posts:
    3
    So I'm doing this:

    IOSStoreProductView _productView;

    IOSStoreProductView _productView = new IOSStoreProductView(_productID);

    _productView.Disnissed += ReturnFromAppStore;

    _productView.Load();

    But the method "ReturnFromAppStore" never gets called when I dismiss the view.
    Is there anything else I need to do to get it to work?

    That is the only part of iOSNative that i'm using... Maybe I need to set something else up somewhere else?
     
  15. yifan024

    yifan024

    Joined:
    Jun 5, 2013
    Posts:
    19
    Is Geofencing supported? Like update location in background even when app is not running?
     
  16. zhaoqingqign

    zhaoqingqign

    Joined:
    Sep 28, 2013
    Posts:
    1
    Is Not Support IOS 64? I Switch Arm64
    upload_2015-6-18_15-25-33.png
     
  17. Tracy-Ma

    Tracy-Ma

    Joined:
    Nov 22, 2012
    Posts:
    21
    -(void) dismissGameCenterView: (GKGameCenterViewController *)vc {

    [vc dismissViewControllerAnimated:YEScompletion:nil];
    // comment out this line solve the issure
    // [vc.view.superview removeFromSuperview];

    [vc release];

    }
     
  18. Lance Cheng

    Lance Cheng

    Joined:
    Sep 5, 2014
    Posts:
    1
    I've studied In-app purchase process from Apple Developer. Compare with TransactionServer.m, the class calls finishTransaction itself , however, if I want to call finishTransaction after purchase verification process on self-host game server , to avoid network failure or app crash , then next time case SKPaymentTransactionStatePurchased will triggered again.

    Question is : in order to call finishTransaction , paramter SKPaymentTrasaction* trnsacton is must have, how to pass this parameter through Unity ? a roughly possible solution is implement a method by youself and just pass OrderID as string to
    TransactionServer.m , search the OrderID in updateTransactions then call finishTrasaction internal.

    in the scenario, to ensure purchased event triggered again while next time app startup, please let user decide when to call finishTransaction .
     
  19. Tinytouchtales

    Tinytouchtales

    Joined:
    Dec 30, 2013
    Posts:
    23
    Hey,

    i've update to Unity 5.1.1f1 today and it seems that every time i build for iOS the Xcode project is missing its Binary Library links like GameKit.framework etc. I do have to add them manually back in. This seems to be a new issue, is there an easy way to fix that on my side?

    cheers!
     
  20. biscito

    biscito

    Joined:
    Apr 3, 2013
    Posts:
    86
    strange xcode error :

    error: unable to restore file position to 0x00000ca8 for section __DWARF.__debug_inlined (errno = 9)
     
  21. lacost

    lacost

    Joined:
    May 30, 2012
    Posts:
    1,604
    Nope, you should do any specific action, just switch to IL2CPP and build as always.

    Hello @cesarpo , thx for the report, I just checked and turns out there was a bug with fake events. Just fixed it.


    What Unity and IOS version you currently using?


    It's not widely used feature in game development, that's why it not implemented to the plugin so far.

    Arm64 is supported, please have a look:
    https://unionassets.com/iosnative/ios-64-bit-support-462


    Well point is finishTransaction needs a transaction object. So if application will be relaunched I will not able to call it, since I can only store transaction object in-app cache while app is running.
    Basically from my perspective scenario should look like this.
    The user makes the transaction, event if it's a fake transaction, the plugin will finish it, since if plugin will not finish the transaction it IOS will always send event that transaction si not finished.
    After transaction is finished you will get all transaction event inside the Unity. you can send receipt to your server to check if transaction is valid. And you will UNLOCK content in your game only after you got confirmation from YOUR server.
    Cheers!


    The IOS Native is adding the GameKit.framework automatically, We had issues with Unity 5, since post-processing is run's a little bit different with Unity 5. Thx for the report I will check this. So fat as quick fix you can just choose GameKit.framework as dependence for any *.mm file. You will see the menu when you click on it. It's just a quick fix for not adding it every time manually into the Xcode project


    Well, it a bit lack of information here for me. I can suggest to try project clean up, or recreate the project. You can also send me your project so I could look on it on my machine. Keep me informed.


    Cheers!
     
  22. renman3000

    renman3000

    Joined:
    Nov 7, 2011
    Posts:
    6,480
    Hi there,
    I purchased your plug in and am eager to get it running.

    I have run into an issue with the Store Set Up.
    I have created my own Class, STORE_MNG. In it, on Awake() I am attempting to subscribe to the two events you require and initialise the store.
    Code (csharp):
    1.  
    2. using UnityEngine;
    3. using System.Collections;
    4. using UnionAssets.FLE;
    5. using System.Collections;
    6. using System.Collections.Generic;
    7.  
    8. public class STORE_MNG : MonoBehaviour {
    9.  
    10. void Awake(){
    11. IOSInAppPurchaseManager.instance.OnStoreKitInitComplete += OnStoreKitInitComplete;
    12. IOSInAppPurchaseManager.instance.OnTransactionComplete += OnTransactionComplete;
    13. InAppPurchaseManager.instance.loadStore();
    14. }
    15. public void OnStoreKitInitComplete(){
    16. }
    17.  
    18. public void OnTransactionComplete(){
    19. }
    20. }
    21.  

    ... But I am greeted with errors.
    1.
    Assets/Scripts/STORE_MNG.cs(10,50): error CS0123: A method or delegate `STORE_MNG.OnStoreKitInitComplete()' parameters do not match delegate `System.Action<ISN_Result>(ISN_Result)' parameters


    2.
    Assets/Scripts/STORE_MNG.cs(10,50): error CS0428: Cannot convert method group `OnStoreKitInitComplete' to non-delegate type `System.Action<ISN_Result>'. Consider using parentheses to invoke the method

    3.
    Assets/Scripts/STORE_MNG.cs(10,50): error CS0019: Operator `+=' cannot be applied to operands of type `System.Action<ISN_Result>' and `method group'

    4.
    Assets/Scripts/STORE_MNG.cs(11,50): error CS0123: A method or delegate `STORE_MNG.OnTransactionComplete()' parameters do not match delegate `System.Action<IOSStoreKitResponse>(IOSStoreKitResponse)' parameters

    5.
    Assets/Scripts/STORE_MNG.cs(11,50): error CS0428: Cannot convert method group `OnTransactionComplete' to non-delegate type `System.Action<IOSStoreKitResponse>'. Consider using parentheses to invoke the method

    6.
    Assets/Scripts/STORE_MNG.cs(11,50): error CS0019: Operator `+=' cannot be applied to operands of type `System.Action<IOSStoreKitResponse>' and `method group'

    7.
    Assets/Scripts/STORE_MNG.cs(12,17): error CS0103: The name `InAppPurchaseManager' does not exist in the current context
     
  23. United-Unity

    United-Unity

    Joined:
    Mar 25, 2015
    Posts:
    20
    Hello!

    In using game center feature in iOS native, a following bug was found. It causes 3rd party authentication failed.
    Code (CSharp):
    1. Plugins/IOS/ISN_GameCenterManager.mm
    2. -(void) getSignature {
    3. ...
    4.         NSMutableString *sig = [[NSMutableString alloc] init];
    5.         const char *db = (const char *) [signature bytes];
    6.         for (int i = 0; i < [salt length]; i++) { // BUG: use signature instead of salt
    7.             if(i != 0) {
    8.                 [sig appendFormat:@","];
    9.             }
    10.            
    11.             [sig appendFormat:@"%i", (unsigned char)db[i]];
    12.         }
    13.        
    14.        
    15.         NSMutableString *slt = [[NSMutableString alloc] init];
    16.         const char *db2 = (const char *) [salt bytes];
    17.         for (int i = 0; i < [signature length]; i++) { // BUG: use salt instead of signature
    18.             if(i != 0) {
    19.                 [slt appendFormat:@","];
    20.             }
    21.            
    22.             [slt appendFormat:@"%i", (unsigned char)db2[i]];
    23.         }
    24. ...
    25. }
    If this hotfix is applied. everything will be fine. Please update this fix to next update.
    Thanks!
     
  24. United-Unity

    United-Unity

    Joined:
    Mar 25, 2015
    Posts:
    20
    Hello!

    From Unity 4.6.6p2, IOSDeply/post_process.py had a runtime error related with mod_pbxproj module as following.
    Code (CSharp):
    1. Traceback (most recent call last):
    2.   File "Assets/Middleware/IOSDeploy/Scripts/Editor/post_process.py", line 14, in <module>
    3.     project = XcodeProject.Load(path +'/Unity-iPhone.xcodeproj/project.pbxproj')
    4.   File "/../Assets/Middleware/IOSDeploy/Scripts/Editor/mod_pbxproj.py", line 1288, in Load
    5.     tree = json.loads(jsonStr)
    6.   File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/json/__init__.py", line 338, in loads
    7.     return _default_decoder.decode(s)
    8.   File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/json/decoder.py", line 365, in decode
    9.     obj, end = self.raw_decode(s, idx=_w(s, 0).end())
    10.   File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/json/decoder.py", line 381, in raw_decode
    11.     obj, end = self.scan_once(s, idx)
    12. ValueError: Invalid \escape: line 1 column 69703 (char 69702)
    13. ISD Executing post process done.
    I didn't delve into this problem enough but problem is solved after update mod_pbxproj module with latest one.
    (you can get this at https://github.com/kronenthaler/mod-pbxproj)

    Please consider updating this new module to next update.
    Thanks!
     
  25. Exbow

    Exbow

    Joined:
    Sep 3, 2013
    Posts:
    1
    @lacost i am not sure if this is a bug or just some functionality due to my setup. I am running on a Virtual Machine Mac os X and a simulator.On the Multiplayer Demo scene when i click the Find Match button the unity app has no input if i find any match or i click cancel.
     
  26. WhosTheBoss

    WhosTheBoss

    Joined:
    Jan 8, 2013
    Posts:
    47
    Hello Lacost

    I have Unity 5.1.1, XCode 6.3.2

    X Code gives me build error:

    Undefined symbols for architecture armv7:
    "_OBJC_CLASS_$_MFMailComposeViewController", referenced from:
    objc-class-ref in SocialGate.o
    "_kUTTypeMovie", referenced from:
    -[ISNCamera GetVideo] in ISNCamera.o
    -[ISNCamera imagePickerController:didFinishPickingMediaWithInfo:] in ISNCamera.o
    "_SLServiceTypeFacebook", referenced from:
    -[SocialGate fbPost:] in SocialGate.o
    -[SocialGate fbPostWithMedia:media:] in SocialGate.o
    "_OBJC_CLASS_$_SLComposeViewController", referenced from:
    objc-class-ref in SocialGate.o
    "_SLServiceTypeTwitter", referenced from:
    -[SocialGate twitterPostWithMedia:media:] in SocialGate.o
    -[SocialGate twitterPost:] in SocialGate.o
    "_OBJC_CLASS_$_SLComposeServiceViewController", referenced from:
    objc-class-ref in SocialGate.o
    ld: symbol(s) not found for architecture armv7
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
     
  27. Mitralone

    Mitralone

    Joined:
    Jun 12, 2013
    Posts:
    10
    Hello,

    I am getting this in xCode:

    Undefined symbols for architecture arm64:

    "_kUTTypeMovie", referenced from:

    -[ISNCamera GetVideo] in ISNCamera.o

    -[ISNCamera imagePickerController:didFinishPickingMediaWithInfo:] in ISNCamera.o

    ld: symbol(s) not found for architecture arm64

    Can you please check?

    Thanks

    Mitralone
     
  28. lacost

    lacost

    Joined:
    May 30, 2012
    Posts:
    1,604
    Hey @renman3000 please looks at the example scripts, or use Mono autofill, sine you have declared wrong methods, it should look liek this:

    Code (CSharp):
    1. using UnityEngine;
    2. using System.Collections;
    3. using UnionAssets.FLE;
    4. using System.Collections;
    5. using System.Collections.Generic;
    6. public class STORE_MNG : MonoBehaviour {
    7. void Awake(){
    8. IOSInAppPurchaseManager.instance.OnStoreKitInitComplete += OnStoreKitInitComplete;
    9. IOSInAppPurchaseManager.instance.OnTransactionComplete += OnTransactionComplete;
    10. InAppPurchaseManager.instance.loadStore();
    11. }
    12.     void OnStoreKitInitComplete (ISN_Result result) {
    13.  
    14.     }
    15.  
    16.     void OnTransactionComplete (IOSStoreKitResult result) {
    17.    
    18.     }
    19.  
    20. }
    Hey @United Unity thanks for heads up, fix will be shipped with the new plugin version. About post_process.py, I will test it as well thanks!

    Hey @Exbow , hello, I am not sure, since I never testing any native API on the simulator, and I do not recommend to do this at all. but if you will give me the device (simulator) output I will be able to tell what is going wrong.


    Hey @WhosTheBoss , @Mitralone looks like you guys missing frameworks in the Xcode project setup.
    Plugin is trying to add frameworks automatically, but sometimes post process can fail due to any reason, for example due to specific symbols in the project path, your machine environment issues etc.
    In this case you should add required framework manually, the framework list can be found here:
    https://unionassets.com/iosnative/plugin-set-up-2#setup-in-xcode

    Cheers!
     
    renman3000 likes this.
  29. arbt

    arbt

    Joined:
    May 22, 2013
    Posts:
    7
    Hi, I'm having same issue as @WhosTheBoss. Lots of build errors when I try to build using Unity 5.1.1 and Xcode 6.4 even after manually adding the frameworks in the setup guide.
     
  30. arbt

    arbt

    Joined:
    May 22, 2013
    Posts:
    7
    Turns out that the other missing frameworks were required by another plugin so all good.
     
  31. Crz

    Crz

    Joined:
    Jul 30, 2013
    Posts:
    5
    @WhosTheBoss: add GameKit and MobileCoreServices framework to Xcode
    @Mitralone: just add MessageUI framework to Xcode

    Another way for both of you: I've found the way to add all these frameworks directly to Unity.
    1. In Unity, click on file Plugins/iOS/CGHelper.mm, you will see in the Inspector the list of framework that will be added to Xcode project.
    2. Find your missing framework(s) and check it. Following is my case



    3. Enjoy!
     
  32. super-cypher

    super-cypher

    Joined:
    May 10, 2014
    Posts:
    113
    Me too! im getting loads of errors in xcode. i have tried reimporting everything but no luck, i just get a load of different errors...

    will we be getting a fix anytime soon?

    //
    // TransactionServer.m
    //
    // Created by Osipov Stanislav on 1/16/13.
    //

    #import "TransactionServer.h"


    UnitySendMessage("IOSInAppPurchaseManager", "onVerificationResult", [ISNDataConvertor NSStringToChar:str]);


    UnitySendMessage("IOSInAppPurchaseManager", "onProductStateDeferred", [ISNDataConvertor NSStringToChar:transaction.payment.productIdentifier]);
    }
     
    Last edited: Jul 5, 2015
  33. gregory_igromatic

    gregory_igromatic

    Joined:
    Feb 1, 2014
    Posts:
    25
    we are checking products via
    if (IOSInAppPurchaseManager.instance.products.Count <=0)
    {
    //do not show store interface
    }
    while testing everything is fine, products are available

    when sending to the apple app store they cannot see the products at all (while in review status)
    what can be as a solution?
     
  34. lacost

    lacost

    Joined:
    May 30, 2012
    Posts:
    1,604
    I was have to change post processing a bit for unity 5.1, since for some reason Unity has change the way it works file files steam in Unity 5.1

    If you currently have any issues with compilation under Unity 5, please send me logs or screenshot so I will able to provide the fix for you. But generally for current version you only need to add frameworks manually and you good.

    @Crz thx for your replay, the automatic post-process will work with Unity 5.1 in the next IOS Native 7.1 release.

    Hey @super-cypher there shouldn't be any compilation errors, please send me the log or screenshot via e-mail so I will be able to see what is going work for you and provide the fix.

    Actually if something works in the testing mode it should work the same in the release mode. So I could only assume that something is wrong with your product settings. Are you sure your products is available with the app version you have sent to review?

    Cheers!
     
    Crz likes this.
  35. Crz

    Crz

    Joined:
    Jul 30, 2013
    Posts:
    5
    @lacost I am using iOSNative 6.1 in unity 5.1.1f1 and got a trouble. When push notification was checked and after that I was trying to build my game but error occurs in IOSNotificationController.cs.

    I've tried to fix that by image below. The build succeed. But the device can't get any notification from APNS.

    Screen Shot 2015-07-08 at 10.24.24 PM.png

    This is the result that I've pushed via APNS
    First param is device token and next is message.
    Screen Shot 2015-07-08 at 10.31.16 PM.png

    My iOS certificate is correct because I am using it for building game on unity cloud.

    and the last is simplepush.php file that I was using to push.
     

    Attached Files:

    Last edited: Jul 8, 2015
  36. chaneya

    chaneya

    Joined:
    Jan 12, 2010
    Posts:
    402
    I just updated to Unity 4.6.7 and deployed to Xcode 6.3.1 and got 7 Apple Mach-O Linker errors.

    (Edit: Just read the posts above and adding the Frameworks manually works. At first I skipped over those because they were related to Unity 5 but it obviously applied to both current versions)

    Also I posted a possible bug to the Ultimate Mobile forum several weeks ago and there has been no response so I'll repost it here:

    Today I started testing the Social sharing features using
    UM_ShareUtility.ShareMedia("Title", "Some text to share", tex);

    When I choose Twitter to share my post, I get a string and an image in the resulting post.
    When I choose Facebook, I only get an image with no string. I am currently unable to post text to Facebook using the UM_ShareUtiliy.ShareMedia option. It only passes the image to the resulting post.

    Is this a bug or is there a reason for this?

    Thanks
    Allan
     
    Last edited: Jul 8, 2015
  37. Crz

    Crz

    Joined:
    Jul 30, 2013
    Posts:
    5
    take a look at previous posts before asking anything @chaneya
     
    Last edited: Jul 8, 2015
  38. chaneya

    chaneya

    Joined:
    Jan 12, 2010
    Posts:
    402
    Crz,

    Thanks.

    Just read the posts above and adding the Frameworks manually works. At first I skipped over those because they were related to Unity 5 but it obviously applied to both current versions.

    Allan
     
  39. Blundig

    Blundig

    Joined:
    Jan 7, 2014
    Posts:
    18
    There is a bug in ISN_GameCenterManager.mm that causes the following error to be logged at runtime:
    IndexOutOfRangeException: Array index is out of range.
    at GameCenterManager.OnLeaderboardMaxRangeUpdate (System.String array) [0x00000] in <filename unknown>


    The problem occurs in these 2 selectors:
    retriveScores:scope:collection
    retrieveScoreForLocalPlayerWithCategory:scope:collection.


    The code at issue is:
    Code (CSharp):
    1. NSMutableString * rangeData = [[NSMutableString alloc] init];
    2. [data appendString:[NSString stringWithFormat:@"%@", leaderboardRequest.identifier]];
    3. [data appendString:@","];
    4. [data appendString:[NSString stringWithFormat:@"%d", leaderboardRequest.maxRange]];
    There are 2 problems:
    1. The appendString lines should append to rangeData, not data.
    2. The separator character should be "|", not ",". That is the format expected by GameCenterManager.OnLeaderboardMaxRangeUpdate.

    So, the fix is as follows:
    Code (CSharp):
    1. NSMutableString * rangeData = [[NSMutableStringalloc] init];
    2. [rangeData appendString:[NSString stringWithFormat:@"%@", board.identifier]];
    3. [rangeData appendString:@"|"];
    4. [rangeData appendString:[NSString stringWithFormat:@"%d", board.maxRange]];
    Hope that helps.
     
    Crz likes this.
  40. Blundig

    Blundig

    Joined:
    Jan 7, 2014
    Posts:
    18
    I’ve been using the plugin to implement Game Center leaderboards (including loading Game Center friends lists). All was good with previous versions, but I’ve hit a major limitation after updating to ISN_7.0.

    My game targets iOS 6 as a minimum. This worked before, but ISN_7.0 now requires a minimum of iOS 8 for the same feature set.

    It appears that iOS 7 is the new minimum for Game Center with the plugin, because ISN_GameCenterListner uses [GKLocalPlayer registerListener] during authentication.

    If you need to retrieve friends lists, the minimum bumps up to iOS 8 because ISN_GameCenterListner uses [GKLocalPlayer loadFriendPlayersWithCompletionHandler].

    A few things:
    1. Would you consider updating the code to make it compatible with older iOS versions again? I can’t increase the minimums for my products, so I will have to be locked into older releases of your plugin or find an alternative.
    2. This is a very dangerous (and I believe undocumented) change to your product, especially for people updating existing apps. Unless you are rigorous about testing on devices with older iOS versions, it would be easy to assume everything still works like before. However, users with older iOS versions will experience crashes. I suggest that you:
      • Update your release notes to feature this change prominently. Some may not want to update because of this.
      • Update the Asset Store description to reflect this. It still indicates IOS6 compatibility.
      • Update the User Guide to indicate which Game Center features requires what minimum iOS.
    Thanks
     
  41. uniwersytetgier

    uniwersytetgier

    Joined:
    Oct 29, 2014
    Posts:
    26
    Hello,

    We implemented iOS Native and Mobile Social Native in fresh project. When you try to build on iOS, we had error.

    ERROR: ARC Semantic Issue No known class method for selector 'serializeErrorToNSString:'
    CODE: NSString* errorData = [ISNDataConvertor serializeErrorToNSString:error];

    ERROR: ARC Semantic Issue No known class method for selector 'serializeError:'
    CODE: UnitySendMessage("GameCenterManager", "OnFriendListLoadFailEvent", [ISNDataConvertor serializeError:error]);

    ERROR: Semantic Issue No matching function call to 'UnitySendMessage'
    CODE: UnitySendMessage("GameCenterManager", "OnFriendListLoadFailEvent", [ISNDataConvertor serializeError:error]);

    ERROR: ARC Semantic Issue No known class method for selector 'serializeErrorWithData:code:'
    CODE: UnitySendMessage("GameCenterManager", "OnFriendListLoadFailEvent", [ISNDataConvertor serializeErrorWithData:mad:"User has to be authenticated to perform friends load operation" code:0]);

    ERROR: Semantic Issue No matching function call to 'UnitySendMessage'
    CODE: UnitySendMessage("GameCenterManager", "OnFriendListLoadFailEvent", [ISNDataConvertor serializeErrorWithData:mad:"User has to be authenticated to perform friends load operation" code:0]);

    How to fix it?
     

    Attached Files:

    Last edited: Jul 12, 2015
  42. samiress

    samiress

    Joined:
    May 12, 2013
    Posts:
    6
    Product looks great! Before purchase, could you please help me understand something.

    I want to use it ONLY for the gallery access. Do I need to setup Game Center and ads etc? Can I build without those steps?
     
  43. gselfish

    gselfish

    Joined:
    Mar 13, 2015
    Posts:
    6
    Well, that's unfortunate really. I was going to buy this asset, mainly for turn-based multiplayer and leaderboards, but I surely don't want to drop ios 6 support, let alone ios 7.
    Thank you for the heads up Blundig, I guess I'll have to look elsewhere.
    In any case, I wish there was an official response on this topic from the asset creators. I don't know, maybe some workaround would be possible by mixing different versions of the asset?
     
  44. Blundig

    Blundig

    Joined:
    Jan 7, 2014
    Posts:
    18
    There is a bug in [IOSNativeUtility ShowSpinner], as follows:

    1. Create an app that is locked to a specific orientation (Portrait for this example).
    2. Run the app on a device with iOS 7 or earlier.
    3. Hold the device in landscape orientation.
    4. Trigger [IOSNativeUtility ShowSpinner].

    Notice that the spinner won’t be centered to the screen, and the spinner’s rectangle frame won’t cover the entire screen.

    The problem is that the code is checking the Device orientation instead of the UI orientation to determine how to draw the spinner. To fix, replace:

    Code (csharp):
    1. if([[UIDevice currentDevice] orientation] == UIDeviceOrientationPortrait || [[UIDevice currentDevice] orientation] == UIDeviceOrientationPortraitUpsideDown) {}
    with:

    Code (csharp):
    1. if( UIInterfaceOrientationIsPortrait([[UIApplication sharedApplication] statusBarOrientation])) {}
    Edit: It looks like this class has had its name refactored to ISN_NativeUtility.mm in v7.1 of the plugin, but the above still applies.
     
    Last edited: Jul 13, 2015
  45. kyuskoj

    kyuskoj

    Joined:
    Aug 28, 2013
    Posts:
    30
    There is a problem when i press home button while any native dialog is opened.
    when i came back to application, I can't re-open any dialog with this message on Xcode

    Warning: Attempt to present <UIAlertController: 0x1885a820> on <UnityDefaultViewController: 0x145cdbd0> which is already presenting

    I use latest version of Xcode and iOS.
    Is there anyone who has this issue?
     
  46. RSH1

    RSH1

    Joined:
    Jul 9, 2012
    Posts:
    181
    I am getting the following error in XCode when calling IOSInAppPurchaseManager.instance.loadStore(); after having made a test purchase

    Code (CSharp):
    1. 2015-07-14 17:31:44.311 candy[39873:2722927] init
    2. 2015-07-14 17:31:44.313 candy[39873:2722927] loadStore....
    3. 2015-07-14 17:31:44.538 candy[39873:2722927] ISN: completeTransaction...
    4. 2015-07-14 17:31:44.542 candy[39873:2722927] Reachability Flag Status: -R ------- networkStatusForFlags
    5. 2015-07-14 17:31:44.543 candy[39873:2722927] ISN: apple.com reachable sending tracnsactio finish
    6. 2015-07-14 17:31:44.543 candy[39873:2722927] ISN: provideContent for: candy_removeads
    7. 2015-07-14 17:31:44.574 candy[39873:2722927] Uncaught exception: NSInvalidArgumentException: -[__NSCFString appendString:]: nil argument
    8. (
    9.     0   CoreFoundation                      0x27368c37 <redacted> + 150
    10.     1   libobjc.A.dylib                     0x34b13c8b objc_exception_throw + 38
    11.     2   CoreFoundation                      0x27368b65 <redacted> + 0
    12.     3   CoreFoundation                      0x2732471b <redacted> + 166
    13.     4   candy                               0x00110468 -[TransactionServer provideContent:isRestored:] + 1228
    14.     5   candy                               0x00110830 -[TransactionServer completeTransaction:] + 320
    15.     6   candy                               0x0010f1b0 -[TransactionServer paymentQueue:updatedTransactions:] + 428
    16.     7   StoreKit                            0x2a7a8079 <redacted> + 84
    17.     8   CoreFoundation                      0x2727ac7d CFArrayApplyFunction + 36
    18.     9   StoreKit                            0x2a7a8015 <redacted> + 128
    19.     10  StoreKit                            0x2a7a8927 <redacted> + 1074
    20.     11  StoreKit                            0x2a7a900d <redacted> + 128
    21.     12  StoreKit                            0x2a7a7bad <redacted> + 60
    22.     13  libdispatch.dylib                   0x04bb09db _dispatch_call_block_and_release + 10
    23.     14  libdispatch.dylib                   0x04bb09c7 _dispatch_client_callout + 22
    24.     15  libdispatch.dylib                   0x04bb43ed _dispatch_main_queue_callback_4CF + 808
    25.     16  CoreFoundation                      0x2732e9d1 <redacted> + 8
    26.     17  CoreFoundation                      0x2732d0d1 <redacted> + 1512
    27.     18  CoreFoundation                      0x2727b211 CFRunLoopRunSpecific + 476
    28.     19  CoreFoundation                      0x2727b023 CFRunLoopRunInMode + 106
    29.     20  GraphicsServices                    0x2e6740a9 GSEventRunModal + 136
    30.     21  UIKit                               0x2a8871d1 UIApplicationMain + 1440
    31.     22  candy                               0x000b1a80 main + 308
    32.     23  candy                               0x000b1948 start + 40
    33. )
    34. 2015-07-14 17:31:44.578 candy[39873:2722927] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[__NSCFString appendString:]: nil argument'
    35. *** First throw call stack:
    36. (0x27368c1f 0x34b13c8b 0x27368b65 0x2732471b 0x110468 0x110830 0x10f1b0 0x2a7a8079 0x2727ac7d 0x2a7a8015 0x2a7a8927 0x2a7a900d 0x2a7a7bad 0x4bb09db 0x4bb09c7 0x4bb43ed 0x2732e9d1 0x2732d0d1 0x2727b211 0x2727b023 0x2e6740a9 0x2a8871d1 0xb1a80 0xb1948)
    37. libc++abi.dylib: terminating with uncaught exception of type NSException
    I never encountered this error before using previous versions of the plugin with other apps. What's happening?
     
  47. SpaceKitty

    SpaceKitty

    Joined:
    Feb 3, 2015
    Posts:
    3
    We're experiencing crashes on IOS 7.1.2, Unity 5.1 when native windows show up - be that purchase prompt or anything else:

    Uncaught exception: NSInvalidArgumentException: Application tried to present a nil modal view controller on target <UnityDefaultViewController: 0x1276e3a70>.

    (

    0 CoreFoundation 0x00000001835eb11c <redacted> + 160

    1 libobjc.A.dylib 0x000000018fea41fc objc_exception_throw + 60

    2 UIKit 0x00000001866a9bdc <redacted> + 5528

    3 slotspanther 0x0000000100fee780 +[ISN_NativePopUpsManager showRateUsPopUp:message:b1:b2:b3:] + 572

    4 slotspanther 0x0000000100fef574 _ISN_ShowRateUsPopUp + 384

    5 slotspanther 0x000000010019df9c IOSNativePopUpManager__ISN_ShowRateUsPopUp_m1616 + 240

    6 slotspanther 0x000000010019dc48 IOSNativePopUpManager_showRateUsPopUp_m1621 + 116

    7 slotspanther 0x000000010019dbc8 IOSRateUsPopUp_init_m1611 + 116

    8 slotspanther 0x000000010019db3c IOSRateUsPopUp_Create_m1610 + 488

    9 slotspanther 0x0000000100583ab8 IOSSlot_RateUsPopup_m7321 + 2232
     
  48. jan1111

    jan1111

    Joined:
    Dec 31, 2014
    Posts:
    2
    Hi! I recently updated IOSNative to 7.1 to my Unity project and now when I build to xcode it throws me those llinker duplicate symbols errors. Please help! Thanks!!

    This is the error:

    duplicate symbol __ISN_ShowRateUsPopUp in:

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/IOSNativePopUpsManager.o

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/ISN_NativePopUpsManager.o

    duplicate symbol __ISN_ShowDialog in:

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/IOSNativePopUpsManager.o

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/ISN_NativePopUpsManager.o

    duplicate symbol __ISN_ShowMessage in:

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/IOSNativePopUpsManager.o

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/ISN_NativePopUpsManager.o

    duplicate symbol __ISN_DismissCurrentAlert in:

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/IOSNativePopUpsManager.o

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/ISN_NativePopUpsManager.o

    duplicate symbol _templateReviewURL in:

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/IOSNativeUtility.o

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/ISN_NativeUtility.o

    duplicate symbol _datePicker in:

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/IOSNativeUtility.o

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/ISN_NativeUtility.o

    duplicate symbol __ISN_ShowDP in:

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/IOSNativeUtility.o

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/ISN_NativeUtility.o

    duplicate symbol __ISN_RedirectToAppStoreRatingPage in:

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/IOSNativeUtility.o

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/ISN_NativeUtility.o

    duplicate symbol __ISN_ShowPreloader in:

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/IOSNativeUtility.o

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/ISN_NativeUtility.o

    duplicate symbol __ISN_HidePreloader in:

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/IOSNativeUtility.o

    /Users/Jan/Library/Developer/Xcode/DerivedData/Unity-iPhone-fmhfxciijwhcbtbvijcnabvdxjwp/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/ISN_NativeUtility.o

    ld: 17 duplicate symbols for architecture armv7

    clang: error: linker command failed with exit code 1 (use -v to see invocation)
     
  49. jan1111

    jan1111

    Joined:
    Dec 31, 2014
    Posts:
    2
    Oh.. By the way.. Forgot to mention.. I'm using Unity 4.6.7f1, xcode 6.4 and building target platforms version 7.1.
    I know that this error means that there's 2 implementations of those functions.. But I don't know how should I fix...
    Thanks!
     
  50. RSH1

    RSH1

    Joined:
    Jul 9, 2012
    Posts:
    181
    The exception when purhasing an IAP is on this line:

    Code (CSharp):
    1. [data appendString:transaction.payment.applicationUsername];
    on Transactionserver.m

    The exception is also thrown from clicking 'Init' on the 'BillingExample' scene.
     
    Last edited: Jul 16, 2015
unityunity