mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-19 22:23:51 +00:00
[Client] Fix double summoning magical effects
This commit is contained in:
parent
3e7230e89d
commit
ee84868b7d
1 changed files with 3 additions and 1 deletions
|
@ -495,7 +495,9 @@ void ObjectList::spawnObjects(MWWorld::CellStore* cellStore)
|
|||
LOG_APPEND(TimedLog::LOG_INFO, "-- adding active spell to master with id %s, effect %i, duration %f",
|
||||
baseObject.summonSpellId.c_str(), baseObject.summonEffectId, baseObject.summonDuration);
|
||||
|
||||
masterCreatureStats.getActiveSpells().addSpell(baseObject.summonSpellId, false, activeEffects, "", masterCreatureStats.getActorId());
|
||||
auto activeSpells = masterCreatureStats.getActiveSpells();
|
||||
if (!activeSpells.isSpellActive(baseObject.summonSpellId))
|
||||
activeSpells.addSpell(baseObject.summonSpellId, false, activeEffects, "", masterCreatureStats.getActorId());
|
||||
|
||||
LOG_APPEND(TimedLog::LOG_INFO, "-- setting summoned creatureActorId for %i-%i to %i",
|
||||
newPtr.getCellRef().getRefNum(), newPtr.getCellRef().getMpNum(), creatureActorId);
|
||||
|
|
Loading…
Reference in a new issue