MCPcopy Create free account
hub / github.com/cuberite/cuberite / UpdateItems

Method UpdateItems

src/Inventory.cpp:524–543  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

522
523
524void cInventory::UpdateItems(void)
525{
526 const cItem & Slot = GetEquippedItem();
527
528 if (Slot.IsEmpty())
529 {
530 return;
531 }
532
533 switch (Slot.m_ItemType)
534 {
535 case E_ITEM_MAP:
536 {
537 ItemHandler(Slot.m_ItemType)->OnUpdate(m_Owner.GetWorld(), &m_Owner, Slot);
538 break;
539 }
540
541 default: break;
542 }
543}
544
545
546

Callers 1

TickMethod · 0.80

Calls 4

ItemHandlerFunction · 0.85
IsEmptyMethod · 0.45
OnUpdateMethod · 0.45
GetWorldMethod · 0.45

Tested by

no test coverage detected