MCPcopy Create free account
hub / github.com/crossuo/crossuo / DrawCorpse

Method DrawCorpse

src/Managers/AnimationManager.cpp:1436–1453  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1434}
1435
1436void CAnimationManager::DrawCorpse(CGameItem *obj, int x, int y)
1437{
1438 if (g_CorpseManager.InList(obj->Serial, 0))
1439 {
1440 return;
1441 }
1442
1443 m_Sitting = 0;
1444 Anim.Direction = (obj->Layer & 0x7F) & 7;
1445 bool mirror = false;
1446 GetAnimDirection(Anim.Direction, mirror);
1447 Color = obj->Hidden() ? 0x038E : 0;
1448 uint8_t animIndex = obj->AnimIndex;
1449 const uint16_t graphic = g_AnimationManager.ConvertBodyIfNeeded(obj->GetGraphicForAnimation());
1450 Anim.Group = GetDieGroupIndex(graphic, obj->UsedLayer != 0);
1451 Draw(obj, x, y, mirror, animIndex); //Draw animation
1452 DrawEquippedLayers(false, obj, x, y, mirror, Anim.Direction, animIndex, 0);
1453}
1454
1455bool CAnimationManager::CorpsePixelsInXY(CGameItem *obj, int x, int y)
1456{

Callers 1

DrawMethod · 0.80

Calls 5

InListMethod · 0.80
HiddenMethod · 0.80
ConvertBodyIfNeededMethod · 0.80
DrawFunction · 0.50

Tested by

no test coverage detected