0.10.15 - City Guards are not restored by save/reloading

User avatar
pango
Posts: 3347
Joined: Wed Jul 18, 2018 6:14 pm
Location: France
Contact:

0.10.15 - City Guards are not restored by save/reloading

Post by pango »

Well, everything is in the title really...
Mastodon: @pango@fosstodon.org
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

User avatar
Hazelnut
Posts: 3015
Joined: Sat Aug 26, 2017 2:46 pm
Contact:

Re: City Guards are not restored by save/reloading

Post by Hazelnut »

except for whether this matches classic or not. :P
See my mod code for examples of how to change various aspects of DFU: https://github.com/ajrb/dfunity-mods

User avatar
pango
Posts: 3347
Joined: Wed Jul 18, 2018 6:14 pm
Location: France
Contact:

Re: City Guards are not restored by save/reloading

Post by pango »

It doesn't match classic, attaching a savegame, surrounded by guards.
Attachments
SAVE4.zip
(170.65 KiB) Downloaded 113 times
Mastodon: @pango@fosstodon.org
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

hannafamilycomputer
Posts: 71
Joined: Wed Sep 25, 2019 12:19 am

Re: City Guards are not restored by save/reloading

Post by hannafamilycomputer »

Ghosts in daggerfall at night aren't restored ethier. I saved a game while they were following me (they were chasing me all the way til daytime) , and they disappear when you load it, even though you can see them in the save game preview.

I'll upload a save in a few days if needed (and I remember)


Edit: 1/11/2022. I forgot. Well here is the save's picture.
Screenshot.jpg
Screenshot.jpg (170.42 KiB) Viewed 2176 times
SAVE18.zip
(466.83 KiB) Downloaded 116 times
Yes, I know the question's already been answered, but I had to stay true to my word :)
Last edited by hannafamilycomputer on Sat Jan 11, 2020 8:32 pm, edited 2 times in total.

User avatar
Hazelnut
Posts: 3015
Joined: Sat Aug 26, 2017 2:46 pm
Contact:

Re: City Guards are not restored by save/reloading

Post by Hazelnut »

Does this differ from say mobs in wilderness and a save/load by any chance?

Something may have broken or been missed here.
See my mod code for examples of how to change various aspects of DFU: https://github.com/ajrb/dfunity-mods

User avatar
Interkarma
Posts: 7236
Joined: Sun Mar 22, 2015 1:51 am

Re: City Guards are not restored by save/reloading

Post by Interkarma »

This is a fairly simple scene parenting issue (i.e. the mobs aren't parented correctly for serialization). I didn't realise this was the case with guards.

Thanks for letting me know. I'll move to bug reports and fix up when I can. Same for ghosts / quest spawns in towns.

User avatar
pango
Posts: 3347
Joined: Wed Jul 18, 2018 6:14 pm
Location: France
Contact:

Re: 0.10.15 - City Guards are not restored by save/reloading

Post by pango »

Just watched Grimith's stream EP5 to the end, and it seems to be a little more subtle; Guards spawning after killing commoners aren't restored, but guards spontaneously spawning because of criminal conspiracy are...
So yes, probably very little is missing to get it working all the time

Some other small issues happened to him with City Guards on his first stream, for example when he flee to a different region because he was chased by guards for some crimes, he got attacked again in the first town he arrived... Probably some state that needs clearing upon fast travel?
I wanted to reproduce the issue first, but if you have any idea why this could happen, that's something that could be looked into.
Mastodon: @pango@fosstodon.org
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

User avatar
Seferoth
Posts: 665
Joined: Fri Nov 22, 2019 5:45 pm
Location: Finland

Re: 0.10.15 - City Guards are not restored by save/reloading

Post by Seferoth »

pango wrote: Thu Dec 19, 2019 1:48 am Just watched Grimith's stream EP5 to the end, and it seems to be a little more subtle; Guards spawning after killing commoners aren't restored, but guards spontaneously spawning because of criminal conspiracy are...
So yes, probably very little is missing to get it working all the time

Some other small issues happened to him with City Guards on his first stream, for example when he flee to a different region because he was chased by guards for some crimes, he got attacked again in the first town he arrived... Probably some state that needs clearing upon fast travel?
I wanted to reproduce the issue first, but if you have any idea why this could happen, that's something that could be looked into.
I had similar issue with the quest "Lost Artifact", i think that was it, anyway the one where you have to kidnap a kid for the witch. I got the kid and recalled to the dungeon next to witch and tons of guards spawned immediately there too. Don't know if this is on purpose, but it really does not make any sense.

User avatar
pango
Posts: 3347
Joined: Wed Jul 18, 2018 6:14 pm
Location: France
Contact:

Re: 0.10.15 - City Guards are not restored by save/reloading

Post by pango »

Seferoth wrote: Thu Dec 19, 2019 2:52 am I had similar issue with the quest "Lost Artifact", i think that was it, anyway the one where you have to kidnap a kid for the witch. I got the kid and recalled to the dungeon next to witch and tons of guards spawned immediately there too. Don't know if this is on purpose, but it really does not make any sense.
Such quests can spawn enemies, so that's probably normal:

Code: Select all

	create foe _warrior_ every 15 minutes 40 times with 100% success msg 1012 
So I'm talking of game behavior with no such quest running (hopefully; and that's one of the reason I would have like to reproduce the problem myself first)
Mastodon: @pango@fosstodon.org
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

User avatar
Hazelnut
Posts: 3015
Joined: Sat Aug 26, 2017 2:46 pm
Contact:

Re: City Guards are not restored by save/reloading

Post by Hazelnut »

Interkarma wrote: Wed Dec 18, 2019 11:25 pm This is a fairly simple scene parenting issue (i.e. the mobs aren't parented correctly for serialization). I didn't realise this was the case with guards.

Thanks for letting me know. I'll move to bug reports and fix up when I can. Same for ghosts / quest spawns in towns.
I've been looking at the scene caching for the corpses issue and enemies are not cached which means that even for mobs parented correctly for serialisation are not restored from a save if the player enters a building before saving. When loaded the mobs are missing. This differs from classic which reloads the outside mobs successfully even when saved inside.

I'm not familiar with the serialization system used for this, but IIRC we agreed that scene cache should not persist mobs as it was already handled. If this needs to change, the cache can handle mobs easily enough but the existing system will need to change so as not to duplicate mobs on transitions between exteriors and interiors.

Also foes created from quests are added to loose item tracking if spawned in exterior, but those created using foespawner class are not. That is not what I would expect. Anyway can pick this up with you once you get some time to dig into it.
See my mod code for examples of how to change various aspects of DFU: https://github.com/ajrb/dfunity-mods

Locked