Advertisement
Guest User

Untitled

a guest
Jul 23rd, 2019
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.88 KB | None | 0 0
  1. ool CPetActor::Update(DWORD deltaTime)
  2. {
  3. bool bResult = true;
  4. #ifdef ENABLE_FIX_PETY
  5. if((this->GetSummonItemVID() != 0 && (NULL == ITEM_MANAGER::instance().FindByVID(this->GetSummonItemVID()) || ITEM_MANAGER::instance().FindByVID(this->GetSummonItemVID())->GetOwner() != this->GetOwner())))
  6. {
  7. m_pkOwner->SetQuestFlag("pet_system.pet_vnum", 0);
  8. m_pkOwner->SetQuestFlag("pet_item_id.pet_vnum", 0);
  9. this->Unsummon();
  10. return true;
  11. }
  12. #endif
  13. #ifdef ENABLE_SYSTEMY_PETY
  14. if (this->IsSummoned() && m_pkUpdate == 1)
  15. {
  16. long x = m_pkChar->GetX();
  17. long y = m_pkChar->GetY();
  18.  
  19. if (0 != m_pkChar)
  20. {
  21. this->SetName(this->GetName());
  22. m_pkChar->Show(m_pkOwner->GetMapIndex(), x, y);
  23. m_pkUpdate = 0;
  24. }
  25. }
  26. #endif
  27.  
  28. if(this->IsSummoned() && HasOption(EPetOption_Followable))
  29. {
  30. bResult = bResult && this->_UpdateFollowAI();
  31. }
  32.  
  33.  
  34. return bResult;
  35. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement