[DiscordArchive] Isn’t it a fresh npc ?
[DiscordArchive] Isn’t it a fresh npc ?
Archived author: Seyden • Posted: 2023-05-26T01:41:29.485000+00:00
Original source
Isn’t it a fresh npc ?
Archived author: Malcrom • Posted: 2023-05-26T01:41:32.700000+00:00
Original source
Maybe that is why blizz used demon creator
Archived author: Malcrom • Posted: 2023-05-26T01:41:50.002000+00:00
Original source
yeah summoned again
Archived author: Seyden • Posted: 2023-05-26T01:42:41.696000+00:00
Original source
So if he is summoned again
Archived author: Seyden • Posted: 2023-05-26T01:42:46.413000+00:00
Original source
There has to be a summoner
Archived author: Malcrom • Posted: 2023-05-26T01:42:55.496000+00:00
Original source
yes
Archived author: Malcrom • Posted: 2023-05-26T01:43:03.333000+00:00
Original source
but it's not the player
Archived author: Malcrom • Posted: 2023-05-26T01:43:23.403000+00:00
Original source
```cpp
void JustAppeared() override
{
if (me->GetEntry() == NPC_ALLIANCE_SPARING_PARTNER)
{
SetEquipmentSlots(false, EQUIPMENT_SWORD, EQUIP_NO_CHANGE, EQUIP_NO_CHANGE);
_summonSpell = SPELL_SUMMON_COLE;
_path = PATH_ALLIANCE_SPARING_PARTNER;
_actorId = ACTOR_ID_ALLIANCE;
_actorIndex = 0;
}
else if (me->GetEntry() == NPC_HORDE_SPARING_PARTNER)
{
SetEquipmentSlots(false, EQUIPMENT_AXE, EQUIP_NO_CHANGE, EQUIP_NO_CHANGE);
_summonSpell = SPELL_SUMMON_THROG;
_path = PATH_HORDE_SPARING_PARTNER;
_actorId = ACTOR_ID_HORDE;
_actorIndex = 1;
}
_events.ScheduleEvent(EVENT_MOVE_TO_A_POSITION, 2s);
_events.ScheduleEvent(EVENT_CHECK_FOR_PLAYER, 1s);
}
void IsSummonedBy(WorldObject* summonerWO) override
{
Unit* summoner = summonerWO->ToUnit();
if (!summoner || !summoner->IsPlayer())
return;
_playerGUID = summoner->GetGUID();
}
```
Archived author: Seyden • Posted: 2023-05-26T01:43:37.767000+00:00
Original source
Who is it then
Archived author: Malcrom • Posted: 2023-05-26T01:43:43.324000+00:00
Original source
IsSummonedBy is called when player cast spell on self