game.cpp: When A_Spawn() is spawning from an already existing sprite, do not reset the owner field if it has been overridden from the default.

git-svn-id: https://svn.eduke32.com/eduke32@7738 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
pogokeen 2019-06-25 18:35:22 +00:00 committed by Christoph Oelckers
parent d621023807
commit cfa0ea2a65

View file

@ -1445,7 +1445,10 @@ int A_Spawn(int spriteNum, int tileNum)
if (s.picnum == SECTOREFFECTOR && s.lotag == 50)
a.picnum = s.owner;
s.owner = a.owner = newSprite;
if (s.owner == -1)
s.owner = a.owner = newSprite;
else
a.owner = s.owner;
a.floorz = sector[s.sectnum].floorz;
a.ceilingz = sector[s.sectnum].ceilingz;