Forum rules - please read before posting.

Selective Save

Is there any way to do selective save? I want my character to stay on his last position on a scene, then i change scene and add / remove his inventory, and then back to original scene with his last position intact?

I am thinking of selective save, which is save only his inventory. So i can just go back and load to get ny character in his previous position

Comments

  • Welcome to the community, @gearball.

    I'm afraid I'm not too clear from your wording exactly what you want your character to do, but the save game file will always save all data.  You can choose exactly what data gets loaded, however if you use the Save: Save or load Action to load your game, rather than use the default click of a SavesList menu element.  In principle this should give you the same thing.

    In order to hook up a Save: Save or load Action to your Load Menu, create a new ActionList asset that contains this Action.  Then create a new Integer parameter for that ActionList (see this tutorial) and use it to override the Set Slot Index in your load Action.

    Finally, navigate to your SavesList element in your Load menu in the Menu Manager, uncheck Load when click on?, and assign your new ActionList as the ActionList when click?.  You should then see the integer parameter appear beneath, meaning that this value will be set to the slot index when clicked, and hence the correct slot index will be sent to the Action.
  • edited October 2016
    Umm, that's one thing I've been trying to find out too. Making sure the player stays where he was before a scene change it's something most people who want to add JRPG features to a game have to research sometime, as It's used often for changing to battle scenes and other stuff.

    In this case, and If you know a bit of coding, there's another option which is to use additive scene loading. If you are interested, here are some people talking about some techniques to do that in unity. And here is a more current example and replacement for the old Application.LoadLevelAdditive. Of course you could also just try to capture the player's last transform.position and put him there when coming back to the scene, but it may not work as gracefully and would still need some coding.

    Anyway, I still haven't had the chance to play with this much, since I'm not working in the battle for my mobile project yet, but if I find out more I'll let you know. (I think AC has some additive scene loading features too, but I haven't had the time to test them either)
  • @Alverik: It does, though it's not widely used - the Scene: Add or remove Action can be used to merge scenes together during gameplay in the more recent versions of Unity.
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.