Dev build/Linux: pacification regression [RESOLVED]

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

Dev build/Linux: pacification regression [RESOLVED]

Post by pango » Thu Jan 10, 2019 9:29 pm

It seems there has been some regression in pacification: when I get a message that I pacified some monster with a language/etiquette skill, it keeps attacking me.
If I save/reload the game, the monsters finally becomes pacific. So I'm not sure the gamesave will be of any use.
Attachments
SAVE1.zip
(479.71 KiB) Downloaded 8 times
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

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

Re: Dev build/Linux: pacification regression

Post by Hazelnut » Thu Jan 10, 2019 9:31 pm

Are you sure there are not 2 of the mobs and you pacify one that you're unaware of and the other attacks?

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

Re: Dev build/Linux: pacification regression

Post by pango » Thu Jan 10, 2019 9:50 pm

How comes this one is pacific (without new message) after save/reload?
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

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

Re: Dev build/Linux: pacification regression

Post by Hazelnut » Sat Jan 12, 2019 4:14 pm

I loaded the save and as you said found the vamp was pacified. I did get an error on load however, although I've no idea if it's anything to do with the issue. From comments in this code, it seems it's simply an issue with the loading and re-init of cyclic dependencies. Doubt this is connected to your issue.

Code: Select all

EntityEffect.RestoreEffectSaveData() could not find SerializableEnemy for LoadID 26169480 in StateManager.
UnityEngine.Debug:LogError(Object)
DaggerfallWorkshop.Game.MagicAndEffects.EntityEffectManager:GetCasterReference(EntityTypes, UInt64) (at Assets/Scripts/Game/MagicAndEffects/EntityEffectManager.cs:1825)
DaggerfallWorkshop.Game.MagicAndEffects.EntityEffectManager:RestoreInstancedBundleSaveData(EffectBundleSaveData_v1[]) (at Assets/Scripts/Game/MagicAndEffects/EntityEffectManager.cs:1762)
DaggerfallWorkshop.Game.Serialization.SerializableEnemy:RestoreSaveData(Object) (at Assets/Scripts/Game/Serialization/SerializableEnemy.cs:209)
DaggerfallWorkshop.Game.Serialization.SerializableStateManager:RestoreEnemyData(EnemyData_v1[]) (at Assets/Scripts/Game/Serialization/SerializableStateManager.cs:407)
DaggerfallWorkshop.Game.Serialization.SaveLoadManager:RestoreSaveData(SaveData_v1) (at Assets/Scripts/Game/Serialization/SaveLoadManager.cs:837)
DaggerfallWorkshop.Game.Serialization.<LoadGame>c__Iterator2:MoveNext() (at Assets/Scripts/Game/Serialization/SaveLoadManager.cs:1170)

RestoreInstancedBundleSaveData() could not restore effect as caster was not found.
UnityEngine.Debug:LogWarning(Object)
DaggerfallWorkshop.Game.MagicAndEffects.EntityEffectManager:RestoreInstancedBundleSaveData(EffectBundleSaveData_v1[]) (at Assets/Scripts/Game/MagicAndEffects/EntityEffectManager.cs:1782)
DaggerfallWorkshop.Game.Serialization.SerializableEnemy:RestoreSaveData(Object) (at Assets/Scripts/Game/Serialization/SerializableEnemy.cs:209)
DaggerfallWorkshop.Game.Serialization.SerializableStateManager:RestoreEnemyData(EnemyData_v1[]) (at Assets/Scripts/Game/Serialization/SerializableStateManager.cs:407)
DaggerfallWorkshop.Game.Serialization.SaveLoadManager:RestoreSaveData(SaveData_v1) (at Assets/Scripts/Game/Serialization/SaveLoadManager.cs:837)
DaggerfallWorkshop.Game.Serialization.<LoadGame>c__Iterator2:MoveNext() (at Assets/Scripts/Game/Serialization/SaveLoadManager.cs:1170)


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

Re: Dev build/Linux: pacification regression

Post by Hazelnut » Sat Jan 12, 2019 4:47 pm

Yep, that has nothing to do with this issue as I thought. The problem is caused by resume persuing previous target code added to EnemySenses on 6th Jan in commit 6afc9428 by Allofich. Basically the last target is the player so this code restores the player as target after the target is removed due to being non-hostile.

Code: Select all

                    // If had a valid target before, resume pursuing it. Looks better to first finish any attack animation.
                    if (lastTarget != null && lastTarget.Entity.CurrentHealth > 0 && !mobile.IsPlayingOneShot())
                        target = lastTarget;
Allofich, going to leave this one to you since, while I could fix this specific issue, I don't have enough understanding of the code to ensure other aspects are not compromised.

R.D.
Posts: 379
Joined: Fri Oct 07, 2016 10:41 am

Re: Dev build/Linux: pacification regression

Post by R.D. » Mon Jan 14, 2019 2:24 am

Will take a look soon.

R.D.
Posts: 379
Joined: Fri Oct 07, 2016 10:41 am

Re: Dev build/Linux: pacification regression

Post by R.D. » Sat Jan 19, 2019 4:46 am

Fixed.

Post Reply