ArcEmu All In One
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Á¦°¡ ÇÏÀÌÀß Á¦À̳ª lua¸¦ ¸¸µé¾ú´Âµ¥ cpp¿¡ ÀÌ¹Ì Á¸ÀçÇÏ´Â ½ºÅ©¸³Æ®¿©¼­ Áö¿ì·Á°í Çϴµ¥ ½ºÆçºÎºÐÀº ¾î¶²°ÇÁö ¸ð¸£°Ú¾î¿ä

Go down

Á¦°¡ ÇÏÀÌÀß Á¦À̳ª lua¸¦ ¸¸µé¾ú´Âµ¥ cpp¿¡ ÀÌ¹Ì Á¸ÀçÇÏ´Â ½ºÅ©¸³Æ®¿©¼­ Áö¿ì·Á°í Çϴµ¥ ½ºÆçºÎºÐÀº ¾î¶²°ÇÁö ¸ð¸£°Ú¾î¿ä Empty Á¦°¡ ÇÏÀÌÀß Á¦À̳ª lua¸¦ ¸¸µé¾ú´Âµ¥ cpp¿¡ ÀÌ¹Ì Á¸ÀçÇÏ´Â ½ºÅ©¸³Æ®¿©¼­ Áö¿ì·Á°í Çϴµ¥ ½ºÆçºÎºÐÀº ¾î¶²°ÇÁö ¸ð¸£°Ú¾î¿ä

¿Ã¸®±â by gunwoo11 2009-02-28, 7:50 pm

//Jaina Proudmoore AI & GS
#define CN_JAINA_PROUDMOORE 17772

class JainaProudmooreAI : public CreatureAIScript
{
public:
ADD_CREATURE_FACTORY_FUNCTION(JainaProudmooreAI);

JainaProudmooreAI(Creature* pCreature) : CreatureAIScript(pCreature)
{
HyjalPhase[_unit->GetInstanceID()] = HYJAL_PHASE_NOT_STARTED;
_unit->SetUInt32Value(UNIT_NPC_FLAGS, 1);
}
};

class JainaProudmooreGS : public GossipScript
{
public:
void GossipHello(Object * pObject, Player* Plr, bool AutoSend)
{
GossipMenu *Menu;
objmgr.CreateGossipMenuForPlayer(&Menu, pObject->GetGUID(), 1, Plr);

switch(HyjalPhase[pObject->GetInstanceID()])
{
case HYJAL_PHASE_NOT_STARTED:
Menu->AddItem(0, "We are ready to defend the Alliance base.", 1);
break;

case HYJAL_PHASE_RAGE_WINTERCHILL_COMPLETE:
Menu->AddItem(0, "We are ready to defend the Alliance base.", 1);
break;

case HYJAL_PHASE_ANETHERON_COMPLETE:
Menu->AddItem(0, "The defenses are holding up: we can continue.", 1);
break;
}

if(AutoSend)
Menu->SendTo(Plr);
}

void GossipSelectOption(Object * pObject, Player* Plr, uint32 Id, uint32 IntId, const char * Code)
{
Creature *creature = static_cast<Creature*>(pObject);

switch(HyjalPhase[pObject->GetInstanceID()])
{
case HYJAL_PHASE_NOT_STARTED:
case HYJAL_PHASE_RAGE_WINTERCHILL_COMPLETE:
case HYJAL_PHASE_ANETHERON_COMPLETE:
break;
}

creature->SetUInt32Value(UNIT_NPC_FLAGS, 0);
}

void GossipEnd(Object * pObject, Player* Plr) { GossipScript::GossipEnd(pObject, Plr); }
void Destroy() { delete this; }
};

¿©±â¼­ ¾îµð±îÁö¸¸ Áö¿ö¾ß ¿þÀ̺ê ÅؽºÆ®´Â Áö¿öÁöÁö¾Ê°í ½ºÆ縸 lua·Î Àû¿ëÇÒ¼öÀְԵdzª¿ä? Á¦°¡ cpp´Â óÀ½ÀÌ¶ó ¤¾¤§¤§

gunwoo11

°Ô½Ã¹° °¹¼ö : 45
Registration date : 2009-01-18

À§·Î Go down

À§·Î


 
Permissions in this forum:
´ä±ÛÀ» ¿Ã¸± ¼ö ¾ø½À´Ï´Ù