Jump to content

patro

Members
  • Posts

    15
  • Joined

  • Last visited

    Never
  • Donations

    0.00 GBP 

patro's Achievements

Member

Member (2/3)

0

Reputation

  1. I'll update my patch when i got the time and the sources for it.
  2. Edit: Nevermind, i storted it out correctly
  3. I dunno... depends on which one of the four patches you use, which rev of MaNGOS you use, and when the crash happens
  4. I have the same problem. Every time i use $git pull, i get those errors... Any enlightment about how to update properly?
  5. My last attempt for this, just updated to the latest rev. Also uploaded it to filebeam. http://filebeam.com/5cbdb8f10f7d7d4aa79d3f66c09c1e93 @ Thorazi, looks like your patchfile is missing something
  6. Cuz we <3 to stick with a stable version J/k, i just don't wanna update my server everytime. If i get things sorted out, i'll update it. But untill then you can always add one of the 4 patches given manually. It's not that much work, and we gotta do it aswell
  7. Editted my post, i don't know if this one works... i get some weird errors with GIT lately... i think it's time to format my pc again
  8. For rev. 7776 (last one i made) diff --git a/src/game/Group.cpp b/src/game/Group.cpp index b2b495c..a2b99f1 100644 --- a/src/game/Group.cpp +++ b/src/game/Group.cpp @@ -310,6 +310,8 @@ bool Group::AddMember(const uint64 &guid, const char* name) uint32 Group::RemoveMember(const uint64 &guid, const uint8 &method) { + BroadcastGroupUpdate(); + // remove member and change leader (if need) only if strong more 2 members _before_ member remove if(GetMembersCount() > (isBGGroup() ? 1 : 2)) // in BG group case allow 1 members group { @@ -1595,3 +1597,18 @@ void Group::_homebindIfInstance(Player *player) player->m_InstanceValid = false; } } + +void Group::BroadcastGroupUpdate(void) +{ + // Group Hack: force flags update on group leave - for values update hack + for(member_citerator citr = m_memberSlots.begin(); citr != m_memberSlots.end(); ++citr) + { + Player *pp = objmgr.GetPlayer(citr->guid); + if(pp && pp->IsInWorld()) + { + pp->ForceValuesUpdateAtIndex(UNIT_FIELD_BYTES_2); + pp->ForceValuesUpdateAtIndex(UNIT_FIELD_FACTIONTEMPLATE); + DEBUG_LOG("-- Forced group value update for '%s'", pp->GetName()); + } + } +} \\ No newline at end of file diff --git a/src/game/Group.h b/src/game/Group.h index 478b7c5..17cfac9 100644 --- a/src/game/Group.h +++ b/src/game/Group.h @@ -330,6 +330,9 @@ class MANGOS_DLL_SPEC Group InstanceGroupBind* GetBoundInstance(uint32 mapid, uint8 difficulty); BoundInstancesMap& GetBoundInstances(uint8 difficulty) { return m_boundInstances[difficulty]; } + //Group hack. + void BroadcastGroupUpdate(void); + protected: bool _addMember(const uint64 &guid, const char* name, bool isAssistant=false); bool _addMember(const uint64 &guid, const char* name, bool isAssistant, uint8 group); diff --git a/src/game/GroupHandler.cpp b/src/game/GroupHandler.cpp index b7c55e6..0373ab4 100644 --- a/src/game/GroupHandler.cpp +++ b/src/game/GroupHandler.cpp @@ -196,6 +196,7 @@ void WorldSession::HandleGroupAcceptOpcode( WorldPacket & /*recv_data*/ ) if(!group->AddMember(GetPlayer()->GetGUID(), GetPlayer()->GetName())) return; + group->BroadcastGroupUpdate(); } void WorldSession::HandleGroupDeclineOpcode( WorldPacket & /*recv_data*/ ) diff --git a/src/game/Object.cpp b/src/game/Object.cpp index 15963e8..35da227 100644 --- a/src/game/Object.cpp +++ b/src/game/Object.cpp @@ -637,6 +637,38 @@ void Object::_BuildValuesUpdate(uint8 updatetype, ByteBuffer * data, UpdateMask else *data << (m_uint32Values[ index ] & ~UNIT_DYNFLAG_OTHER_TAGGER); } + // FG: pretend that OTHER players in own group are friendly ("blue") + else if(index == UNIT_FIELD_BYTES_2 || index == UNIT_FIELD_FACTIONTEMPLATE) + { + bool ch = false; + if(target->GetTypeId() == TYPEID_PLAYER && GetTypeId() == TYPEID_PLAYER && target != this) + { + if(target->IsInSameGroupWith((Player*)this) || target->IsInSameRaidWith((Player*)this)) + { + if(index == UNIT_FIELD_BYTES_2) + { + DEBUG_LOG("-- VALUES_UPDATE: Sending '%s' the blue-group-fix from '%s' (flag)", target->GetName(), ((Player*)this)->GetName()); + *data << ( m_uint32Values[ index ] & (UNIT_BYTE2_FLAG_SANCTUARY << 8) ); // this flag is at uint8 offset 1 !! + ch = true; + } + else if(index == UNIT_FIELD_FACTIONTEMPLATE) + { + FactionTemplateEntry const *ft1, *ft2; + ft1 = ((Player*)this)->getFactionTemplateEntry(); + ft2 = ((Player*)target)->getFactionTemplateEntry(); + if(ft1 && ft2 && !ft1->IsFriendlyTo(*ft2)) + { + uint32 faction = ((Player*)target)->getFaction(); // pretend that all other HOSTILE players have own faction, to allow follow, heal, rezz (trade wont work) + DEBUG_LOG("-- VALUES_UPDATE: Sending '%s' the blue-group-fix from '%s' (faction %u)", target->GetName(), ((Player*)this)->GetName(), faction); + *data << uint32(faction); + ch = true; + } + } + } + } + if(!ch) + *data << m_uint32Values[ index ]; + } else { // send in current format (float as float, uint32 as uint32) @@ -1496,6 +1528,19 @@ Creature* WorldObject::SummonCreature(uint32 id, float x, float y, float z, floa return pCreature; } +void Object::ForceValuesUpdateAtIndex(uint32 i) +{ + m_uint32Values_mirror[i] = GetUInt32Value(i) + 1; // makes server think the field changed + if(m_inWorld) + { + if(!m_objectUpdated) + { + ObjectAccessor::Instance().AddUpdateObject(this); + m_objectUpdated = true; + } + } +} + namespace MaNGOS { class NearUsedPosDo diff --git a/src/game/Object.h b/src/game/Object.h index fc01e3a..ab0fdbc 100644 --- a/src/game/Object.h +++ b/src/game/Object.h @@ -300,6 +300,9 @@ class MANGOS_DLL_SPEC Object virtual bool hasQuest(uint32 /* quest_id */) const { return false; } virtual bool hasInvolvedQuest(uint32 /* quest_id */) const { return false; } + + void ForceValuesUpdateAtIndex(uint32); + protected: Object ( ); diff --git a/src/game/TradeHandler.cpp b/src/game/TradeHandler.cpp index aa323c9..df83656 100644 --- a/src/game/TradeHandler.cpp +++ b/src/game/TradeHandler.cpp @@ -534,11 +534,11 @@ void WorldSession::HandleInitiateTradeOpcode(WorldPacket& recvPacket) return; } - if(pOther->GetTeam() !=_player->GetTeam() ) + /*if(pOther->GetTeam() !=_player->GetTeam() ) { SendTradeStatus(TRADE_STATUS_WRONG_FACTION); return; - } + }*/ if( pOther->GetDistance2d( _player ) > 10.0f ) { Thnx to False.Genesis for the original patch Thnx to Frozen-in-Time for the trading fix part
  9. What server rev are you trying to apply it to? Cuz he said in the first post the patch was for rev 7464
  10. I always used this from False.Genesis's GitHub: 2[/color][/size]22[/color][/size]22[/color][/size]22[/color][/size]22[/color][/size]22[/color][/size]22[/color][/size]22[/color][/size]22[/color][/size]2 It always worked for me
  11. I've finally installed / compiled my server again, and i'm also figgling around with your given codes I've tried the one from post #17, but i can summon a ghoul w/out Corpse Dust or a nearby corpse (dunno how that can be, i've might done something wrong... i'm not an expert in C++, but i'm learning it on the way ) Also, on the very first try of casting the spell with the Ghoul-mastery talent on, i've summoned a pet with the name "Bonerawler". But after i dismissed him to give it another shot, he was called "Risen Ghoul" :huh: (Every time i summon him now, he's called like that...) I'm going to see if i can help you guys a bit. Anyways, great work making it work sofar. =) Edit: you got a little typo in your last code: ManGOS::XP::GetGrayLevel, it should be with a capital "N"
  12. Confirmed on rev. 7629 Necrosis needs mana apparently, combat log gives Player's Nercosis failed. (Not enough mana) Player also gets the error message out of mana.
  13. Hmm dunno if it's relevant, but there's a way atm to explore The Black Temple. You've gotta try to fly over the wall behind the Doomwalker (just try to get over the edge of the wall) and you get the explore thingy I don't think this is the right way to do it, and i doubt it's offi-like
  14. Got some problems too with the extractor, but i'll wait for a good release Great job Mangos Devs and a big thnx!
  15. Hmm, i've also been thinking to do something with the area beneath Karazhan, but i didn't came too far... It's not an "real instance", so it's hard to make something nice out of it. I just created a few boss scripts with SD2, and spawned the bosses in there. And to let the players come in, i made a areatrigger NPC.
×
×
  • 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