Skip to content
Permalink
Browse files

Scripts/The Barrens: Beaten Corpse (#24124)

* Scripts/The Barrens: Beaten Corpse

* Rename 9999_99_99_99_world.sql to 2020_02_01_00_world.sql

Co-authored-by: Giacomo Pozzoni <giacomopoz@gmail.com>
  • Loading branch information
Sorikoff and jackpoz committed Feb 1, 2020
1 parent c86d440 commit 74d19691a56355c5932913ee7e5553d5125b1126
@@ -0,0 +1,4 @@
UPDATE `creature_template` SET `AIName`= 'SmartAI',`ScriptName`="" WHERE `entry`=10668;
DELETE FROM `smart_scripts` WHERE `entryorguid`=10668 AND `source_type`=0;
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(10668,0,0,0,62,0,100,0,2871,0,0,0,33,10668,0,0,0,0,0,7,0,0,0,0,0,0,0,'Beaten Corpse - On gossip select - Credit quest');
@@ -40,42 +40,6 @@ EndContentData */
#include "SpellInfo.h"
#include "TemporarySummon.h"

/*######
## npc_beaten_corpse
######*/

enum BeatenCorpse
{
GOSSIP_OPTION_ID_BEATEN_CORPSE = 0,
GOSSIP_MENU_OPTION_INSPECT_BODY = 2871
};

class npc_beaten_corpse : public CreatureScript
{
public:
npc_beaten_corpse() : CreatureScript("npc_beaten_corpse") { }

struct npc_beaten_corpseAI : public ScriptedAI
{
npc_beaten_corpseAI(Creature* creature) : ScriptedAI(creature) { }

bool GossipSelect(Player* player, uint32 menuId, uint32 gossipListId) override
{
if (menuId == GOSSIP_MENU_OPTION_INSPECT_BODY && gossipListId == GOSSIP_OPTION_ID_BEATEN_CORPSE)
{
CloseGossipMenuFor(player);
player->TalkedToCreature(me->GetEntry(), me->GetGUID());
}
return false;
}
};

CreatureAI* GetAI(Creature* creature) const override
{
return new npc_beaten_corpseAI(creature);
}
};

/*######
# npc_gilthares
######*/
@@ -655,7 +619,6 @@ class npc_wizzlecrank_shredder : public CreatureScript

void AddSC_the_barrens()
{
new npc_beaten_corpse();
new npc_gilthares();
new npc_taskmaster_fizzule();
new npc_twiggy_flathead();

0 comments on commit 74d1969

Please sign in to comment.
You can’t perform that action at this time.