|
Post by nitrox32 on Oct 17, 2019 0:37:27 GMT
Is there a way to save the state of a locked door? I'm using Dialogue System's save system and the inventory, item states, and player position are all saving correctly but every time I save and come back to the scene the door is locked again. I put a DS position saver component which should save the position an rotation of the door but the door keeps resetting when the scene opens. Tony at Pixelcrushers suggested that I use an animation saver component which is part of DS save system. The only problem is that from what I can tell the simple door component doesn't use an animator. Any idea on how not to have the door reset?
|
|
|
Post by shadex on Oct 17, 2019 15:23:15 GMT
Is there a way to save the state of a locked door? I'm using Dialogue System's save system and the inventory, item states, and player position are all saving correctly but every time I save and come back to the scene the door is locked again. I put a DS position saver component which should save the position an rotation of the door but the door keeps resetting when the scene opens. Tony at Pixelcrushers suggested that I use an animation saver component which is part of DS save system. The only problem is that from what I can tell the simple door component doesn't use an animator. Any idea on how not to have the door reset? That's not a simple question. It's a going to be a design question. For instance, if your loading your level's additivly, using multiple scenes, you can simply keep the scene with the locked doors disabled but loaded, or disable all objects in the scene, and reneable when loading.
If you need to unload that scene then you need to look into serializer, which is what that animation saver component is (though i think invector's door uses rotations). Most people end up writing a little script using easy save 3. But to answer your question, assuming that the animation saver would work, just create your own door opening animation and trigger it instead of invectors door rotation.
|
|
|
Post by nitrox32 on Oct 19, 2019 15:18:39 GMT
Actually the solution was quite simple for my design choices. I did end up using the DS position saver component. It should of been placed on the door model itself instead of the parent object that contained the vSimpleDoor and UseItemEventTrigger compnonets. I also had to untick Auto Close in the vSimpleDoor component.
|
|