Forum rules - please read before posting.

Issue when saving

edited June 2014 in Technical Q&A
Hi again :) I know Chris everytime u read me u are desperated :(

Btw this is the problem :)

All my cameras in the scene have the yrotation unlocked and the field of view unlocked. I was experimenting with save and load and I got this issue. When the game starts after loading the camera is totally locked...I need to change camera moving with my character to reactivate the rotations and the field of view on the cameras.

Plus I was wondering if there is a way to remove the various save I did to test the game. thx

Comments

  • Be sure to add a ConstantID script to any camera that can be active when saving (i.e. gameplay cameras).  If you don't the save game file won't be able to store which camera is active at the time.

    When you save a game, check the console log: it should tell you the folder location.
  • That worked perfectly :) this constant id is important for every item that need to be stored for the save? like hotspots or objects in the scene? and what retain in prefab exactly means?
  • Unless it's a "standard" object like the Player prefab, you generally need either a ConstantID or Remember script on it for it's data to be saved.  The need to manually assign this script is to keep save file sizes down: you only save what you need to.

    "Retain in prefab" means that if you make a prefab out of an object with a Constant ID, the ID will be retained.  By default, the Constant ID value won't be stored as part of the prefab - this ensures the scene object's ID value is unique.  However, if you have an object that appears in several scenes (e.g. an NPC), you'd want to check this box.
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.