cleans up extra=extra complaint

This commit is contained in:
Azaezel 2018-03-12 17:41:22 -05:00
parent c875f44bd1
commit 015f07e50e
4 changed files with 10 additions and 10 deletions

View file

@ -1089,9 +1089,9 @@ U32 afxMagicSpell::packUpdate(NetConnection* conn, U32 mask, BitStream* stream)
if (stream->writeFlag(mask & InitialUpdateMask))
{
// pack extra object's ghost index or scope id if not yet ghosted
if (stream->writeFlag(dynamic_cast<NetObject*>(extra) != 0))
if (stream->writeFlag(dynamic_cast<NetObject*>(mExtra) != 0))
{
NetObject* net_extra = (NetObject*)extra;
NetObject* net_extra = (NetObject*)mExtra;
S32 ghost_idx = conn->getGhostIndex(net_extra);
if (stream->writeFlag(ghost_idx != -1))
stream->writeRangedU32(U32(ghost_idx), 0, NetConnection::MaxGhostCount);
@ -1252,7 +1252,7 @@ void afxMagicSpell::unpackUpdate(NetConnection * conn, BitStream * stream)
if (stream->readFlag()) // is ghost_idx
{
S32 ghost_idx = stream->readRangedU32(0, NetConnection::MaxGhostCount);
extra = dynamic_cast<SimObject*>(conn->resolveGhost(ghost_idx));
mExtra = dynamic_cast<SimObject*>(conn->resolveGhost(ghost_idx));
}
else
{