MissingMethodException: Method not found: ........

Options
Hi,

I have this error, I don't know why. Someday can help me please ? Thanks a lot !!
11-03 23:32:58.736: I/Unity(30750): MissingMethodException: Method not found: 'Default constructor not found...ctor() of ExitGames.Client.Photon.PingMono'.
11-03 23:32:58.736: I/Unity(30750): at System.Activator.CreateInstance (System.Type type, Boolean nonPublic) [0x00000] in <filename unknown>:0
11-03 23:32:58.736: I/Unity(30750): at System.Activator.CreateInstance (System.Type type) [0x00000] in <filename unknown>:0
11-03 23:32:58.736: I/Unity(30750): at PhotonPingManager+<PingSocket>c__Iterator2D.MoveNext () [0x00000] in <filename unknown>:0

Best regards,

AB

Comments

  • Tobias
    Options
    Is this post related to this?
    http://hutonggames.com/playmakerforum/i ... 1#msg41571

    I mailed Jean but can post my reply here, too. I don't know if you know enough coding to make it work for you.

    In PUN, in PingCloudRegions.cs, find PingSocket(Region region). In line 125 or so, PingNativeDynamic gets a special treatment.
    This can be done for PingMono, too.
    Add:
    [code2=csharp]else if (PhotonHandler.PingImplementation == typeof(PingMono))
    {
    Debug.Log("Using constructor for new PingMono()"); // it seems on iOS, the Activator can't find the default Constructor
    ping = new PingMono();
    }[/code2]


    It could also be related to the build player settings. It should be DotNet 2.0 Subset and in best case the build should "Strip Bytecode".
  • Thank you.

    I'm a coder, so no problem with that.


    I do that. I will let you know if the issue is not resolved, but I'm sure it is.


    Thank you !!

    Best regards,

    AB
  • jeanfabre
    Options
    Hi,

    Good. Thanks Tobias for stepping in :)

    Bye,

    Jean
  • smurf
    Options
    Hi,

    My client had the same issue. Although the patch works great I've done some testing with Unity5.1.2f1 and XCode 6.4.

    If I set the player settings to .net 2.0 and strip byte code disabled, it works fine without the patch.

    It also works great with .Net subset. When I do enable strip byte code the exception happens.

    Do you get the same thing?

    Kind regards,
    Andrei