Jump to content

Prince

Members
  • Posts

    15
  • Joined

  • Last visited

    Never
  • Donations

    0.00 GBP 

Prince's Achievements

Member

Member (2/3)

0

Reputation

  1. could someone finally stop this spamer, thanks?! it can't be that one guy post one crash hundrets of times! :mad:
  2. Ok, thanks. I'll think about it and try to give the players in Ahn'kahet the Jedoga additional achievement via Player::UpdateAchievementCriteria...
  3. Hello! I would like to use code like this (Ahn'kahet example) for instance achievements: if (!onedead) { /* Nicht möglich, da "CompletedAchievement()" privat ist! AchievementEntry const* AE = sAchievementStore.LookupEntry(AchievementVolunteerWork); Map::PlayerList const &PlayerList = instance->GetPlayers(); if (!PlayerList.isEmpty()) { for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i) (i->getSource())->GetAchievementMgr().CompletedAchievement(AE); }*/ } the problem is that CompletedAchievement() is a private function. Couldn't / shouldn't we not simple make it public to let developer use this in instance scripts!? :confused:
  4. could someone generate a patch for the latest rev and post it here, thanks?!
  5. no. it's the same problem as with arrais issue. the loot is first created if the player try to loot something. you can't check at this place wether the loot is empty (if there is a loot id) nor if there is gold. that's the problem which i wrote above. my patch is only for creatures (npcs).
  6. "loot" is first created here "void Player::SendLoot(uint64 guid, LootType loot_type)" and this is first executed if the player try to loot the creature. if (uint32 lootid = creature->GetCreatureInfo()->lootid) loot->FillLoot(lootid, LootTemplates_Creature, recipient, false); we have no chance to fix arrai's issue without move the above code to unit atm.
  7. " && !cVictim->loot.empty()" seems not to work and looks that the loot is created later somewhere in the source. don't know where atm. :confused: simply remove " && !cVictim->loot.empty()" again out of the patch and it works again.
  8. deeper look -> more simple (correct) fix found. see first post.
  9. simple... it was a fast search for the flag and this was the second occurence of this flag and the first place where i could fix it. perhaps i'll look later for a better position...
  10. because of this bothers me since mangos was born, i wrote this just in the moment... on offi you'll never get lootable animation for creatures without loot. What bug does the patch fix? What features does the patch add? - it prevent to show the lootable animation for creatures without loot For which repository revision was the patch created? - rev 8250 Is there a thread in the bug report section or at lighthouse? If yes, please add a link to the thread. - I don't believe it... I don't know... Who has been writing this patch? Please include either forum user names or email addresses. - Prince THE DIFF diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index 0b67a2f..0dfda03 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -647,7 +657,8 @@ uint32 Unit::DealDamage(Unit *pVictim, uint32 damage, CleanDamage const* cleanDa if(!cVictim->isPet()) { cVictim->DeleteThreatList(); - cVictim->SetUInt32Value(UNIT_DYNAMIC_FLAGS, UNIT_DYNFLAG_LOOTABLE); + if (cVictim->GetCreatureInfo()->lootid) + cVictim->SetUInt32Value(UNIT_DYNAMIC_FLAGS, UNIT_DYNFLAG_LOOTABLE); } // Call creature just died function if (cVictim->AI())
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use