Hi to everyone,
i love Adventure Creator every day a little bit more.
Now i have a problem with save file.
After i Load a saved game and click on a Hotspot with interaction that contain a Save node...
a get this error:
NullReferenceException: Object reference not set to an instance of an object
AC.LevelStorage.SendSceneToData (AC.SubScene subScene) (at C:/Users/Zorky/Documents/UNITY PROGETTI/La foresta incantata 12/Assets/AdventureCreator/Scripts/Save system/LevelStorage.cs:307)
AC.LevelStorage.StoreAllOpenLevelData () (at C:/Users/Zorky/Documents/UNITY PROGETTI/La foresta incantata 12/Assets/AdventureCreator/Scripts/Save system/LevelStorage.cs:241)
AC.SaveSystem.SaveSaveGame (System.Int32 saveID, System.Boolean overwriteLabel, System.String newLabel) (at C:/Users/Zorky/Documents/UNITY PROGETTI/La foresta incantata 12/Assets/AdventureCreator/Scripts/Save system/SaveSystem.cs:746)
AC.SaveSystem.SaveAutoSave () (at C:/Users/Zorky/Documents/UNITY PROGETTI/La foresta incantata 12/Assets/AdventureCreator/Scripts/Save system/SaveSystem.cs:682)
AC.ActionSaveHandle.PerformSaveOrLoad () (at C:/Users/Zorky/Documents/UNITY PROGETTI/La foresta incantata 12/Assets/AdventureCreator/Scripts/Actions/ActionSaveHandle.cs:145)
AC.ActionSaveHandle.Run () (at C:/Users/Zorky/Documents/UNITY PROGETTI/La foresta incantata 12/Assets/AdventureCreator/Scripts/Actions/ActionSaveHandle.cs:68)
AC.ActionList+d__33.MoveNext () (at C:/Users/Zorky/Documents/UNITY PROGETTI/La foresta incantata 12/Assets/AdventureCreator/Scripts/ActionList/ActionList.cs:370)
UnityEngine.SetupCoroutine.InvokeMoveNext (System.Collections.IEnumerator enumerator, System.IntPtr returnValueAddress) (at C:/buildslave/unity/build/Runtime/Export/Scripting/Coroutines.cs:17)
UnityEngine.MonoBehaviour:StartCoroutine(String, Object)
AC.ActionList:ProcessAction(Int32) (at C:/Users/Zorky/Documents/UNITY PROGETTI/La foresta incantata 12/Assets/AdventureCreator/Scripts/ActionList/ActionList.cs:320)
AC.ActionList:ProcessActionEnd(ActionEnd, Int32, Boolean) (at C:/Users/Zorky/Documents/UNITY PROGETTI/La foresta incantata 12/Assets/AdventureCreator/Scripts/ActionList/ActionList.cs:552)
AC.ActionList:EndAction(Action) (at C:/Users/Zorky/Documents/UNITY PROGETTI/La foresta incantata 12/Assets/AdventureCreator/Scripts/ActionList/ActionList.cs:470)
AC.d__33:MoveNext() (at C:/Users/Zorky/Documents/UNITY PROGETTI/La foresta incantata 12/Assets/AdventureCreator/Scripts/ActionList/ActionList.cs:439)
Any idea? Many Thanks,
Paolo
The game is fot IOS, my Unity version is 2019.2.8f1, my AC version is 1.69.2
It looks like you're new here. If you want to get involved, click one of these buttons!
Comments
So you're saying that this only occurs if you load the game beforehand?
Try opening up LevelStorage.cs, and paste the following into line 305:
Does that resolve the issue?
Beautiful, Chris! It work! Thank you very much. Where was the problem? On my project or is a bug on Adventure Creator?
Ok, don't work also in a new fresh project.
I've created a new empty project importing only Adventure Creator 1.69.4 on Unity 2019.2.8f1 Windows 10 64bit.
I've add 1 CUBE 3D and 1 SPHERE 3D.
I've put 2 hotspot, one on each and 2 Remember hotspot.
I've create 2 INTERACTION with: disable hotspot and save (autosave).
When i PLAY, i click on the CUBE, the interaction disable the hotspot and save.
I press STOP.
I press PLAY again and i LOAD the autosave from AC Menu default.
The hotspot on the CUBE is active and if i click on the cube i get the same error:
NullReferenceException: Object reference not set to an instance of an object
AC.LevelStorage.SendSceneToData (AC.SubScene subScene) (at……
For me is very strange. I've read many many post on this forum and you said many time that the hotspot remember is enought for saving the state.
Help!
Thank you, Chris.
Paolo
I've found a thing… The issue appear only on IOS Platform.
If i switch on "PC, MAC & LINUX" or "ANDROID"… all Hotspot remember works fine as aspected.
Are there a solution for IOS platform?
Thanks
What iOS version are you building to? I shall look into this.
Does it work if you enable Json saving by checking Save in Json format? (Experimental) at the top of the Settings Manager?
Hi Chris! Yes! Changing the save format in Json (experimental) all works on iOS!
I'm so happy and grateful to you. Finnally i can close my new 3d adventure game!
When ready i'll send to you a link for download it (if you like and you have time).
Thanks!
Paolo
Great. This issue will be fixed in v1.69.5.