mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-23 18:36:31 +01:00
Merge branch 'master' of github.com:TrinityCore/TrinityCore into 4.3.4
Conflicts: src/server/game/AuctionHouse/AuctionHouseMgr.h src/server/game/Entities/Creature/Creature.cpp src/server/game/Entities/Player/Player.cpp src/server/game/Entities/Unit/StatSystem.cpp src/server/game/Entities/Unit/Unit.cpp src/server/game/Entities/Vehicle/Vehicle.cpp src/server/game/Handlers/NPCHandler.cpp
This commit is contained in:
@@ -99,9 +99,6 @@ public:
|
||||
if (!player->HasAuraType(SPELL_AURA_MOD_SHAPESHIFT))
|
||||
player->SetShapeshiftForm(FORM_NONE);
|
||||
|
||||
player->SetFloatValue(UNIT_FIELD_BOUNDINGRADIUS, DEFAULT_WORLD_OBJECT_SIZE);
|
||||
player->SetFloatValue(UNIT_FIELD_COMBATREACH, DEFAULT_COMBAT_REACH);
|
||||
|
||||
player->setFactionForRace(player->getRace());
|
||||
|
||||
player->SetUInt32Value(UNIT_FIELD_BYTES_0, ((player->getRace()) | (player->getClass() << 8) | (player->getGender() << 16) | (powerType << 24)));
|
||||
@@ -116,8 +113,6 @@ public:
|
||||
|
||||
//-1 is default value
|
||||
player->SetUInt32Value(PLAYER_FIELD_WATCHED_FACTION_INDEX, uint32(-1));
|
||||
|
||||
//player->SetUInt32Value(PLAYER_FIELD_BYTES, 0xEEE00000);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -51,7 +51,8 @@ enum mainCreatures
|
||||
CREATURE_ECK = 29932
|
||||
};
|
||||
|
||||
enum Gameobjects {
|
||||
enum Gameobjects
|
||||
{
|
||||
|
||||
GO_SLADRAN_ALTAR = 192518,
|
||||
GO_MOORABI_ALTAR = 192519,
|
||||
@@ -67,7 +68,6 @@ enum Gameobjects {
|
||||
GO_GALDARAH_DOOR3 = 192568,
|
||||
GO_BRIDGE = 193188,
|
||||
GO_COLLISION = 192633
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -820,7 +820,6 @@ public:
|
||||
void Reset()
|
||||
{
|
||||
WithRedDragonBlood = false;
|
||||
HarpoonerGUID = 0;
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* who)
|
||||
@@ -879,6 +878,12 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
if ((me->getFaction() == 35) && (!me->HasAura(SPELL_SUBDUED)))
|
||||
{
|
||||
HarpoonerGUID = 0;
|
||||
me->DisappearAndDie();
|
||||
}
|
||||
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
|
||||
|
||||
@@ -275,56 +275,6 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
/*######
|
||||
## npc_mcgoyver
|
||||
######*/
|
||||
|
||||
#define GOSSIP_ITEM_MG_I "Walt sent me to pick up some dark iron ingots."
|
||||
#define GOSSIP_ITEM_MG_II "Yarp."
|
||||
|
||||
enum eMcGoyver
|
||||
{
|
||||
QUEST_WE_CAN_REBUILD_IT = 11483,
|
||||
|
||||
SPELL_CREATURE_DARK_IRON_INGOTS = 44512,
|
||||
SPELL_TAXI_EXPLORERS_LEAGUE = 44280,
|
||||
|
||||
GOSSIP_TEXTID_MCGOYVER = 12193
|
||||
};
|
||||
|
||||
class npc_mcgoyver : public CreatureScript
|
||||
{
|
||||
public:
|
||||
npc_mcgoyver() : CreatureScript("npc_mcgoyver") { }
|
||||
|
||||
bool OnGossipHello(Player* player, Creature* creature)
|
||||
{
|
||||
if (player->GetQuestStatus(QUEST_WE_CAN_REBUILD_IT) == QUEST_STATUS_INCOMPLETE)
|
||||
player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_MG_I, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
|
||||
|
||||
player->SEND_GOSSIP_MENU(player->GetGossipTextId(creature), creature->GetGUID());
|
||||
return true;
|
||||
}
|
||||
|
||||
bool OnGossipSelect(Player* player, Creature* creature, uint32 /*sender*/, uint32 action)
|
||||
{
|
||||
player->PlayerTalkClass->ClearMenus();
|
||||
switch (action)
|
||||
{
|
||||
case GOSSIP_ACTION_INFO_DEF+1:
|
||||
player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_MG_II, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+2);
|
||||
player->SEND_GOSSIP_MENU(GOSSIP_TEXTID_MCGOYVER, creature->GetGUID());
|
||||
player->CastSpell(player, SPELL_CREATURE_DARK_IRON_INGOTS, true);
|
||||
break;
|
||||
case GOSSIP_ACTION_INFO_DEF+2:
|
||||
player->CastSpell(player, SPELL_TAXI_EXPLORERS_LEAGUE, true);
|
||||
player->CLOSE_GOSSIP_MENU();
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
};
|
||||
|
||||
/*######
|
||||
## npc_daegarn
|
||||
######*/
|
||||
@@ -435,6 +385,5 @@ void AddSC_howling_fjord()
|
||||
new npc_apothecary_hanes;
|
||||
new npc_plaguehound_tracker;
|
||||
new npc_razael_and_lyana;
|
||||
new npc_mcgoyver;
|
||||
new npc_daegarn;
|
||||
}
|
||||
|
||||
@@ -3634,6 +3634,45 @@ class spell_gen_orc_disguise : public SpellScriptLoader
|
||||
}
|
||||
};
|
||||
|
||||
enum WhisperGulchYoggSaronWhisper
|
||||
{
|
||||
SPELL_YOGG_SARON_WHISPER_DUMMY = 29072
|
||||
};
|
||||
|
||||
class spell_gen_whisper_gulch_yogg_saron_whisper : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_gen_whisper_gulch_yogg_saron_whisper() : SpellScriptLoader("spell_gen_whisper_gulch_yogg_saron_whisper") { }
|
||||
|
||||
class spell_gen_whisper_gulch_yogg_saron_whisper_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_gen_whisper_gulch_yogg_saron_whisper_AuraScript);
|
||||
|
||||
bool Validate(SpellInfo const* /*spellInfo*/)
|
||||
{
|
||||
if (!sSpellMgr->GetSpellInfo(SPELL_YOGG_SARON_WHISPER_DUMMY))
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
void HandleEffectPeriodic(AuraEffect const* /*aurEff*/)
|
||||
{
|
||||
PreventDefaultAction();
|
||||
GetTarget()->CastSpell((Unit*)NULL, SPELL_YOGG_SARON_WHISPER_DUMMY, true);
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
OnEffectPeriodic += AuraEffectPeriodicFn(spell_gen_whisper_gulch_yogg_saron_whisper_AuraScript::HandleEffectPeriodic, EFFECT_0, SPELL_AURA_PERIODIC_DUMMY);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
{
|
||||
return new spell_gen_whisper_gulch_yogg_saron_whisper_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
void AddSC_generic_spell_scripts()
|
||||
{
|
||||
new spell_gen_absorb0_hitlimit1();
|
||||
@@ -3722,4 +3761,5 @@ void AddSC_generic_spell_scripts()
|
||||
new spell_gen_two_forms();
|
||||
new spell_gen_darkflight();
|
||||
new spell_gen_orc_disguise();
|
||||
new spell_gen_whisper_gulch_yogg_saron_whisper();
|
||||
}
|
||||
|
||||
@@ -1257,10 +1257,10 @@ public:
|
||||
if (creature->isTrainer())
|
||||
player->ADD_GOSSIP_ITEM(GOSSIP_ICON_TRAINER, GOSSIP_TEXT_TRAIN, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_TRAIN);
|
||||
|
||||
if (creature->isCanTrainingAndResetTalentsOf(player))
|
||||
if (player->getClass() == CLASS_ROGUE)
|
||||
player->ADD_GOSSIP_ITEM(GOSSIP_ICON_TRAINER, GOSSIP_HELLO_ROGUE1, GOSSIP_SENDER_MAIN, GOSSIP_OPTION_UNLEARNTALENTS);
|
||||
|
||||
if (player->GetSpecsCount() == 1 && creature->isCanTrainingAndResetTalentsOf(player) && player->getLevel() >= sWorld->getIntConfig(CONFIG_MIN_DUALSPEC_LEVEL))
|
||||
if (player->GetSpecsCount() == 1 && player->getLevel() >= sWorld->getIntConfig(CONFIG_MIN_DUALSPEC_LEVEL))
|
||||
player->ADD_GOSSIP_ITEM(GOSSIP_ICON_TRAINER, GOSSIP_HELLO_ROGUE3, GOSSIP_SENDER_MAIN, GOSSIP_OPTION_LEARNDUALSPEC);
|
||||
|
||||
if (player->getClass() == CLASS_ROGUE && player->getLevel() >= 24 && !player->HasItemCount(17126) && !player->GetQuestRewardStatus(6681))
|
||||
|
||||
Reference in New Issue
Block a user