Forum rules - please read before posting.

Adventure Creator 1.32 iOS problems

edited May 2014 in Engine development
I have recently created a new project to test out Adventure Creator 1.32 and it works fine on the desktop platform but on iOS I get the following two errors:

NullReferenceException: Object reference not set to an instance of an object
GlobalVariables.UpdateSelf () (at Assets/AdventureCreator/Scripts/Variables/GlobalVariables.cs:44)
GlobalVariables.Awake () (at Assets/AdventureCreator/Scripts/Variables/GlobalVariables.cs:26)
UnityEngine.Object:Instantiate(Object)
KickStarter:Awake() (at Assets/AdventureCreator/Scripts/Game engine/KickStarter.cs:129)


and

NullReferenceException: Object reference not set to an instance of an object
AC.MenuSlider.RecalculateSize () (at Assets/AdventureCreator/Scripts/Menu/Menu classes/MenuSlider.cs:194)
AC.Menu.PositionElements () (at Assets/AdventureCreator/Scripts/Menu/Menu classes/Menu.cs:610)
AC.Menu.Recalculate () (at Assets/AdventureCreator/Scripts/Menu/Menu classes/Menu.cs:529)
AC.Menu.Copy (AC.Menu _menu) (at Assets/AdventureCreator/Scripts/Menu/Menu classes/Menu.cs:244)
PlayerMenus.Awake () (at Assets/AdventureCreator/Scripts/Controls/PlayerMenus.cs:69)
UnityEngine.Object:Instantiate(Object)


Never had these errors before.

Hope you can help.

Comments

  • I will try to get this fixed very shortly for 1.33, but in the meantime: does clicking "Clear options cache" in the Settings Manager help?
  • Not that I can get to the settings manager anymore. Working in iOS platform mode just throws continuous XML related errors:

    XmlException: Text node cannot appear in this state.  Line 1, position 1.
    Mono.Xml2.XmlTextReader.ReadText (Boolean notWhitespace)
    Mono.Xml2.XmlTextReader.ReadContent ()
    Mono.Xml2.XmlTextReader.Read ()
    System.Xml.XmlTextReader.Read ()
    System.Xml.XmlReader.MoveToContent ()
    System.Xml.Serialization.XmlSerializationReaderInterpreter.ReadRoot ()
    System.Xml.Serialization.XmlSerializer.Deserialize (System.Xml.Serialization.XmlSerializationReader reader)

    You can go to Window > Layouts > Default to get rid of the Game editor window which gives you back access to the Game editor but the Settings tab sends the system into overdrive again.

    Hopefully the fix is straightforward.


  • I can't recreate this on my end - iOS mode still works for me.  Rather than me think I've fixed it and update prematurely, could you let me know if this solves the issue?  Open up SettingsManager.cs and find line 295.

    Change:
    #if (UNITY_IPHONE || UNITY_WP8)
    to:
    #if UNITY_WP8

    There should be two more instances on lines 304 and 319.  Do the same for those, and I'm hoping that will fix it.
  • Yes! that fixed the XML errors! Just those other errors still popping up:

    NullReferenceException: Object reference not set to an instance of an object
    GlobalVariables.UpdateSelf () (at Assets/AdventureCreator/Scripts/Variables/GlobalVariables.cs:44)
    GlobalVariables.Awake () (at Assets/AdventureCreator/Scripts/Variables/GlobalVariables.cs:26)
    UnityEngine.Object:Instantiate(Object)
    KickStarter:Awake() (at Assets/AdventureCreator/Scripts/Game engine/KickStarter.cs:129)

    NullReferenceException: Object reference not set to an instance of an object
    AC.MenuSlider.RecalculateSize () (at Assets/AdventureCreator/Scripts/Menu/Menu classes/MenuSlider.cs:198)
    AC.Menu.PositionElements () (at Assets/AdventureCreator/Scripts/Menu/Menu classes/Menu.cs:610)
    AC.Menu.Recalculate () (at Assets/AdventureCreator/Scripts/Menu/Menu classes/Menu.cs:529)
    AC.Menu.Copy (AC.Menu _menu) (at Assets/AdventureCreator/Scripts/Menu/Menu classes/Menu.cs:244)
    PlayerMenus.Awake () (at Assets/AdventureCreator/Scripts/Controls/PlayerMenus.cs:69)
    UnityEngine.Object:Instantiate(Object)
    KickStarter:Awake() (at Assets/AdventureCreator/Scripts/Game engine/KickStarter.cs:129)

    I assume these will be fixed in an update?


  • Good, thanks. I can't recreate those other errors either, so let's try this:

    GlobalVariables.cs, line 44. From:
    if (GetComponent <Options>() && GetComponent <Options>().optionsData.linkedVariables != "")

    to:
    if (GetComponent <Options>() && GetComponent <Options>().optionsData != null && GetComponent <Options>().optionsData.linkedVariables != "")

    If that works, I should be able to fix the other one too on my end.
  • Update: Never mind.  Found the larger issue, fixed for 1.33.
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.