#18 Save/Load Updates

Merged
ryanreed merged 12 commits from save-load-updates into master 1 month ago
ryanreed commented 1 month ago
Owner

This provides a few updates:

  • Moves back from Jolt to default physics
    • Was seeing weird issues with some Block StaticBodys where collision wasn't working after loading a save.
  • Reworked the signals
  • Split the load_save function into load_save and apply_save. This allows for something to happen directly before loading. For instance, clearing the world.
    • Previously, this was located within the SaveGameManger which means the addon wasn't completely independent. This change seprates the last of the logic for the Save Game System addon
  • Hopefully corrects saving 2 players in a save (issue noted in #15 and #16)
This provides a few updates: * Moves back from Jolt to default physics * Was seeing weird issues with some Block StaticBodys where collision wasn't working after loading a save. * Reworked the signals * Split the `load_save` function into `load_save` and `apply_save`. This allows for something to happen directly before loading. For instance, clearing the world. * Previously, this was located within the `SaveGameManger` which means the addon wasn't completely independent. This change seprates the last of the logic for the `Save Game System` addon * Hopefully corrects saving 2 players in a save (issue noted in #15 and #16)
ryanreed added 7 commits 1 month ago
ryanreed added 1 commit 1 month ago
ryanreed added 1 commit 1 month ago
ryanreed commented 1 month ago
Poster
Owner

Just found an issue that may have existed prior to this change:

The file save seems to get larger and larger. Not clear what's causing this at the moment:

.rw-r--r--  5.7M 2025-03-27 17:57 quicksave_game_data.tres
.rw-r--r--  177k 2025-03-27 13:37 save_2025-03-27T133745.tres
.rw-r--r--  355k 2025-03-27 16:29 save_2025-03-27T160327.tres
.rw-r--r--  177k 2025-03-27 16:17 save_2025-03-27T161710.tres
.rw-r--r--  710k 2025-03-27 16:32 save_2025-03-27T163254.tres
.rw-r--r--  712k 2025-03-27 16:33 save_2025-03-27T163321.tres
.rw-r--r--  710k 2025-03-27 16:34 save_2025-03-27T163410.tres
.rw-r--r--  1.4M 2025-03-27 17:55 save_2025-03-27T175551.tres

The large saves seem to happen after a previous save is loaded, indicating previous saves are being appended rather than a completely new save being created.

Just found an issue that may have existed prior to this change: The file save seems to get larger and larger. Not clear what's causing this at the moment: ``` .rw-r--r-- 5.7M 2025-03-27 17:57 quicksave_game_data.tres .rw-r--r-- 177k 2025-03-27 13:37 save_2025-03-27T133745.tres .rw-r--r-- 355k 2025-03-27 16:29 save_2025-03-27T160327.tres .rw-r--r-- 177k 2025-03-27 16:17 save_2025-03-27T161710.tres .rw-r--r-- 710k 2025-03-27 16:32 save_2025-03-27T163254.tres .rw-r--r-- 712k 2025-03-27 16:33 save_2025-03-27T163321.tres .rw-r--r-- 710k 2025-03-27 16:34 save_2025-03-27T163410.tres .rw-r--r-- 1.4M 2025-03-27 17:55 save_2025-03-27T175551.tres ``` The large saves seem to happen after a previous save is loaded, indicating previous saves are being appended rather than a completely new save being created.
ryanreed added 1 commit 1 month ago
ryanreed commented 1 month ago
Poster
Owner

The above issue has been fixed.

Found 1 additional issue: Player is not being saved at the moment

The above issue has been fixed. ~~Found 1 additional issue: Player is not being saved at the moment~~
ryanreed added 1 commit 1 month ago
ryanreed added 1 commit 1 month ago
ryanreed commented 1 month ago
Poster
Owner

Previous issue should be solved now

Previous issue should be solved now
ryanreed commented 1 month ago
Poster
Owner

I believe the issue with using Jolt had to do with appending save files when saving, rather than overwriting data. This caused the loading to try to recreate a number of blocks at the same position. Jolt eventually fails in some way.

I believe e5dbf84a57 should have fixed this problem so I may turn this back to Jolt eventually.

Note: A possible fix for this sort of issue could be to check the block exists before loading at that position

I believe the issue with using Jolt had to do with appending save files when saving, rather than overwriting data. This caused the loading to try to recreate a number of blocks at the same position. Jolt eventually fails in some way. I believe e5dbf84a57 should have fixed this problem so I may turn this back to Jolt eventually. Note: A possible fix for this sort of issue could be to check the block exists before loading at that position
ryanreed changed title from WIP: Save/Load Updates to Save/Load Updates 1 month ago
ryanreed merged commit b04f54660c into master 1 month ago
ryanreed deleted branch save-load-updates 1 month ago
The pull request has been merged as b04f54660c.
Sign in to join this conversation.
No reviewers
No Label
No Milestone
No Assignees
1 Participants
Notifications
Due Date

No due date set.

Dependencies

This pull request currently doesn't have any dependencies.

Loading…
There is no content yet.