1234 {
1236
1238 if (roll <= 50)
1240 else if (roll <= 83)
1242 else
1244
1249
1250 if (!wilhelm || !apple || !drostan)
1251 return;
1252
1253 switch (ev)
1254 {
1256 {
1259
1260 if (!bird || !crunchy)
1261 ;
1262 else
1263 {
1268
1273
1274 break;
1275 }
1276 [[fallthrough]];
1277 }
1279 {
1283 break;
1284 }
1286 {
1292
1293
1294 break;
1295 }
1296 }
1297 }
uint32 urand(uint32 min, uint32 max)
Definition: Random.cpp:44
std::uint8_t uint8
Definition: Define.h:109
std::uint32_t uint32
Definition: Define.h:107
@ SPELL_BIRD_FALL
Definition: zone_sholazar_basin.cpp:1203
@ EVENT_HIT
Definition: zone_sholazar_basin.cpp:1206
@ SPELL_MISS_APPLE
Definition: zone_sholazar_basin.cpp:1200
@ SAY_DROSTAN_REPLY_MISS
Definition: zone_sholazar_basin.cpp:1211
@ SPELL_MISS_BIRD_APPLE
Definition: zone_sholazar_basin.cpp:1201
@ NPC_DROSTAN
Definition: zone_sholazar_basin.cpp:1195
@ SAY_WILHELM_HIT
Definition: zone_sholazar_basin.cpp:1210
@ NPC_CRUNCHY
Definition: zone_sholazar_basin.cpp:1196
@ SPELL_APPLE_FALL
Definition: zone_sholazar_basin.cpp:1202
@ SAY_WILHELM_MISS
Definition: zone_sholazar_basin.cpp:1209
@ EVENT_MISS_BIRD
Definition: zone_sholazar_basin.cpp:1207
@ EVENT_MISS
Definition: zone_sholazar_basin.cpp:1205
@ NPC_THICKBIRD
Definition: zone_sholazar_basin.cpp:1197
@ NPC_APPLE
Definition: zone_sholazar_basin.cpp:1194
@ SPELL_HIT_APPLE
Definition: zone_sholazar_basin.cpp:1199
void Talk(uint8 id, WorldObject const *whisperTarget=nullptr, Milliseconds delay=0s)
Causes the creature to talk/say the text assigned to their entry in the creature_text database table.
Definition: CreatureAI.cpp:50
Definition: Creature.h:46
CreatureAI * AI() const
Definition: Creature.h:143
Player * ToPlayer()
Definition: Object.h:198
Creature * ToCreature()
Definition: Object.h:202
float GetMapWaterOrGroundLevel(float x, float y, float z, float *ground=nullptr) const
Definition: Object.cpp:3126
Creature * FindNearestCreature(uint32 entry, float range, bool alive=true) const
Definition: Object.cpp:2446
float GetPositionZ() const
Definition: Position.h:119
float GetPositionX() const
Definition: Position.h:117
float GetPositionY() const
Definition: Position.h:118
Definition: Player.h:1064
static void Kill(Unit *killer, Unit *victim, bool durabilityLoss=true, WeaponAttackType attackType=BASE_ATTACK, SpellInfo const *spellProto=nullptr, Spell const *spell=nullptr)
Definition: Unit.cpp:17658
MotionMaster * GetMotionMaster()
Definition: Unit.h:1601
SpellCastResult CastSpell(SpellCastTargets const &targets, SpellInfo const *spellInfo, CustomSpellValues const *value, TriggerCastFlags triggerFlags=TRIGGERED_NONE, Item *castItem=nullptr, AuraEffect const *triggeredByAura=nullptr, ObjectGuid originalCaster=ObjectGuid::Empty)
Definition: Unit.cpp:1168
void MovePoint(uint32 id, const Position &pos, bool generatePath=true, bool forceDestination=true)
Definition: MotionMaster.h:211
Unit * GetHitUnit()
Definition: SpellScript.cpp:448
Unit * GetCaster()
Definition: SpellScript.cpp:401