165{
167
168
170 {
173 return;
174 }
175
176
178
179 if (unit)
181 else if (gob)
183
185 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction: Invoker: {} ({})", tempInvoker->GetName(), tempInvoker->GetGUID().ToString());
186
188
191 if (unit)
192 invoker = unit;
193 else if (gob)
194 invoker = gob;
195
197
199 {
201 {
204
206 {
207 if (
IsCreature((target)) && !target->ToCreature()->IsPet())
208 {
210 {
213 }
214 else
216 break;
217 }
219 {
222 break;
223 }
224 }
225
226 if (!talkTarget)
228
229 if (!talker)
230 break;
231
233 {
235 break;
236 }
237
242
245 break;
246 }
248 {
250 {
254 {
257 }
258
259 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction:: SMART_ACTION_SIMPLE_TALK: talker: {} ({}), textGroupId: {}",
261 }
262 break;
263 }
265 {
267 {
269 {
270 target->ToUnit()->HandleEmoteCommand(e.
action.
emote.emote);
271 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction:: SMART_ACTION_PLAY_EMOTE: target: {} ({}), emote: {}",
272 target->GetName(), target->GetGUID().ToString(), e.
action.
emote.emote);
273 }
274 }
275 break;
276 }
278 {
280 {
282 {
285 else
287 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction:: SMART_ACTION_SOUND: target: {} ({}), sound: {}, onlyself: {}",
289 }
290 }
291 break;
292 }
294 {
302 for (unsigned int sound : sounds)
303 {
304 if (sound)
305 {
306 temp[count] = sound;
307 ++count;
308 }
309 }
310
311 if (count == 0)
312 {
313 break;
314 }
315
317 {
319 {
322 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction:: SMART_ACTION_RANDOM_SOUND: target: {} ({}), sound: {}, onlyself: {}",
324 }
325 }
326
327 break;
328 }
330 {
332
334 {
336 {
338
340 {
342 if (
Player* player = i->GetSource())
343 {
345 {
347 {
349 targets.push_back(player);
350 }
351 else
352 targets.push_back(player);
353 }
354 }
355 }
356 }
357 }
358 else
360
361 if (!targets.empty())
362 {
364 {
366 {
368 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction:: SMART_ACTION_MUSIC: target: {} ({}), sound: {}, onlySelf: {}, type: {}",
370 }
371 }
372 }
373 break;
374 }
376 {
378
380 {
382 {
384
386 {
388 if (
Player* player = i->GetSource())
389 {
391 {
393 {
395 targets.push_back(player);
396 }
397 else
398 targets.push_back(player);
399 }
400 }
401 }
402 }
403 }
404 else
406
407 if (targets.empty())
408 break;
409
417 for (unsigned int sound : sounds)
418 {
419 if (sound)
420 {
421 temp[count] = sound;
422 ++count;
423 }
424 }
425
426 if (count == 0)
427 {
428 break;
429 }
430
432 {
434 {
437 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction:: SMART_ACTION_RANDOM_MUSIC: target: {} ({}), sound: {}, onlyself: {}, type: {}",
439 }
440 }
441
442 break;
443 }
445 {
447 {
449 {
451 {
453 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_SET_FACTION: Creature entry {}, GuidLow {} set faction to {}",
455 }
456 else
457 {
459 {
460 if (target->ToCreature()->GetFaction() != ci->faction)
461 {
462 target->ToCreature()->SetFaction(ci->faction);
463 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_SET_FACTION: Creature entry {}, GuidLow {} set faction to {}",
464 target->GetEntry(), target->GetGUID().ToString(), ci->faction);
465 }
466 }
467 }
468 }
469 }
470 break;
471 }
473 {
475 {
477 continue;
478
480 {
481
483 {
485 {
488 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_MORPH_TO_ENTRY_OR_MODEL: Creature entry {}, GuidLow {} set displayid to {}",
490 }
491 }
492
493 else
494 {
496 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_MORPH_TO_ENTRY_OR_MODEL: Creature entry {}, GuidLow {} set displayid to {}",
498 }
499 }
500 else
501 {
502 target->ToCreature()->DeMorph();
503 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_MORPH_TO_ENTRY_OR_MODEL: Creature entry {}, GuidLow {} demorphs.",
504 target->GetEntry(), target->GetGUID().ToString());
505 }
506 }
507 break;
508 }
510 {
512 {
514 {
515 target->ToPlayer()->FailQuest(e.
action.
quest.quest);
516 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_FAIL_QUEST: Player guidLow {} fails quest {}",
517 target->GetGUID().ToString(), e.
action.
quest.quest);
518 }
519 }
520 break;
521 }
523 {
525 {
527 {
529 {
531 {
532 if (player->CanTakeQuest(q, true))
533 {
535 {
537 menu.SendQuestGiverQuestDetails(q,
me->
GetGUID(),
true);
538 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_OFFER_QUEST: Player guidLow {} - offering quest {}",
540 }
541 }
542 }
543 else
544 {
545 player->AddQuestAndCheckCompletion(q, nullptr);
546 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_OFFER_QUEST: Player guidLow {} - quest {} added",
548 }
549 }
550 }
551 }
552 break;
553 }
555 {
557 {
559 continue;
560
562 }
563 break;
564 }
566 {
567 std::vector<uint32> emotes;
569 std::back_inserter(emotes), [](
uint32 emote) { return emote != 0; });
570
572 {
574 {
576 target->ToUnit()->HandleEmoteCommand(emote);
577 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_RANDOM_EMOTE: Creature guidLow {} handle random emote {}",
578 target->GetGUID().ToString(), emote);
579 }
580 }
581 break;
582 }
584 {
586 break;
587
589 {
591 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction:: SMART_ACTION_THREAT_ALL_PCT: Creature {} modify threat for unit {}, value {}",
593 }
594 break;
595 }
597 {
599 break;
600
602 {
604 {
606 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_THREAT_SINGLE_PCT: Creature {} modify threat for unit {}, value {}",
608 }
609 }
610 break;
611 }
613 {
615 {
616
618 if (
Vehicle* vehicle = target->ToUnit()->GetVehicleKit())
619 for (
auto & Seat : vehicle->
Seats)
621 player->AreaExploredOrEventHappens(e.action.quest.quest);
622
624 {
625 target->ToPlayer()->AreaExploredOrEventHappens(e.
action.
quest.quest);
626
627 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_CALL_AREAEXPLOREDOREVENTHAPPENS: Player guidLow {} credited quest {}",
628 target->GetGUID().ToString(), e.
action.
quest.quest);
629 }
630 }
631 break;
632 }
634 {
635 if (targets.empty())
636 break;
637
639
642
645
646 bool failedSpellCast = false, successfulSpellCast = false;
647
649 {
650
653
655 continue;
656
657 if (caster && caster !=
me)
658 {
660 }
662 {
663
665 continue;
666
667
670 break;
671
672
674 continue;
675
676
679
685
687 bool isWithinMeleeRange = distanceToTarget <= meleeRange;
690
693
694
695 if (isWithinLOSInMap && isWithinMeleeRange && isRangedAttack && isTargetRooted && canCastSpell && !
me->
IsVehicle())
696 {
697 failedSpellCast = true;
698
700 continue;
701
702 float minDistance = std::max(meleeRange, spellMinRange) - distanceToTarget +
NOMINAL_MELEE_RANGE;
704 continue;
705 }
706
707 if (distanceToTarget > spellMaxRange && isWithinLOSInMap)
708 {
709 failedSpellCast = true;
710
712 continue;
713
716
717 continue;
718 }
719 else if (distanceToTarget < spellMinRange || !(isWithinLOSInMap || isSpellIgnoreLOS))
720 {
721 failedSpellCast = true;
722
724 continue;
725
729 continue;
730 }
731
734 {
737 else
739 }
740
743
745 {
750 }
751
752 if (spellCastFailed)
753 failedSpellCast = true;
754 else
755 successfulSpellCast = true;
756
757 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_CAST: Unit {} casts spell {} on target {} with castflags {}",
759 }
760 }
761
762
763 if (failedSpellCast && !successfulSpellCast)
764 {
766
767 return;
768 }
769
770 break;
771 }
773 {
774 if (targets.empty())
775 break;
776
779
782 {
784 {
786 }
787 else
788 {
790 }
791 }
792
794 {
796 if (!uTarget)
797 continue;
798
800 {
802 {
804 }
805
807 }
808 }
809 break;
810 }
812 {
813
815 if (!tempLastInvoker)
816 break;
817
818 if (targets.empty())
819 break;
820
823
825 {
827 continue;
828
829 if (!
IsUnit(tempLastInvoker))
830 continue;
831
833 {
835 {
837 }
838
841 {
843 {
845 }
846 else
847 {
849 }
850 }
851
853 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_INVOKER_CAST: Invoker {} casts spell {} on target {} with castflags {}",
855 }
856 else
857 {
858 LOG_DEBUG(
"scripts.ai",
"Spell {} not cast because it has flag SMARTCAST_AURA_NOT_PRESENT and the target {} already has the aura",
860 }
861 }
862 break;
863 }
865 {
867 {
869 {
871 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_ADD_AURA: Adding aura {} to unit {}",
873 }
874 }
875 break;
876 }
878 {
880 {
882 {
884
885
887 {
889 }
890
892 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction:: SMART_ACTION_ACTIVATE_GOBJECT. Gameobject {} activated",
go->
GetGUID().
ToString());
893 }
894 }
895
896 break;
897 }
899 {
901 {
903 {
904 target->ToGameObject()->ResetDoorOrButton();
905 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_RESET_GOBJECT. Gameobject {} (entry: {}) reset",
906 target->GetGUID().ToString(), target->GetEntry());
907 }
908 }
909 break;
910 }
912 {
914 {
916 {
918 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_SET_EMOTE_STATE. Unit {} set emotestate to {}",
919 target->GetGUID().ToString(), e.
action.
emote.emote);
920 }
921 }
922 break;
923 }
925 {
927 {
929 {
931 {
933 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_SET_UNIT_FLAG. Unit {} added flag {} to UNIT_FIELD_FLAGS",
935 }
936 else
937 {
939 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_SET_UNIT_FLAG. Unit {} added flag {} to UNIT_FIELD_FLAGS_2",
941 }
942 }
943 }
944 break;
945 }
947 {
949 {
951 {
953 {
955 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_REMOVE_UNIT_FLAG. Unit {} removed flag {} to UNIT_FIELD_FLAGS",
957 }
958 else
959 {
961 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction:: SMART_ACTION_REMOVE_UNIT_FLAG. Unit {} removed flag {} to UNIT_FIELD_FLAGS_2",
963 }
964 }
965 }
966 break;
967 }
969 {
971 break;
972
974 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction:: SMART_ACTION_AUTO_ATTACK: Creature: {} bool on = {}",
976 break;
977 }
979 {
981 break;
982
985 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction:: SMART_ACTION_ALLOW_COMBAT_MOVEMENT: Creature {} bool on = {}",
987 break;
988 }
990 {
992 break;
993
995 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction:: SMART_ACTION_SET_EVENT_PHASE: Creature {} set event phase {}",
997 break;
998 }
1000 {
1002 break;
1003
1006 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction:: SMART_ACTION_INC_EVENT_PHASE: Creature {} inc event phase by {}, "
1008 break;
1009 }
1011 {
1013 break;
1014
1017 if (target->ToCreature()->IsAIEnabled)
1018 target->ToCreature()->AI()->EnterEvadeMode();
1019
1020 break;
1021 }
1023 {
1024
1026 break;
1027
1030 {
1033 }
1034 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction:: SMART_ACTION_FLEE_FOR_ASSIST: Creature {} DoFleeToGetAssistance",
me->
GetGUID().
ToString());
1035 break;
1036 }
1038 {
1040 break;
1041
1043 break;
1044 }
1046 {
1048 {
1050 continue;
1051
1053
1056 {
1058 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction: SMART_ACTION_CALL_GROUPEVENTHAPPENS: Player {}, group credit for quest {}",
1060 }
1061
1062
1064 {
1065 for (
auto& Seat : vehicle->
Seats)
1066 {
1068 {
1070 }
1071 }
1072 }
1073 }
1074 break;
1075 }
1077 {
1079 {
1081 continue;
1082
1084 {
1086 {
1089 }
1090 else
1092 }
1093 else
1094 target->ToUnit()->RemoveAllAuras();
1095
1096 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction: SMART_ACTION_REMOVEAURASFROMSPELL: Unit {}, spell {}",
1098 }
1099 break;
1100 }
1102 {
1104 break;
1105
1107 {
1109 break;
1110 }
1111
1113 {
1115 {
1118 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction: SMART_ACTION_FOLLOW: Creature {} following target {}",
1120 break;
1121 }
1122 }
1123 break;
1124 }
1126 {
1128 break;
1129
1130 std::vector<uint32> phases;
1132 std::back_inserter(phases), [](
uint32 phase) { return phase != 0; });
1133
1136 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction: SMART_ACTION_RANDOM_PHASE: Creature {} sets event phase to {}",
1138 break;
1139 }
1141 {
1143 break;
1144
1147 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction: SMART_ACTION_RANDOM_PHASE_RANGE: Creature {} sets event phase to {}",
1149 break;
1150 }
1152 {
1154 {
1156 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction: SMART_ACTION_CALL_KILLEDMONSTER: (trigger == true) Player {}, Killcredit: {}",
1158 }
1160 {
1162 break;
1163
1165 {
1167 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction: SMART_ACTION_CALL_KILLEDMONSTER: Player {}, Killcredit: {}",
1169 }
1170 }
1171 else
1172 {
1174 {
1176 continue;
1177
1179 if (!player)
1180 continue;
1181
1183 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction: SMART_ACTION_CALL_KILLEDMONSTER: Player {}, Killcredit: {}",
1185 }
1186 }
1187 break;
1188 }
1190 {
1192 if (!obj)
1193 obj = unit;
1194
1195 if (!obj)
1196 break;
1197
1199 if (!instance)
1200 {
1201 LOG_ERROR(
"scripts.ai.sai",
"SmartScript: Event {} attempt to set instance data without instance script. EntryOrGuid {}", e.
GetEventType(), e.
entryOrGuid);
1202 break;
1203 }
1204
1206 {
1207 case 0:
1208 {
1211 } break;
1212 case 1:
1213 {
1216 } break;
1217 default:
1218 {
1219 break;
1220 }
1221 }
1222 break;
1223 }
1225 {
1227 if (!obj)
1228 obj = unit;
1229
1230 if (!obj)
1231 break;
1232
1234 if (!instance)
1235 {
1237 break;
1238 }
1239
1240 if (targets.empty())
1241 break;
1242
1244 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction: SMART_ACTION_SET_INST_DATA64: Field: {}, data: {}",
1246 break;
1247 }
1249 {
1252 target->ToCreature()->UpdateEntry(e.action.updateTemplate.creature, target->ToCreature()->GetCreatureData(), e.action.updateTemplate.updateLevel != 0);
1253 break;
1254 }
1256 {
1258 {
1260 {
1262 {
1263
1265 {
1266 me->KillSelf();
1267 LOG_DEBUG("sql.sql", "SmartScript::ProcessAction: SMART_ACTION_DIE: Creature {}", me->GetGUID().ToString());
1268 }
1270 }
1271 }
1273 {
1276 }
1277 break;
1278 }
1280 {
1281 if (targets.empty())
1282 break;
1283
1285 {
1288
1291 if (
IsPlayer(unit) && !unit->ToPlayer()->isDead())
1292 {
1294 }
1295 }
1296 else
1297 {
1299 {
1301 {
1302 target->ToCreature()->SetInCombatWithZone();
1303 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction: SMART_ACTION_SET_IN_COMBAT_WITH_ZONE: Creature {}, target: {}",
1305 }
1306 }
1307 }
1308
1309 break;
1310 }
1312 {
1314 {
1316 {
1319 {
1322 }
1323 LOG_DEBUG(
"scripts.ai",
"SmartScript::ProcessAction: SMART_ACTION_CALL_FOR_HELP: Creature {}, target: {}",
1325 }
1326 }
1327 break;
1328 }
1330 {
1332 {
1334 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction: SMART_ACTION_SET_SHEATH: Creature {}, State: {}",
1336 }
1337 break;
1338 }
1340 {
1342 {
1344 {
1346 LOG_ERROR(
"sql.sql",
"SmartScript: SMART_ACTION_FORCE_DESPAWN has removeObjectFromWorld set. delay and forceRespawnTimer ignored.");
1347
1349 creature->AddObjectToRemoveList();
1352 }
1353 else
1354 {
1356
1357
1358 if (despawnDelay <= 0ms)
1359 despawnDelay = 1ms;
1360
1363 creature->DespawnOrUnsummon(despawnDelay, forceRespawnTimer);
1366 }
1367 }
1368
1369 break;
1370 }
1372 {
1374 {
1379 }
1380 break;
1381 }
1383 {
1385 {
1387 continue;
1388
1390 {
1392 {
1395 }
1396 else
1398 }
1399 else
1400 target->ToUnit()->Dismount();
1401 }
1402 break;
1403 }
1405 {
1407 {
1409 {
1411 if (!ai)
1412 continue;
1413
1416 else
1418 }
1419 }
1420 break;
1421 }
1423 {
1425 {
1427 {
1429
1431 {
1434 else
1436 }
1437 else
1439 }
1441 {
1443
1445 {
1448 else
1450 }
1451 else
1453 }
1454 }
1455 break;
1456 }
1458 {
1460 break;
1461
1462 float x, y, z;
1465 break;
1466 }
1468 {
1470 break;
1471
1473 break;
1474 }
1476 {
1479 target->ToUnit()->SetVisible(e.action.visibility.state);
1480
1481 break;
1482 }
1484 {
1486 target->setActive(e.action.setActive.state);
1487 break;
1488 }
1490 {
1492 break;
1493
1494 if (targets.empty())
1495 break;
1496
1497
1500 break;
1501 }
1503 {
1505 if (
Unit* unitTarget = target->ToUnit())
1506 unitTarget->AttackStop();
1507 break;
1508 }
1510 {
1514 if (!summoner)
1515 break;
1516
1518
1520 {
1525 {
1528 else
1531 {
1533 summon->AI()->AttackStart(unit);
1535 summon->AI()->AttackStart(
me);
1536 }
1537 }
1538 break;
1539 }
1540
1541 float x, y, z, o;
1543 {
1544 target->GetPosition(x, y, z, o);
1550 {
1552 summon->AI()->AttackStart(unit);
1554 summon->AI()->AttackStart(target->ToUnit());
1556 summon->AI()->AttackStart(
me);
1557 }
1558 }
1559
1561 break;
1562
1564 {
1566 summon->AI()->AttackStart(unit);
1568 summon->AI()->AttackStart(
me);
1569 }
1570 break;
1571 }
1573 {
1575 break;
1576
1577 if (!targets.empty())
1578 {
1579 float x, y, z, o;
1581 {
1582
1583
1584
1585
1586 target->GetPosition(x, y, z, o);
1593 else
1595 }
1596 }
1597
1599 break;
1600
1602 break;
1603 }
1605 {
1607 {
1609 continue;
1610
1611 Unit::Kill(target->ToUnit(), target->ToUnit());
1612 }
1613
1614 break;
1615 }
1617 {
1619 break;
1620 }
1622 {
1624 {
1626 continue;
1627
1629 }
1630 break;
1631 }
1633 {
1635 {
1637 continue;
1638
1640 }
1641 break;
1642 }
1644 {
1646 break;
1647 }
1649 {
1651 {
1656 }
1657 break;
1658 }
1660 {
1662 break;
1663
1665
1668
1669
1671 break;
1672 }
1674 {
1676 {
1678 {
1680 }
1681 }
1682
1683 break;
1684 }
1686 {
1688 break;
1689
1691 break;
1692 }
1694 {
1695 if (!targets.empty())
1696 {
1698 {
1700 {
1703 else
1704 LOG_ERROR(
"sql.sql",
"SmartScript: Action target for SMART_ACTION_SET_COUNTER is not using SmartAI, skipping");
1705 }
1707 {
1710 else
1711 LOG_ERROR(
"sql.sql",
"SmartScript: Action target for SMART_ACTION_SET_COUNTER is not using SmartGameObjectAI, skipping");
1712 }
1713 }
1714 }
1715 else
1717 break;
1718 }
1720 {
1722 break;
1723
1727
1729 {
1731 {
1733 break;
1734 }
1735 }
1736
1739
1744 break;
1745 }
1747 {
1749 break;
1750
1753 break;
1754 }
1756 {
1758 break;
1759
1764 break;
1765 }
1767 {
1769 break;
1770
1772 break;
1773 }
1775 {
1777 break;
1778
1780 {
1781 float randomOri =
frand(0.0f, 2 * M_PI);
1785 break;
1786 }
1787
1789 {
1794 break;
1795 }
1796
1798 {
1802 }
1804 {
1808 }
1809 else if (!targets.empty())
1810 {
1814 }
1815
1816 break;
1817 }
1819 {
1821 {
1823 continue;
1824
1826 }
1827 break;
1828 }
1830 {
1832 break;
1833
1835
1837
1839 {
1841 {
1845 trans->CalculatePassengerPosition(dest.x, dest.y, dest.z);
1846
1849
1850 break;
1851 }
1853 {
1855 {
1866 );
1867
1868 }
1869
1870 break;
1871 }
1872
1873 default:
1874 {
1875
1876 if (targets.empty())
1877 return;
1878 else
1880
1881 float x, y, z;
1883
1888
1891
1892 break;
1893 }
1894 }
1895
1896 break;
1897 }
1899 {
1901 {
1903 {
1905
1909 }
1910 }
1911
1912 break;
1913 }
1915 {
1917 {
1921 {
1922
1925 else
1927 }
1928 }
1929 break;
1930 }
1932 {
1935 target->ToPlayer()->PlayerTalkClass->SendCloseGossip();
1936 break;
1937 }
1939 {
1941 {
1943 {
1944 std::array<uint32, MAX_EQUIPMENT_ITEMS> slot;
1946 {
1948 if (!eInfo)
1949 {
1950 LOG_ERROR(
"sql.sql",
"SmartScript: SMART_ACTION_EQUIP uses non-existent equipment info id {} for creature {}", equipId,
npc->GetEntry());
1951 break;
1952 }
1953
1954 npc->SetCurrentEquipmentId(equipId);
1955
1956 std::copy(std::begin(eInfo->
ItemEntry), std::end(eInfo->
ItemEntry), std::begin(slot));
1957 }
1958 else
1960
1964 }
1965 }
1966 break;
1967 }
1969 {
1974
1979
1983
1987
1995 break;
1996 }
1999
2000
2003 break;
2006 break;
2008 {
2010 {
2012 {
2019 break;
2020 }
2022 {
2029 break;
2030 }
2031 }
2032
2033 break;
2034 }
2037 break;
2040 break;
2042 {
2044 break;
2045
2048
2050 if (
Creature* creature = target->ToCreature())
2051 if (
IsSmart(creature) && creature->GetVictim())
2053 creature->GetMotionMaster()->MoveChase(creature->GetVictim(), attackDistance, attackAngle);
2054
2055 break;
2056 }
2058 {
2060 {
2062 break;
2063 }
2064
2066 {
2068 {
2071 }
2073 {
2076 }
2077 }
2078 break;
2079 }
2081 {
2084 target->ToUnit()->ReplaceAllNpcFlags(
NPCFlags(e.action.unitFlag.flag));
2085 break;
2086 }
2088 {
2091 target->ToUnit()->SetNpcFlag(
NPCFlags(e.action.unitFlag.flag));
2092 break;
2093 }
2095 {
2098 target->ToUnit()->RemoveNpcFlag(
NPCFlags(e.action.unitFlag.flag));
2099 break;
2100 }
2102 {
2103 if (targets.empty())
2104 break;
2105
2107 GetTargets(casters,
CreateSmartEvent(
SMART_EVENT_UPDATE_IC, 0, 0, 0, 0, 0, 0, 0,
SMART_ACTION_NONE, 0, 0, 0, 0, 0, 0, (
SMARTAI_TARGETS)e.
action.
crossCast.
targetType, e.
action.
crossCast.
targetParam1, e.
action.
crossCast.
targetParam2, e.
action.
crossCast.
targetParam3, 0, 0), unit);
2108
2110 {
2112 continue;
2113
2115
2116 bool interruptedSpell = false;
2117
2119 {
2121 continue;
2122
2124 {
2126 {
2128 interruptedSpell = true;
2129 }
2130
2132 }
2133 else
2135 }
2136 }
2137 break;
2138 }
2140 {
2141 std::vector<uint32> actionLists;
2143 std::back_inserter(actionLists), [](
uint32 actionList) { return actionList != 0; });
2144
2147 {
2149 break;
2150 }
2151
2153 {
2155 {
2158 }
2160 {
2163 }
2164 }
2165 break;
2166 }
2168 {
2171 {
2173 break;
2174 }
2175
2177 {
2179 {
2182 }
2184 {
2187 }
2188 }
2189 break;
2190 }
2192 {
2195 target->ToPlayer()->ActivateTaxiPathTo(e.action.taxi.id);
2196 break;
2197 }
2199 {
2200 bool foundTarget = false;
2201
2203 {
2205 {
2206 foundTarget = true;
2207
2210 else
2212 }
2213 }
2214
2216 {
2219 else
2221 }
2222 break;
2223 }
2225 {
2228 target->ToUnit()->SetByteFlag(
UNIT_FIELD_BYTES_1, e.action.setunitByte.type, e.action.setunitByte.byte1);
2229 break;
2230 }
2232 {
2235 target->ToUnit()->RemoveByteFlag(
UNIT_FIELD_BYTES_1, e.action.delunitByte.type, e.action.delunitByte.byte1);
2236 break;
2237 }
2239 {
2242 target->ToUnit()->InterruptNonMeleeSpells(e.action.interruptSpellCasting.withDelayed != 0, e.action.interruptSpellCasting.spell_id, e.action.interruptSpellCasting.withInstant != 0);
2243 break;
2244 }
2246 {
2249 target->ToGameObject()->SendCustomAnim(e.action.sendGoCustomAnim.anim);
2250 break;
2251 }
2253 {
2257 break;
2258 }
2260 {
2264 break;
2265 }
2267 {
2271 break;
2272 }
2274 {
2276 {
2278 {
2283 }
2284
2285 break;
2286 }
2287
2288 if (targets.empty())
2289 break;
2290
2291
2293 {
2297 }
2298 else
2299 {
2302 {
2305 }
2306 }
2307
2308 break;
2309 }
2311 {
2314 target->ToGameObject()->SetLootState((
LootState)e.action.setGoLootState.state);
2315 break;
2316 }
2318 {
2321 target->ToGameObject()->SetGoState((
GOState)e.action.goState.state);
2322 break;
2323 }
2325 {
2327
2328 if (!ref)
2329 ref = unit;
2330
2331 if (!ref)
2332 break;
2333
2335 if (!storedTargets)
2336 break;
2337
2339 {
2341 {
2344 else
2345 LOG_ERROR(
"sql.sql",
"SmartScript: Action target for SMART_ACTION_SEND_TARGET_TO_TARGET is not using SmartAI, skipping");
2346 }
2348 {
2351 else
2352 LOG_ERROR(
"sql.sql",
"SmartScript: Action target for SMART_ACTION_SEND_TARGET_TO_TARGET is not using SmartGameObjectAI, skipping");
2353 }
2354 }
2355 break;
2356 }
2358 {
2360 break;
2361
2362 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction:: SMART_ACTION_SEND_GOSSIP_MENU: gossipMenuId {}, gossipNpcTextId {}",
2364
2366 if (
Player* player = target->ToPlayer())
2367 {
2370 else
2372
2374 }
2375
2376 break;
2377 }
2379 {
2380 if (!targets.empty())
2381 {
2382 float x, y, z, o;
2385 {
2387 {
2390 }
2391 else
2393 }
2394 }
2396 {
2398 {
2399 float x, y, z, o;
2402 }
2403 else
2405 }
2406 break;
2407 }
2409 {
2412 target->ToCreature()->SetRegeneratingHealth(e.action.setHealthRegen.regenHealth);
2413
2414 break;
2415 }
2417 {
2420 target->ToCreature()->SetControlled(e.action.setRoot.root != 0,
UNIT_STATE_ROOT);
2421 break;
2422 }
2424 {
2427 target->ToGameObject()->SetUInt32Value(
GAMEOBJECT_FLAGS, e.action.goFlag.flag);
2428 break;
2429 }
2431 {
2435 break;
2436 }
2438 {
2441 target->ToGameObject()->RemoveFlag(
GAMEOBJECT_FLAGS, e.action.goFlag.flag);
2442 break;
2443 }
2445 {
2446 std::list<TempSummon*> summonList;
2448
2449 for (std::list<TempSummon*>::const_iterator itr = summonList.begin(); itr != summonList.end(); ++itr)
2450 {
2452 (*itr)->AI()->AttackStart(unit);
2454 (*itr)->AI()->AttackStart(
me);
2455 }
2456
2457 break;
2458 }
2460 {
2463 target->ToUnit()->SetPower(
Powers(e.action.power.powerType), e.action.power.newPower);
2464 break;
2465 }
2467 {
2470 target->ToUnit()->SetPower(
Powers(e.action.power.powerType), target->ToUnit()->GetPower(
Powers(e.action.power.powerType)) + e.action.power.newPower);
2471 break;
2472 }
2474 {
2477 target->ToUnit()->SetPower(
Powers(e.action.power.powerType), target->ToUnit()->GetPower(
Powers(e.action.power.powerType)) - e.action.power.newPower);
2478 break;
2479 }
2481 {
2484 {
2485 LOG_ERROR(
"scripts.ai.sai",
"SmartScript::ProcessAction: At case SMART_ACTION_GAME_EVENT_STOP, inactive event (id: {})", eventId);
2486 break;
2487 }
2489 break;
2490 }
2492 {
2495 {
2496 LOG_ERROR(
"scripts.ai.sai",
"SmartScript::ProcessAction: At case SMART_ACTION_GAME_EVENT_START, already activated event (id: {})", eventId);
2497 break;
2498 }
2500 break;
2501 }
2503 {
2505
2507 {
2508 LOG_ERROR(
"scripts.ai.sai",
"SmartScript::ProcessAction: SMART_ACTION_START_CLOSEST_WAYPOINT: Invalid PathSource {} for entryOrGuid {} source_type {} event_id {} link {}",
2510 break;
2511 }
2512
2513 float distanceToClosest = std::numeric_limits<float>::max();
2515
2517 {
2519 {
2521 {
2523 {
2525
2526 switch (pathSource)
2527 {
2530 break;
2533 break;
2534 }
2535
2536 if (!path || path->
Nodes.empty())
2537 continue;
2538
2539 {
2541 float distToThisPath = creature->GetExactDistSq(wpData.
X, wpData.
Y, wpData.
Z);
2542
2543 if (distToThisPath < distanceToClosest)
2544 {
2545 distanceToClosest = distToThisPath;
2546 closestWpId = pathId;
2547 }
2548 }
2549 }
2550
2551 if (closestWpId)
2552 {
2555
2556 CAST_AI(
SmartAI, creature->AI())->StartPath(forcedMovement, closestWpId, repeat,
nullptr, pathSource);
2557 }
2558 }
2559 }
2560 }
2561 break;
2562 }
2564 {
2567 target->ToUnit()->ExitVehicle();
2568
2569 break;
2570 }
2572 {
2575 {
2578 }
2579
2580 break;
2581 }
2583 {
2586 target->ToCreature()->m_CombatDistance = e.action.combatDistance.dist;
2587
2588 break;
2589 }
2591 {
2594 target->ToCreature()->m_SightDistance = e.action.sightDistance.dist;
2595 break;
2596 }
2598 {
2601 target->ToCreature()->GetMotionMaster()->MoveFleeing(
me, e.action.flee.withEmote);
2602 break;
2603 }
2605 {
2607 break;
2610 me->GetThreatMgr().AddThreat(target->ToUnit(), float(e.action.threat.threatINC) - float(e.action.threat.threatDEC), nullptr, true, true);
2611 break;
2612 }
2614 {
2617 target->ToCreature()->LoadEquipment(e.action.loadEquipment.id, e.action.loadEquipment.force != 0);
2618 break;
2619 }
2621 {
2624 break;
2625 }
2627 {
2630 target->ToUnit()->Dismount();
2631 break;
2632 }
2634 {
2637 target->ToUnit()->SetHover(e.action.setHover.state);
2638 break;
2639 }
2641 {
2644 target->ToUnit()->ApplySpellImmune(e.action.immunity.id, e.action.immunity.type, e.action.immunity.value, true);
2645
2646 break;
2647 }
2649 {
2652 target->ToUnit()->ApplySpellImmune(e.action.immunity.id, e.action.immunity.type, e.action.immunity.value, false);
2653 break;
2654 }
2656 {
2659 target->ToUnit()->GetMotionMaster()->MoveFall();
2660
2661 break;
2662 }
2664 {
2666 break;
2667 }
2669 {
2672 target->ToUnit()->RemoveAllGameObjects();
2673 break;
2674 }
2676 {
2678 {
2680 {
2685 }
2686 }
2687 break;
2688 }
2690 {
2694
2695 break;
2696 }
2698 {
2701 if (
Player* player = target->ToUnit()->GetCharmerOrOwnerPlayerOrPlayerItself())
2702 {
2704 break;
2705 }
2706
2707 break;
2708 }
2710 {
2715 break;
2716 }
2718 {
2720
2721 if (!targets.empty())
2725
2726 break;
2727 }
2729 {
2731 break;
2732
2734 {
2736 {
2738 {
2740 }
2741
2743 {
2753
2756 {
2757
2759
2761 else
2762
2764 }
2765 }
2766 }
2767 }
2768 break;
2769 }
2771 {
2773 break;
2774
2775 if (targets.empty())
2776 break;
2777
2779
2784
2785
2786
2787
2788
2789 float factor = std::exp(k * delta_phi);
2790
2791
2792 float summonRadius = a;
2793
2795 {
2796
2797
2799
2800 do
2801 {
2803 summonPosition.RelocatePolarOffset(phi, summonRadius);
2804
2806
2807 phi += delta_phi;
2808 summonRadius *= factor;
2809 } while (summonRadius <= r_max);
2810 }
2811
2812 break;
2813 }
2815 {
2817 break;
2818
2820
2823
2825 {
2826 float deltaAngle = 0.0f;
2827 if (radius > 0)
2828 deltaAngle = distInARow / radius;
2829
2831 if (deltaAngle > 0)
2832 count += coneAngle / deltaAngle;
2833
2834 float currentAngle = -static_cast<float>(count) * deltaAngle / 2.0f;
2835
2838 else if (!targets.empty())
2839 {
2841 }
2842
2843 for (
uint32 index = 0; index < count; ++index)
2844 {
2846 spawnPosition.RelocatePolarOffset(currentAngle, radius);
2847 currentAngle += deltaAngle;
2848
2850 }
2851 }
2852
2853 break;
2854 }
2856 {
2858 {
2860 {
2861 playerTarget->RemoveArenaSpellCooldowns();
2863 playerTarget->RemoveAurasDueToSpell(57723);
2864 playerTarget->RemoveAurasDueToSpell(2825);
2865 playerTarget->RemoveAurasDueToSpell(32182);
2866 }
2867 }
2868
2869 break;
2870 }
2872 {
2875 {
2876 if (targets.empty())
2877 break;
2878
2880 {
2882 {
2884 {
2885 unitTarget->AI()->DoAction(actionId);
2886 }
2887 }
2889 {
2890 gobjTarget->AI()->DoAction(actionId);
2891 }
2892 }
2893
2894 }
2895 else
2896 {
2899 {
2900 instanceScript = baseObj->GetInstanceScript();
2901 }
2902
2904 {
2906 }
2907
2908 if (instanceScript)
2909 {
2910 instanceScript->
DoAction(actionId);
2911 }
2912 }
2913 break;
2914 }
2916 {
2918 break;
2919
2921 break;
2922 }
2924 {
2926 {
2929 }
2930 break;
2931 }
2933 {
2935 if (
Unit* targetUnit = target->ToUnit())
2936 targetUnit->SetHealth(targetUnit->CountPctFromMaxHealth(e.action.setHealthPct.percent));
2937 break;
2938 }
2940 {
2943 float speed = float(speedInteger) + float(speedFraction) / std::pow(10, std::floor(std::log10(float(speedFraction ? speedFraction : 1)) + 1));
2944
2947 target->ToCreature()->SetSpeed(
UnitMoveType(e.action.movementSpeed.movementType), speed);
2948
2949 break;
2950 }
2952 {
2954 {
2956 continue;
2957
2959 }
2960 break;
2961 }
2963 {
2965 {
2967
2969 {
2971 {
2972 guidToSend = invoker->
GetGUID();
2973 }
2974 }
2975
2977 {
2979 }
2981 {
2983 }
2984 }
2985 break;
2986 }
2988 {
2989
2991 {
2992 case 0:
2993 {
2995 {
2997 {
3000 c->DespawnOrUnsummon();
3001 }
3002 }
3003 break;
3004 }
3005 case 1:
3006 {
3008 {
3010 {
3012 c->Respawn(true);
3014 }
3015 }
3016 break;
3017 }
3018 case 2:
3019 {
3021 {
3023 {
3025
3026
3029 else
3030 c->Respawn(true);
3031
3032
3035
3036
3039 }
3040 }
3041 break;
3042 }
3043 default:
3044 break;
3045 }
3046 break;
3047 }
3049 {
3051
3053 {
3055 {
3057 }
3058 }
3059 break;
3060 }
3062 {
3064 break;
3065
3067
3070
3072 {
3074 {
3078 }
3079 break;
3080 }
3081
3083 {
3084 float currentAngle = startAngle + (itr * stepAngle);
3086 }
3087
3088 break;
3089 }
3091 {
3093 {
3095 {
3098 }
3099 }
3100 break;
3101 }
3103 {
3105 {
3108 target->ToCreature()->GetMotionMaster()->MoveIdle();
3109
3110 break;
3111 }
3112
3113 uint8 membCount = targets.size();
3117 {
3119 {
3120 float angle = (membCount > 4 ? (M_PI * 2)/membCount : (M_PI / 2));
3122 {
3124 {
3126 itr++;
3127 }
3128 }
3129 break;
3130 }
3132 {
3134 {
3136 {
3138 itr++;
3139 }
3140 }
3141 break;
3142 }
3144 {
3146 {
3148 {
3150 itr++;
3151 }
3152 }
3153 break;
3154 }
3156 {
3158 {
3160 {
3162 itr++;
3163 }
3164 }
3165 break;
3166 }
3168 {
3170 {
3172 {
3174 itr++;
3175 }
3176 }
3177 break;
3178 }
3180 {
3182 {
3184 {
3186 itr++;
3187 }
3188 }
3189 break;
3190 }
3191 default:
3192 break;
3193 }
3194
3195 break;
3196 }
3198 {
3200 {
3201 case 0:
3202 {
3204 target->ToCreature()->SetFacingTo((target->ToCreature()->HasUnitMovementFlag(
MOVEMENTFLAG_ONTRANSPORT) && target->ToCreature()->GetTransGUID() ? target->ToCreature()->GetTransportHomePosition() : target->ToCreature()->GetHomePosition()).GetOrientation());
3205
3206 break;
3207 }
3208 case 1:
3209 {
3211 target->ToCreature()->SetFacingTo(e.target.o);
3212
3213 break;
3214 }
3215 case 2:
3216 {
3218 target->ToCreature()->SetFacingToObject(
me);
3219
3220 break;
3221 }
3222 case 3:
3223 {
3225 GetTargets(facingTargets,
CreateSmartEvent(
SMART_EVENT_UPDATE_IC, 0, 0, 0, 0, 0, 0, 0,
SMART_ACTION_NONE, 0, 0, 0, 0, 0, 0, (
SMARTAI_TARGETS)e.
action.
orientationTarget.
targetType, e.
action.
orientationTarget.
targetParam1, e.
action.
orientationTarget.
targetParam2, e.
action.
orientationTarget.
targetParam3, e.
action.
orientationTarget.
targetParam4, 0), unit);
3226
3229 target->ToCreature()->SetFacingToObject(facingTarget);
3230
3231 break;
3232 }
3233 default:
3234 break;
3235 }
3236 break;
3237 }
3239 {
3241 {
3243 {
3245 {
3248 }
3249 }
3250 }
3251
3252 break;
3253 }
3255 {
3257 {
3259 {
3261 {
3265 }
3266 }
3267 }
3268
3269 break;
3270 }
3272 {
3275 target->ToUnit()->StopMoving();
3276
3277 break;
3278 }
3280 {
3283 target->ToUnit()->PauseMovement(e.action.move.timer);
3284
3285 break;
3286 }
3288 {
3291 target->ToUnit()->ResumeMovement(e.action.move.timer);
3292
3293 break;
3294 }
3296 {
3298 break;
3299 }
3301 {
3304 {
3307 }
3308 break;
3309 }
3311 {
3314 target->ToUnit()->SetAnimTier(
AnimTier(e.action.animTier.animTier));
3315 break;
3316 }
3318 {
3320 {
3322 {
3324 LOG_DEBUG(
"sql.sql",
"SmartScript::ProcessAction: SMART_ACTION_SET_GOSSIP_MENU: Creature {} set gossip menu to {}",
3326 }
3327 }
3328 break;
3329 }
3331 {
3333 break;
3334
3336 break;
3337 }
3338 default:
3340 break;
3341 }
3342
3344 {
3346 if (linked.has_value())
3347 {
3348 auto& linkedEvent = linked.value().get();
3350 executionStack.emplace_back(SmartScriptFrame{ linkedEvent, unit, var0, var1, bvar, spell, gob });
3351 else
3352 LOG_ERROR(
"sql.sql",
"SmartScript::ProcessAction: Entry {} SourceType {}, Event {}, Link Event {} found but has wrong type (should be 61, is {}).", e.
entryOrGuid, e.
GetScriptType(), e.
event_id, e.
link, linkedEvent.GetEventType());
3353 }
3354 else
3356 }
3357}
npc
Definition BattlegroundSA.h:47
#define DEFAULT_LOCALE
Definition Common.h:131
#define MAX_EQUIPMENT_ITEMS
Definition CreatureData.h:36
@ TEXT_RANGE_NORMAL
Definition CreatureTextMgr.h:30
std::int8_t int8
Definition Define.h:105
std::chrono::milliseconds Milliseconds
Milliseconds shorthand typedef.
Definition Duration.h:27
std::chrono::seconds Seconds
Seconds shorthand typedef.
Definition Duration.h:30
#define sGameEventMgr
Definition GameEventMgr.h:201
GOState
Definition GameObjectData.h:707
LootState
Definition GameObject.h:109
@ GO_READY
Definition GameObject.h:111
EncounterState
Definition InstanceScript.h:57
@ BROADCAST_TEXT_CALL_FOR_HELP
Definition Language.h:24
@ BROADCAST_TEXT_FLEE_FOR_ASSIST
Definition Language.h:25
@ MOTION_SLOT_CONTROLLED
Definition MotionMaster.h:66
@ MOTION_SLOT_ACTIVE
Definition MotionMaster.h:65
PathSource
Definition MotionMaster.h:94
ForcedMovement
Definition MotionMaster.h:85
@ FORCED_MOVEMENT_NONE
Definition MotionMaster.h:86
AnimTier
Definition MotionMaster.h:100
#define NOMINAL_MELEE_RANGE
Definition ObjectDefines.h:47
#define sObjectMgr
Definition ObjectMgr.h:1712
TempSummonType
Definition Object.h:48
@ TEMPSUMMON_TIMED_DESPAWN
Definition Object.h:51
@ TEMPSUMMON_CORPSE_DESPAWN
Definition Object.h:53
float frand(float min, float max)
Definition Random.cpp:57
uint32 urand(uint32 min, uint32 max)
Definition Random.cpp:44
void SendGossipMenuFor(Player *player, uint32 npcTextID, ObjectGuid const &guid)
Definition ScriptedGossip.cpp:45
void ClearGossipMenuFor(Player *player)
Definition ScriptedGossip.cpp:22
@ GAMEOBJECT_TYPE_DOOR
Definition SharedDefines.h:1566
@ POWER_MANA
Definition SharedDefines.h:257
@ CHAT_MSG_MONSTER_EMOTE
Definition SharedDefines.h:3403
@ CHAT_MSG_ADDON
Definition SharedDefines.h:3386
@ LANG_UNIVERSAL
Definition SharedDefines.h:723
@ LANG_ADDON
Definition SharedDefines.h:741
@ SPELL_ATTR2_IGNORE_LINE_OF_SIGHT
Definition SharedDefines.h:446
@ TEAM_NEUTRAL
Definition SharedDefines.h:750
SpellCastResult
Definition SharedDefines.h:936
@ SPELL_FAILED_OUT_OF_RANGE
Definition SharedDefines.h:1034
@ SPELL_CAST_OK
Definition SharedDefines.h:1126
@ SPELL_FAILED_SPELL_IN_PROGRESS
Definition SharedDefines.h:1042
@ SMART_EVENT_FLAG_TEMP_IGNORE_CHANCE_ROLL
Definition SmartScriptMgr.h:1959
SMARTAI_TARGETS
Definition SmartScriptMgr.h:1541
@ SMART_TARGET_RANDOM_POINT
Definition SmartScriptMgr.h:1580
#define sSmartWaypointMgr
Definition SmartScriptMgr.h:2263
SMART_ACTION
Definition SmartScriptMgr.h:541
@ SMART_ACTION_REMOVE_TIMED_EVENT
Definition SmartScriptMgr.h:616
@ SMART_ACTION_NONE
Definition SmartScriptMgr.h:542
@ SMART_ACTION_SET_GO_FLAG
Definition SmartScriptMgr.h:646
@ SMART_ACTION_UPDATE_TEMPLATE
Definition SmartScriptMgr.h:578
@ SMART_ACTION_SET_HEALTH_REGEN
Definition SmartScriptMgr.h:644
@ SMART_ACTION_SET_GOSSIP_MENU
Definition SmartScriptMgr.h:727
@ SMART_ACTION_ACTIVATE_GOBJECT
Definition SmartScriptMgr.h:551
@ SMART_ACTION_GAME_EVENT_START
Definition SmartScriptMgr.h:654
@ SMART_ACTION_CALL_RANDOM_RANGE_TIMED_ACTIONLIST
Definition SmartScriptMgr.h:630
@ SMART_ACTION_REMOVE_UNIT_FIELD_BYTES_1
Definition SmartScriptMgr.h:633
@ SMART_ACTION_SET_INST_DATA64
Definition SmartScriptMgr.h:577
@ SMART_ACTION_SET_FACTION
Definition SmartScriptMgr.h:544
@ SMART_ACTION_THREAT_SINGLE_PCT
Definition SmartScriptMgr.h:555
@ SMART_ACTION_OFFER_QUEST
Definition SmartScriptMgr.h:549
@ SMART_ACTION_REMOVE_ALL_GAMEOBJECTS
Definition SmartScriptMgr.h:668
@ SMART_ACTION_RISE_UP
Definition SmartScriptMgr.h:656
@ SMART_ACTION_SET_INGAME_PHASE_MASK
Definition SmartScriptMgr.h:586
@ SMART_ACTION_SET_UNIT_FIELD_BYTES_1
Definition SmartScriptMgr.h:632
@ SMART_ACTION_CLOSE_GOSSIP
Definition SmartScriptMgr.h:614
@ SMART_ACTION_DISABLE_EVADE
Definition SmartScriptMgr.h:659
@ SMART_ACTION_CONE_SUMMON
Definition SmartScriptMgr.h:706
@ SMART_ACTION_ADD_GO_FLAG
Definition SmartScriptMgr.h:647
@ SMART_ACTION_ESCORT_START
Definition SmartScriptMgr.h:595
@ SMART_ACTION_ADD_DYNAMIC_FLAG
Definition SmartScriptMgr.h:637
@ SMART_ACTION_KILL_UNIT
Definition SmartScriptMgr.h:593
@ SMART_ACTION_LOAD_EQUIPMENT
Definition SmartScriptMgr.h:666
@ SMART_ACTION_CALL_AREAEXPLOREDOREVENTHAPPENS
Definition SmartScriptMgr.h:557
@ SMART_ACTION_ATTACK_START
Definition SmartScriptMgr.h:591
@ SMART_ACTION_MOVEMENT_RESUME
Definition SmartScriptMgr.h:723
@ SMART_ACTION_SET_UNIT_FLAG
Definition SmartScriptMgr.h:560
@ SMART_ACTION_NO_ENVIRONMENT_UPDATE
Definition SmartScriptMgr.h:699
@ SMART_ACTION_CALL_GROUPEVENTHAPPENS
Definition SmartScriptMgr.h:568
@ SMART_ACTION_MOUNT_TO_ENTRY_OR_MODEL
Definition SmartScriptMgr.h:585
@ SMART_ACTION_INVOKER_CAST
Definition SmartScriptMgr.h:676
@ SMART_ACTION_MOVEMENT_STOP
Definition SmartScriptMgr.h:721
@ SMART_ACTION_SET_SCALE
Definition SmartScriptMgr.h:714
@ SMART_ACTION_JUMP_TO_POS
Definition SmartScriptMgr.h:639
@ SMART_ACTION_CALL_RANDOM_TIMED_ACTIONLIST
Definition SmartScriptMgr.h:629
@ SMART_ACTION_SEND_GOSSIP_MENU
Definition SmartScriptMgr.h:640
@ SMART_ACTION_SET_COUNTER
Definition SmartScriptMgr.h:605
@ SMART_ACTION_FLEE_FOR_ASSIST
Definition SmartScriptMgr.h:567
@ SMART_ACTION_EQUIP
Definition SmartScriptMgr.h:613
@ SMART_ACTION_SET_ROOT
Definition SmartScriptMgr.h:645
@ SMART_ACTION_ATTACK_STOP
Definition SmartScriptMgr.h:711
@ SMART_ACTION_SUMMON_GO
Definition SmartScriptMgr.h:592
@ SMART_ACTION_SET_HOVER
Definition SmartScriptMgr.h:693
@ SMART_ACTION_SIMPLE_TALK
Definition SmartScriptMgr.h:626
@ SMART_ACTION_STOP_MOTION
Definition SmartScriptMgr.h:698
@ SMART_ACTION_VORTEX_SUMMON
Definition SmartScriptMgr.h:708
@ SMART_ACTION_WORLD_SCRIPT
Definition SmartScriptMgr.h:724
@ SMART_ACTION_MUSIC
Definition SmartScriptMgr.h:702
@ SMART_ACTION_SET_ORIENTATION_TARGET
Definition SmartScriptMgr.h:718
@ SMART_ACTION_SET_UNIT_MOVEMENT_FLAGS
Definition SmartScriptMgr.h:690
@ SMART_ACTION_ADD_AURA
Definition SmartScriptMgr.h:617
@ SMART_ACTION_THREAT_ALL_PCT
Definition SmartScriptMgr.h:556
@ SMART_ACTION_WAYPOINT_START
Definition SmartScriptMgr.h:719
@ SMART_ACTION_ESCORT_STOP
Definition SmartScriptMgr.h:597
@ SMART_ACTION_RESPAWN_TARGET
Definition SmartScriptMgr.h:612
@ SMART_ACTION_FOLLOW_GROUP
Definition SmartScriptMgr.h:717
@ SMART_ACTION_SOUND
Definition SmartScriptMgr.h:546
@ SMART_ACTION_ESCORT_PAUSE
Definition SmartScriptMgr.h:596
@ SMART_ACTION_MOVE_TO_POS_TARGET
Definition SmartScriptMgr.h:687
@ SMART_ACTION_SET_MOVEMENT_SPEED
Definition SmartScriptMgr.h:678
@ SMART_ACTION_PLAY_CINEMATIC
Definition SmartScriptMgr.h:677
@ SMART_ACTION_ADD_NPC_FLAG
Definition SmartScriptMgr.h:624
@ SMART_ACTION_EVADE
Definition SmartScriptMgr.h:566
@ SMART_ACTION_FAIL_QUEST
Definition SmartScriptMgr.h:548
@ SMART_ACTION_INTERRUPT_SPELL
Definition SmartScriptMgr.h:634
@ SMART_ACTION_ADD_POWER
Definition SmartScriptMgr.h:651
@ SMART_ACTION_SET_ANIM_TIER
Definition SmartScriptMgr.h:726
@ SMART_ACTION_REMOVE_DYNAMIC_FLAG
Definition SmartScriptMgr.h:638
@ SMART_ACTION_RANDOM_SOUND
Definition SmartScriptMgr.h:657
@ SMART_ACTION_RANDOM_MUSIC
Definition SmartScriptMgr.h:703
@ SMART_ACTION_SET_COMBAT_DISTANCE
Definition SmartScriptMgr.h:691
@ SMART_ACTION_SET_POWER
Definition SmartScriptMgr.h:650
@ SMART_ACTION_SEND_TARGET_TO_TARGET
Definition SmartScriptMgr.h:642
@ SMART_ACTION_REMOVE_POWER
Definition SmartScriptMgr.h:652
@ SMART_ACTION_ADD_IMMUNITY
Definition SmartScriptMgr.h:694
@ SMART_ACTION_SET_DYNAMIC_FLAG
Definition SmartScriptMgr.h:636
@ SMART_ACTION_FALL
Definition SmartScriptMgr.h:696
@ SMART_ACTION_GO_SET_GO_STATE
Definition SmartScriptMgr.h:660
@ SMART_ACTION_CUSTOM_CAST
Definition SmartScriptMgr.h:705
@ SMART_ACTION_REMOVE_ITEM
Definition SmartScriptMgr.h:599
@ SMART_ACTION_SEND_GO_CUSTOM_ANIM
Definition SmartScriptMgr.h:635
@ SMART_ACTION_MORPH_TO_ENTRY_OR_MODEL
Definition SmartScriptMgr.h:545
@ SMART_ACTION_REMOVE_UNIT_FLAG
Definition SmartScriptMgr.h:561
@ SMART_ACTION_RANDOM_PHASE
Definition SmartScriptMgr.h:572
@ SMART_ACTION_SET_EMOTE_STATE
Definition SmartScriptMgr.h:559
@ SMART_ACTION_CROSS_CAST
Definition SmartScriptMgr.h:628
@ SMART_ACTION_GAME_EVENT_STOP
Definition SmartScriptMgr.h:653
@ SMART_ACTION_SCRIPTED_SPAWN
Definition SmartScriptMgr.h:713
@ SMART_ACTION_ESCORT_RESUME
Definition SmartScriptMgr.h:607
@ SMART_ACTION_CALL_SCRIPT_RESET
Definition SmartScriptMgr.h:620
@ SMART_ACTION_CU_ENCOUNTER_START
Definition SmartScriptMgr.h:709
@ SMART_ACTION_COMBAT_STOP
Definition SmartScriptMgr.h:569
@ SMART_ACTION_EXIT_VEHICLE
Definition SmartScriptMgr.h:689
@ SMART_ACTION_SET_HEALTH_PCT
Definition SmartScriptMgr.h:680
@ SMART_ACTION_AUTO_ATTACK
Definition SmartScriptMgr.h:562
@ SMART_ACTION_SET_INVINCIBILITY_HP_LEVEL
Definition SmartScriptMgr.h:584
@ SMART_ACTION_SET_VISIBILITY
Definition SmartScriptMgr.h:589
@ SMART_ACTION_RANDOM_PHASE_RANGE
Definition SmartScriptMgr.h:573
@ SMART_ACTION_MOVEMENT_PAUSE
Definition SmartScriptMgr.h:722
@ SMART_ACTION_GO_SET_LOOT_STATE
Definition SmartScriptMgr.h:641
@ SMART_ACTION_PLAYER_TALK
Definition SmartScriptMgr.h:707
@ SMART_ACTION_SELF_CAST
Definition SmartScriptMgr.h:627
@ SMART_ACTION_SET_SWIM
Definition SmartScriptMgr.h:603
@ SMART_ACTION_SET_SIGHT_DIST
Definition SmartScriptMgr.h:663
@ SMART_ACTION_SET_INST_DATA
Definition SmartScriptMgr.h:576
@ SMART_ACTION_REMOVE_GO_FLAG
Definition SmartScriptMgr.h:648
@ SMART_ACTION_LOAD_GRID
Definition SmartScriptMgr.h:701
@ SMART_ACTION_CALL_FOR_HELP
Definition SmartScriptMgr.h:581
@ SMART_ACTION_SUMMON_RADIAL
Definition SmartScriptMgr.h:715
@ SMART_ACTION_ADD_THREAT
Definition SmartScriptMgr.h:665
@ SMART_ACTION_DISMOUNT
Definition SmartScriptMgr.h:692
@ SMART_ACTION_TELEPORT
Definition SmartScriptMgr.h:604
@ SMART_ACTION_PLAYMOVIE
Definition SmartScriptMgr.h:610
@ SMART_ACTION_TRIGGER_RANDOM_TIMED_EVENT
Definition SmartScriptMgr.h:667
@ SMART_ACTION_FOLLOW
Definition SmartScriptMgr.h:571
@ SMART_ACTION_PLAY_EMOTE
Definition SmartScriptMgr.h:547
@ SMART_ACTION_SET_CORPSE_DELAY
Definition SmartScriptMgr.h:658
@ SMART_ACTION_WAYPOINT_DATA_RANDOM
Definition SmartScriptMgr.h:720
@ SMART_ACTION_SET_GUID
Definition SmartScriptMgr.h:712
@ SMART_ACTION_SET_SHEATH
Definition SmartScriptMgr.h:582
@ SMART_ACTION_SET_ORIENTATION
Definition SmartScriptMgr.h:608
@ SMART_ACTION_SET_NPC_FLAG
Definition SmartScriptMgr.h:623
@ SMART_ACTION_MOVE_TO_POS
Definition SmartScriptMgr.h:611
@ SMART_ACTION_RANDOM_EMOTE
Definition SmartScriptMgr.h:552
@ SMART_ACTION_INC_EVENT_PHASE
Definition SmartScriptMgr.h:565
@ SMART_ACTION_CREATE_TIMED_EVENT
Definition SmartScriptMgr.h:609
@ SMART_ACTION_SET_EVENT_FLAG_RESET
Definition SmartScriptMgr.h:697
@ SMART_ACTION_SUMMON_GAMEOBJECT_GROUP
Definition SmartScriptMgr.h:728
@ SMART_ACTION_DIE
Definition SmartScriptMgr.h:579
@ SMART_ACTION_RESET_SCRIPT_BASE_OBJECT
Definition SmartScriptMgr.h:619
@ SMART_ACTION_REMOVE_NPC_FLAG
Definition SmartScriptMgr.h:625
@ SMART_ACTION_SET_FLY
Definition SmartScriptMgr.h:602
@ SMART_ACTION_INSTALL_AI_TEMPLATE
Definition SmartScriptMgr.h:600
@ SMART_ACTION_SUMMON_CREATURE
Definition SmartScriptMgr.h:554
@ SMART_ACTION_CALL_TIMED_ACTIONLIST
Definition SmartScriptMgr.h:622
@ SMART_ACTION_SET_IN_COMBAT_WITH_ZONE
Definition SmartScriptMgr.h:580
@ SMART_ACTION_DO_ACTION
Definition SmartScriptMgr.h:710
@ SMART_ACTION_SET_HOME_POS
Definition SmartScriptMgr.h:643
@ SMART_ACTION_ADD_ITEM
Definition SmartScriptMgr.h:598
@ SMART_ACTION_SET_ACTIVE
Definition SmartScriptMgr.h:590
@ SMART_ACTION_SET_RANGED_MOVEMENT
Definition SmartScriptMgr.h:621
@ SMART_ACTION_ACTIVATE_TAXI
Definition SmartScriptMgr.h:594
@ SMART_ACTION_START_CLOSEST_WAYPOINT
Definition SmartScriptMgr.h:655
@ SMART_ACTION_SUMMON_CREATURE_GROUP
Definition SmartScriptMgr.h:649
@ SMART_ACTION_REMOVE_IMMUNITY
Definition SmartScriptMgr.h:695
@ SMART_ACTION_PLAY_SPELL_VISUAL
Definition SmartScriptMgr.h:716
@ SMART_ACTION_SET_REACT_STATE
Definition SmartScriptMgr.h:550
@ SMART_ACTION_DISABLE_REWARD
Definition SmartScriptMgr.h:725
@ SMART_ACTION_RANDOM_MOVE
Definition SmartScriptMgr.h:631
@ SMART_ACTION_OVERRIDE_SCRIPT_BASE_OBJECT
Definition SmartScriptMgr.h:618
@ SMART_ACTION_TRIGGER_TIMED_EVENT
Definition SmartScriptMgr.h:615
@ SMART_ACTION_REMOVEAURASFROMSPELL
Definition SmartScriptMgr.h:570
@ SMART_ACTION_FLEE
Definition SmartScriptMgr.h:664
@ SMART_ACTION_ZONE_UNDER_ATTACK
Definition SmartScriptMgr.h:700
@ FOLLOW_TYPE_CIRCLE
Definition SmartScriptMgr.h:1979
@ FOLLOW_TYPE_SEMI_CIRCLE_BEHIND
Definition SmartScriptMgr.h:1980
@ FOLLOW_TYPE_SEMI_CIRCLE_FRONT
Definition SmartScriptMgr.h:1981
@ FOLLOW_TYPE_COLUMN
Definition SmartScriptMgr.h:1983
@ FOLLOW_TYPE_ANGULAR
Definition SmartScriptMgr.h:1984
@ FOLLOW_TYPE_LINE
Definition SmartScriptMgr.h:1982
SMART_EVENT
Definition SmartScriptMgr.h:98
@ SMART_EVENT_TIMED_EVENT_TRIGGERED
Definition SmartScriptMgr.h:158
@ SMART_EVENT_ESCORT_REACHED
Definition SmartScriptMgr.h:139
@ SMART_EVENT_LINK
Definition SmartScriptMgr.h:160
uint32 SAIBool
Definition SmartScriptMgr.h:31
SmartActionSummonCreatureFlags
Definition SmartScriptMgr.h:734
@ SMART_ESCORT_TARGETS
Definition SmartScriptMgr.h:40
@ SMARTCAST_TRIGGERED
Definition SmartScriptMgr.h:1965
@ SMARTCAST_ENABLE_COMBAT_MOVE_ON_LOS
Definition SmartScriptMgr.h:1973
@ SMARTCAST_COMBAT_MOVE
Definition SmartScriptMgr.h:1970
@ SMARTCAST_INTERRUPT_PREVIOUS
Definition SmartScriptMgr.h:1964
@ SMARTCAST_AURA_NOT_PRESENT
Definition SmartScriptMgr.h:1969
@ SMARTCAST_THREATLIST_NOT_SINGLE
Definition SmartScriptMgr.h:1971
@ SMARTCAST_TARGET_POWER_MANA
Definition SmartScriptMgr.h:1972
@ AURA_REMOVE_BY_EXPIRE
Definition SpellAuraDefines.h:395
@ SPELLVALUE_BASE_POINT1
Definition SpellDefines.h:114
@ SPELLVALUE_BASE_POINT2
Definition SpellDefines.h:115
@ SPELLVALUE_BASE_POINT0
Definition SpellDefines.h:113
TriggerCastFlags
Definition SpellDefines.h:132
@ TRIGGERED_FULL_MASK
Will return SPELL_FAILED_DONT_REPORT in CheckCast functions.
Definition SpellDefines.h:150
@ TRIGGERED_NONE
Definition SpellDefines.h:133
#define sSpellMgr
Definition SpellMgr.h:836
#define CAST_AI(a, b)
Definition UnitAI.h:26
#define ENSURE_AI(a, b)
Definition UnitAI.h:27
@ MOVEMENTFLAG_ONTRANSPORT
Definition UnitDefines.h:381
NPCFlags
Non Player Character flags.
Definition UnitDefines.h:320
SheathState
Definition UnitDefines.h:128
@ UNIT_STATE_LOST_CONTROL
Definition UnitDefines.h:219
@ UNIT_STATE_ROOT
Definition UnitDefines.h:183
@ UNIT_STATE_NO_ENVIRONMENT_UPD
Definition UnitDefines.h:201
@ UNIT_STATE_NO_COMBAT_MOVEMENT
Definition UnitDefines.h:204
UnitMoveType
Definition UnitDefines.h:355
@ MOVE_RUN
Definition UnitDefines.h:357
@ UNIT_FLAG_SILENCED
Definition UnitDefines.h:270
ReactStates
Definition Unit.h:565
@ UNIT_FIELD_FLAGS_2
Definition UpdateFields.h:118
@ UNIT_VIRTUAL_ITEM_SLOT_ID
Definition UpdateFields.h:116
@ UNIT_FIELD_FLAGS
Definition UpdateFields.h:117
@ UNIT_NPC_EMOTESTATE
Definition UpdateFields.h:140
@ UNIT_FIELD_BYTES_1
Definition UpdateFields.h:131
@ UNIT_DYNAMIC_FLAGS
Definition UpdateFields.h:136
@ GAMEOBJECT_FLAGS
Definition UpdateFields.h:399
#define sWaypointMgr
Definition WaypointMgr.h:54
#define sWorldState
Definition WorldState.h:377
WorldStateEvent
Definition WorldState.h:42
Say
Definition boss_broodlord_lashlayer.cpp:29
Seats
Definition boss_flame_leviathan.cpp:160
Definition ChatTextBuilder.h:31
Definition SpellAuras.h:87
void StartCinematic(uint32 const cinematicSequenceId)
Definition CinematicMgr.cpp:31
Definition CreatureAI.h:69
void Talk(uint8 id, WorldObject const *whisperTarget=nullptr, Milliseconds delay=0ms)
Causes the creature to talk/say the text assigned to their entry in the creature_text database table.
Definition CreatureAI.cpp:67
void SetReputationRewardDisabled(bool disable)
Definition Creature.h:376
void SetHomePosition(float x, float y, float z, float o)
Definition Creature.h:345
void Respawn(bool force=false)
Definition Creature.cpp:1987
void GetRespawnPosition(float &x, float &y, float &z, float *ori=nullptr, float *dist=nullptr) const
Definition Creature.cpp:2988
void GetHomePosition(float &x, float &y, float &z, float &ori) const
Definition Creature.h:347
void SendZoneUnderAttackMessage(Player *attacker)
Send a message to LocalDefense channel for players opposition team in the zone.
Definition Creature.cpp:2779
void GetTransportHomePosition(float &x, float &y, float &z, float &ori) const
Definition Creature.h:352
void DoFleeToGetAssistance()
Definition Creature.cpp:1045
bool IsRooted() const
Definition Creature.h:88
void SetCorpseDelay(uint32 delay)
Definition Creature.h:74
void SetLootRewardDisabled(bool disable)
Definition Creature.h:378
void SetReactState(ReactStates state)
A creature can have 3 ReactStates : Agressive, Passive, Neutral.
Definition Creature.h:99
void LoadPath(uint32 pathid)
Definition Creature.h:356
Definition SpellDefines.h:165
void AddSpellMod(SpellValueMod mod, int32 value)
Definition SpellDefines.h:167
void AddEventAtOffset(BasicEvent *event, Milliseconds offset, uint8 eventGroup=0)
Definition EventProcessor.h:108
Definition GameObjectAI.h:33
virtual void SetData(uint32, uint32)
Definition GameObjectAI.h:62
void UseDoorOrButton(uint32 time_to_restore=0, bool alternative=false, Unit *user=nullptr)
Definition GameObject.cpp:1405
bool isSpawnedByDefault() const
Definition GameObject.h:195
void SetLootState(LootState s, Unit *unit=nullptr)
Definition GameObject.cpp:2457
void SetRespawnTime(int32 respawn)
Definition GameObject.cpp:1279
GameobjectTypes GetGoType() const
Definition GameObject.h:202
void Respawn()
Definition GameObject.cpp:1294
void DespawnOrUnsummon(Milliseconds delay=0ms, Seconds forcedRespawnTime=0s)
Definition GameObject.cpp:927
void CastSpell(Unit *target, uint32 spell)
Definition GameObject.cpp:2072
virtual bool SetBossState(uint32 id, EncounterState state)
Definition InstanceScript.cpp:390
virtual void DoAction(int32)
Definition InstanceScript.h:284
static std::string GetBossStateName(uint8 state)
Definition InstanceScript.cpp:831
Definition LinkedList.h:139
bool IsEmpty() const
Definition LinkedList.h:97
Definition MapRefMgr.h:26
iterator begin()
Definition MapRefMgr.h:36
iterator end()
Definition MapRefMgr.h:37
void LoadGrid(float x, float y)
Definition Map.cpp:212
PlayerList const & GetPlayers() const
Definition Map.h:326
void MoveWaypoint(uint32 path_id, bool repeatable, PathSource pathSource=PathSource::WAYPOINT_MGR)
Move the unit following a specific path. Doesn't work with UNIT_FLAG_DISABLE_MOVE.
Definition MotionMaster.cpp:913
void MovementExpired(bool reset=true)
Definition MotionMaster.h:206
void MoveJump(Position const &pos, float speedXY, float speedZ, uint32 id=0)
Definition MotionMaster.h:256
void MoveIdle()
Definition MotionMaster.cpp:234
void MoveFollow(Unit *target, float dist, float angle, MovementSlot slot=MOTION_SLOT_ACTIVE, bool inheritWalkState=true, bool inheritSpeed=true)
The unit will follow this target. Doesn't work with UNIT_FLAG_DISABLE_MOVE.
Definition MotionMaster.cpp:447
void MovePoint(uint32 id, const Position &pos, ForcedMovement forcedMovement=FORCED_MOVEMENT_NONE, float speed=0.f, bool generatePath=true, bool forceDestination=true, std::optional< AnimTier > animTier=std::nullopt)
Definition MotionMaster.h:240
void MoveRandom(float wanderDistance=0.0f)
Enable a random movement in desired range around the unit. Doesn't work with UNIT_FLAG_DISABLE_MOVE.
Definition MotionMaster.cpp:244
static ObjectGuid const Empty
Definition ObjectGuid.h:120
std::string ToString() const
Definition ObjectGuid.cpp:47
static CreatureModel const * ChooseDisplayId(CreatureTemplate const *cinfo, CreatureData const *data=nullptr)
Definition ObjectMgr.cpp:1643
bool HasFlag(uint16 index, uint32 flag) const
Definition Object.cpp:871
virtual void SetObjectScale(float scale)
Definition Object.h:121
CinematicMgr & GetCinematicMgr()
Definition Player.h:1396
void GroupEventHappens(uint32 questId, WorldObject const *pEventObject)
Definition PlayerQuest.cpp:1850
void PrepareGossipMenu(WorldObject *source, uint32 menuId=0, bool showQuests=false)
Definition PlayerGossip.cpp:32
void RewardPlayerAndGroupAtEvent(uint32 creature_id, WorldObject *pRewardSource)
Definition Player.cpp:12733
Definition QuestDef.h:210
void SetInvincibilityHpLevel(uint32 level)
Definition SmartAI.h:185
void SetData(uint32 id, uint32 value) override
Definition SmartAI.h:164
void IncPhase(uint32 p)
Definition SmartScript.cpp:5459
void StoreTargetList(ObjectVector const &targets, uint32 id)
Definition SmartScript.h:93
void RetryLater(SmartScriptHolder &e, bool ignoreChanceRoll=false)
Definition SmartScript.cpp:5147
void StoreCounter(uint32 id, uint32 value, uint32 reset, uint32 subtract)
Definition SmartScript.h:108
std::optional< std::reference_wrapper< SmartScriptHolder > > FindLinkedEvent(uint32 link)
Definition SmartScript.h:269
std::deque< SmartScriptFrame > executionStack
Definition SmartScript.h:286
void SetPhaseReset(bool allow)
Definition SmartScript.h:205
void GetTargets(ObjectVector &targets, SmartScriptHolder const &e, WorldObject *invoker=nullptr) const
Definition SmartScript.cpp:3486
void OnReset()
Definition SmartScript.cpp:110
void InstallTemplate(SmartScriptHolder const &e)
Definition SmartScript.cpp:3374
ObjectGuid goOrigGUID
Definition SmartScript.h:229
void DecPhase(uint32 p)
Definition SmartScript.cpp:5465
ObjectGuid meOrigGUID
Definition SmartScript.h:227
Definition SpellInfo.h:340
SpellSchoolMask GetSchoolMask() const
Definition SpellInfo.cpp:1894
bool HasAttribute(SpellAttr0 attribute) const
Definition SpellInfo.h:441
int32 CalcPowerCost(Unit const *caster, SpellSchoolMask schoolMask, Spell *spell=nullptr) const
Definition SpellInfo.cpp:2803
void ModifyThreatByPercent(Unit *target, int32 percent)
Definition ThreatManager.h:150
size_t GetThreatListSize() const
Definition ThreatManager.cpp:294
Definition VehicleDefines.h:130
virtual void SetData(uint32, uint32)
Definition UnitAI.h:219
virtual void AttackStart(Unit *)
Definition UnitAI.cpp:28
uint8 getGender() const
Definition Unit.h:848
void SetFacingToObject(WorldObject *object, Milliseconds timed=0ms)
Definition Unit.cpp:16421
void SetFacingTo(float ori)
Definition Unit.cpp:16411
float GetSpeed(UnitMoveType mtype) const
Definition Unit.cpp:11265
void InterruptNonMeleeSpells(bool withDelayed, uint32 spellid=0, bool withInstant=true, bool bySelf=false)
Definition Unit.cpp:4302
float GetSpellMinRangeForTarget(Unit const *target, SpellInfo const *spellInfo) const
Definition Unit.cpp:11874
Player * GetCharmerOrOwnerPlayerOrPlayerItself() const
Definition Unit.cpp:7698
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:13938
MotionMaster * GetMotionMaster()
Definition Unit.h:1758
void SetUnitMovementFlags(uint32 f)
Definition Unit.h:776
SpellCastResult CastCustomSpell(Unit *victim, uint32 spellId, int32 const *bp0, int32 const *bp1, int32 const *bp2, bool triggered, Item *castItem=nullptr, AuraEffect const *triggeredByAura=nullptr, ObjectGuid originalCaster=ObjectGuid::Empty)
Definition Unit.cpp:1407
bool IsAlive() const
Definition Unit.h:1793
void StopMoving()
Definition Unit.cpp:12997
void SendPlaySpellVisual(uint32 id)
Definition Unit.cpp:15136
bool HasAura(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, ObjectGuid itemCasterGUID=ObjectGuid::Empty, uint8 reqEffMask=0) const
Definition Unit.cpp:5982
virtual void SetSheath(SheathState sheathed)
Definition Unit.h:1777
float GetSpellMaxRangeForTarget(Unit const *target, SpellInfo const *spellInfo) const
Definition Unit.cpp:11854
bool HasUnitMovementFlag(uint32 f) const
Definition Unit.h:774
TransportBase * GetDirectTransport() const
Definition Unit.cpp:14992
void SendMovementFlagUpdate(bool self=false)
Definition Unit.cpp:13051
void EngageWithTarget(Unit *who)
Definition Unit.cpp:7502
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:1350
void RemoveAurasDueToSpell(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, uint8 reqEffMask=0, AuraRemoveMode removeMode=AURA_REMOVE_BY_DEFAULT)
Definition Unit.cpp:5157
void SetSpeed(UnitMoveType mtype, float rate, bool forced=false)
Definition Unit.cpp:11270
ThreatManager & GetThreatMgr()
Definition Unit.h:951
ObjectGuid GetTransGUID() const override
Definition Unit.cpp:14981
bool IsAIEnabled
Definition Unit.h:2097
bool HasUnitState(const uint32 f) const
Definition Unit.h:736
float GetPowerPct(Powers power) const
Definition Unit.h:1137
void SetDisableGravity(bool disable)
Definition Unit.cpp:16462
float GetMeleeRange(Unit const *target) const
Definition Unit.cpp:800
uint32 GetPower(Powers power) const
Definition Unit.h:1135
void CombatStop(bool includingCast=false, bool mutualPvP=true)
Definition Unit.cpp:7469
void KillSelf(bool durabilityLoss=true, WeaponAttackType attackType=BASE_ATTACK, SpellInfo const *spellProto=nullptr, Spell const *spell=nullptr)
Definition Unit.h:1234
bool CanHaveThreatList(bool skipAliveCheck=false) const
Definition Unit.cpp:11394
void SetInFront(WorldObject const *target)
Definition Unit.cpp:16405
bool isDead() const
Definition Unit.h:1795
TempSummon * SummonCreature(uint32 id, const Position &pos, TempSummonType spwtype=TEMPSUMMON_MANUAL_DESPAWN, uint32 despwtime=0, uint32 vehId=0, SummonPropertiesEntry const *properties=nullptr, bool visibleBySummonerOnly=false) const
Definition Object.cpp:2394
Map * FindMap() const
Definition Object.h:626
bool IsWithinLOSInMap(WorldObject const *obj, VMAP::ModelIgnoreFlags ignoreFlags=VMAP::ModelIgnoreFlags::Nothing, LineOfSightChecks checks=LINEOFSIGHT_ALL_CHECKS, Optional< float > collisionHeight={ }, Optional< float > combatReach={ }) const
Definition Object.cpp:1403
void GetNearPoint(WorldObject const *searcher, float &x, float &y, float &z, float searcher_size, float distance2d, float absAngle, float controlZ=0, Position const *startPos=nullptr) const
Definition Object.cpp:2693
void SummonGameObjectGroup(uint8 group, std::list< GameObject * > *list=nullptr)
Definition Object.cpp:2485
bool GetClosePoint(float &x, float &y, float &z, float size, float distance2d=0, float angle=0, WorldObject const *forWho=nullptr, bool force=false) const
Definition Object.cpp:2766
std::string const & GetName() const
Definition Object.h:528
void AddObjectToRemoveList()
Definition Object.cpp:2174
EventProcessor m_Events
Definition Object.h:736
float GetDistance(WorldObject const *obj) const
Definition Object.cpp:1295
uint32 GetAreaId() const
Definition Object.cpp:3120
uint32 GetZoneId() const
Definition Object.cpp:3112
float GetObjectSize() const
Definition Object.cpp:2838
GameObject * SummonGameObject(uint32 entry, float x, float y, float z, float ang, float rotation0, float rotation1, float rotation2, float rotation3, uint32 respawnTime, bool checkTransport=true, GOSummonType summonType=GO_SUMMON_TIMED_OR_CORPSE_DESPAWN)
Definition Object.cpp:2408
void GetRandomPoint(const Position &srcPos, float distance, float &rand_x, float &rand_y, float &rand_z) const
Definition Object.cpp:1558
void SummonCreatureGroup(uint8 group, std::list< TempSummon * > *list=nullptr)
Definition Object.cpp:2471
virtual float GetCombatReach() const
Definition Object.h:506
Creature * SummonTrigger(float x, float y, float z, float ang, uint32 dur, bool setLevel=false, CreatureAI *(*GetAI)(Creature *)=nullptr)
Definition Object.cpp:2443
Player session in the World.
Definition WorldSession.h:384
virtual void SetData(uint32, uint32)
Definition ZoneScript.h:52
virtual void SetGuidData(uint32, ObjectGuid)
Definition ZoneScript.h:45
auto SelectRandomContainerElement(C const &container) -> typename std::add_const< decltype(*std::begin(container))>::type &
Definition Containers.h:133
std::string ToString(Type &&val, Params &&... params)
Definition StringConvert.h:250
Definition ObjectAccessor.h:61
Player * GetPlayer(Map const *, ObjectGuid const &guid)
Definition ObjectAccessor.cpp:220
Definition CreatureData.h:170
uint32 CreatureDisplayID
Definition CreatureData.h:180
float DisplayScale
Definition CreatureData.h:181
Definition CreatureData.h:360
uint32 ItemEntry[MAX_EQUIPMENT_ITEMS]
Definition CreatureData.h:361
float m_positionZ
Definition Position.h:57
float m_positionX
Definition Position.h:55
float GetPositionZ() const
Definition Position.h:123
float m_positionY
Definition Position.h:56
float GetOrientation() const
Definition Position.h:124
void SetOrientation(float orientation)
Definition Position.h:116
float GetPositionX() const
Definition Position.h:121
void GetPosition(float &x, float &y) const
Definition Position.h:126
float GetPositionY() const
Definition Position.h:122
void RelocatePolarOffset(float angle, float dist, float z=0.0f)
Definition Position.cpp:34
float GetAngle(const Position *pos) const
Definition Position.cpp:85
Definition SmartScriptMgr.h:745
struct SmartAction::@75::@98 combatMove
uint32 followState
Definition SmartScriptMgr.h:1454
uint32 visualId
Definition SmartScriptMgr.h:1449
uint32 targetParam2
Definition SmartScriptMgr.h:849
struct SmartAction::@75::@100 incEventPhase
struct SmartAction::@75::@106 killedMonster
SAIBool disableForceDestination
Definition SmartScriptMgr.h:1206
std::array< uint32, SMART_ACTION_PARAM_COUNT > emotes
Definition SmartScriptMgr.h:832
uint32 forcedMovement
Definition SmartScriptMgr.h:1031
uint32 repeatMax
Definition SmartScriptMgr.h:1108
uint32 phaseMin
Definition SmartScriptMgr.h:934
uint32 targetsLimit
Definition SmartScriptMgr.h:840
struct SmartAction::@75::@181 movementSpeed
struct SmartAction::@75::@186 setScale
SAIBool transport
Definition SmartScriptMgr.h:1202
struct SmartAction::@75::@192 wpDataRandom
struct SmartAction::@75::@82 randomSound
struct SmartAction::@75::@120 summonGO
uint32 startAngle
Definition SmartScriptMgr.h:1442
SAIBool reset
Definition SmartScriptMgr.h:1093
std::array< uint32, SMART_ACTION_PARAM_COUNT > actionLists
Definition SmartScriptMgr.h:1156
struct SmartAction::@75::@185 scriptSpawn
uint32 delay
Definition SmartScriptMgr.h:755
struct SmartAction::@75::@163 startClosestWaypoint
uint32 random
Definition SmartScriptMgr.h:1337
uint32 quickChange
Definition SmartScriptMgr.h:1336
uint32 targetParam4
Definition SmartScriptMgr.h:1466
uint32 dist
Definition SmartScriptMgr.h:919
uint32 group
Definition SmartScriptMgr.h:1259
SAIBool disable
Definition SmartScriptMgr.h:1391
struct SmartAction::@75::@180 corpseDelay
struct SmartAction::@75::@194 worldStateScript
struct SmartAction::@75::@111 callHelp
uint32 spell
Definition SmartScriptMgr.h:837
uint32 minHP
Definition SmartScriptMgr.h:986
struct SmartAction::@75::@177 summonVortex
uint32 flags
Definition SmartScriptMgr.h:846
struct SmartAction::@75::@97 autoAttack
SAIBool loot
Definition SmartScriptMgr.h:1509
uint32 distanceBetweenSummons
Definition SmartScriptMgr.h:1352
uint32 data
Definition SmartScriptMgr.h:946
struct SmartAction::@75::@105 randomPhaseRange
uint32 entry
Definition SmartScriptMgr.h:921
struct SmartAction::@75::@91 crossCast
struct SmartAction::@75::@129 setSwim
uint32 quest
Definition SmartScriptMgr.h:816
struct SmartAction::@75::@150 moveToPosTarget
struct SmartAction::@75::@172 orientation
struct SmartAction::@75::@78 simpleTalk
uint32 triggerFlags
Definition SmartScriptMgr.h:839
struct SmartAction::@75::@87 questOffer
uint32 bp1
Definition SmartScriptMgr.h:1367
uint32 distance
Definition SmartScriptMgr.h:779
SAIBool removeObjectFromWorld
Definition SmartScriptMgr.h:981
uint32 min
Definition SmartScriptMgr.h:1105
uint32 spawnTimerMax
Definition SmartScriptMgr.h:1426
uint32 subtract
Definition SmartScriptMgr.h:1094
struct SmartAction::@75::@110 die
uint32 a
Definition SmartScriptMgr.h:1376
struct SmartAction::@75::@151 sendGossipMenu
struct SmartAction::@75::@104 randomPhase
struct SmartAction::@75::@198 setGossipMenu
struct SmartAction::@75::@133 timeEvent
SAIBool invokerGUID
Definition SmartScriptMgr.h:1418
struct SmartAction::@75::@191 wpData
uint32 percent
Definition SmartScriptMgr.h:987
uint32 dec
Definition SmartScriptMgr.h:903
uint32 milliseconds
Definition SmartScriptMgr.h:963
struct SmartAction::@75::@125 item
uint32 summonEntry
Definition SmartScriptMgr.h:1349
struct SmartAction::@75::@84 randomMusic
uint32 followType
Definition SmartScriptMgr.h:1455
uint32 instanceTarget
Definition SmartScriptMgr.h:1386
struct SmartAction::@75::@196 reward
uint32 credit
Definition SmartScriptMgr.h:922
uint32 controlled
Definition SmartScriptMgr.h:1203
uint32 alternative
Definition SmartScriptMgr.h:855
uint32 targetParam1
Definition SmartScriptMgr.h:848
uint32 mapID
Definition SmartScriptMgr.h:1086
uint32 stopMovement
Definition SmartScriptMgr.h:1343
struct SmartAction::@75::@134 movie
struct SmartAction::@75::@94 summonCreature
uint32 charges
Definition SmartScriptMgr.h:914
struct SmartAction::@75::@113 forceDespawn
struct SmartAction::@75::@103 follow
uint32 model
Definition SmartScriptMgr.h:772
uint32 duration
Definition SmartScriptMgr.h:753
SAIBool attackInvoker
Definition SmartScriptMgr.h:868
SAIBool useTalkTarget
Definition SmartScriptMgr.h:754
SAIBool run
Definition SmartScriptMgr.h:1069
struct SmartAction::@75::@176 castCustom
uint32 value
Definition SmartScriptMgr.h:1092
struct SmartAction::@75::@140 timedActionList
uint32 movementExpired
Definition SmartScriptMgr.h:1344
struct SmartAction::@75::@117 moveRandom
uint32 targetParam3
Definition SmartScriptMgr.h:850
uint32 respawnDelay
Definition SmartScriptMgr.h:1427
SAIBool swim
Definition SmartScriptMgr.h:1081
uint32 combatReach
Definition SmartScriptMgr.h:1205
uint32 sound2
Definition SmartScriptMgr.h:785
struct SmartAction::@75::@188 spellVisual
uint32 spawnPos
Definition SmartScriptMgr.h:1307
struct SmartAction::@75::@92 activateObject
struct SmartAction::@75::@167 setHomePos
struct SmartAction::@75::@161 gameEventStop
uint32 pathId2
Definition SmartScriptMgr.h:1283
uint32 creature
Definition SmartScriptMgr.h:771
struct SmartAction::@75::@190 orientationTarget
uint32 spawnTimerMin
Definition SmartScriptMgr.h:1425
struct SmartAction::@75::@132 storeTargets
struct SmartAction::@75::@114 invincHP
uint32 angle
Definition SmartScriptMgr.h:920
uint32 field
Definition SmartScriptMgr.h:945
struct SmartAction::@75::@199 gameobjectGroup
uint32 range
Definition SmartScriptMgr.h:860
struct SmartAction::@75::@95 threatPCT
struct SmartAction::@75::@89 randomEmote
struct SmartAction::@75::@162 gameEventStart
uint32 flag
Definition SmartScriptMgr.h:1126
uint32 sound3
Definition SmartScriptMgr.h:786
uint32 targetsummon
Definition SmartScriptMgr.h:1020
struct SmartAction::@75::@145 jump
uint32 chance
Definition SmartScriptMgr.h:1109
struct SmartAction::@75::@131 setCounter
uint32 state
Definition SmartScriptMgr.h:827
struct SmartAction::@75::@90 cast
struct SmartAction::@75::@108 setInstanceData64
uint32 sound1
Definition SmartScriptMgr.h:784
struct SmartAction::@75::@80 morphOrMount
struct SmartAction::@75::@116 setData
uint32 forceRespawnTimer
Definition SmartScriptMgr.h:980
uint32 speed
Definition SmartScriptMgr.h:1075
uint32 sound4
Definition SmartScriptMgr.h:787
struct SmartAction::@75::@147 flee
uint32 targetType
Definition SmartScriptMgr.h:847
uint32 repetitions
Definition SmartScriptMgr.h:1441
struct SmartAction::@75::@174 coneSummon
uint32 aliveState
Definition SmartScriptMgr.h:924
SAIBool onlySelf
Definition SmartScriptMgr.h:778
uint32 attackScriptOwner
Definition SmartScriptMgr.h:869
uint32 speedxy
Definition SmartScriptMgr.h:1179
uint32 pointId
Definition SmartScriptMgr.h:1201
SAIBool attack
Definition SmartScriptMgr.h:887
uint32 repeatMin
Definition SmartScriptMgr.h:1107
struct SmartAction::@75::@122 wpStart
uint32 scale
Definition SmartScriptMgr.h:1434
SAIBool fly
Definition SmartScriptMgr.h:1074
uint32 textGroupID
Definition SmartScriptMgr.h:752
uint32 castFlags
Definition SmartScriptMgr.h:838
struct SmartAction::@75::@179 disableEvade
std::array< uint32, SMART_ACTION_PARAM_COUNT > phases
Definition SmartScriptMgr.h:929
SAIBool dontDespawn
Definition SmartScriptMgr.h:1429
uint32 turnAngle
Definition SmartScriptMgr.h:1338
uint32 textId
Definition SmartScriptMgr.h:1359
uint32 gossipMenuId
Definition SmartScriptMgr.h:1217
uint32 speedz
Definition SmartScriptMgr.h:1180
SAIBool repeat
Definition SmartScriptMgr.h:1033
struct SmartAction::@75::@173 stopMotion
uint32 gossipNpcTextId
Definition SmartScriptMgr.h:1218
uint32 mask
Definition SmartScriptMgr.h:992
uint32 pathId1
Definition SmartScriptMgr.h:1282
uint32 phi_delta
Definition SmartScriptMgr.h:1379
uint32 count
Definition SmartScriptMgr.h:1054
struct SmartAction::@75::@112 setSheath
uint32 inc
Definition SmartScriptMgr.h:902
uint32 phaseMax
Definition SmartScriptMgr.h:935
struct SmartAction::@75::@130 teleport
uint32 timer
Definition SmartScriptMgr.h:1396
uint32 ContactDistance
Definition SmartScriptMgr.h:1204
struct SmartAction::@75::@79 faction
PathSource pathSource
Definition SmartScriptMgr.h:1286
struct SmartAction::@75::@135 equip
uint32 k
Definition SmartScriptMgr.h:1377
uint32 distanceBetweenRings
Definition SmartScriptMgr.h:1351
uint32 coneLength
Definition SmartScriptMgr.h:1353
uint32 counterId
Definition SmartScriptMgr.h:1091
SAIBool withEmote
Definition SmartScriptMgr.h:969
struct SmartAction::@75::@146 movementFlag
uint32 param
Definition SmartScriptMgr.h:1491
uint32 max
Definition SmartScriptMgr.h:1106
uint32 selfJump
Definition SmartScriptMgr.h:1181
struct SmartAction::@75::@183 cinematic
uint32 maxId
Definition SmartScriptMgr.h:1319
uint32 r_max
Definition SmartScriptMgr.h:1378
struct SmartAction::@75::@136 unitFlag
uint32 speedFraction
Definition SmartScriptMgr.h:1403
struct SmartAction::@75::@88 react
struct SmartAction::@75::@119 setActive
struct SmartAction::@75::@159 creatureGroup
SAIBool fail
Definition SmartScriptMgr.h:1048
struct SmartAction::@75::@124 wpStop
SAIBool directAdd
Definition SmartScriptMgr.h:822
uint32 bp2
Definition SmartScriptMgr.h:1368
uint32 disableGravity
Definition SmartScriptMgr.h:1076
uint32 sound
Definition SmartScriptMgr.h:777
uint32 threatINC
Definition SmartScriptMgr.h:875
uint32 coneAngle
Definition SmartScriptMgr.h:1354
uint32 summonDuration
Definition SmartScriptMgr.h:1350
struct SmartAction::@75::@148 RespawnTarget
struct SmartAction::@75::@175 playerTalk
uint32 threatDEC
Definition SmartScriptMgr.h:876
SAIBool reputation
Definition SmartScriptMgr.h:1508
uint32 stepAngle
Definition SmartScriptMgr.h:1443
struct SmartAction::@75::@153 sendTargetToTarget
uint32 reactState
Definition SmartScriptMgr.h:1036
uint32 speedInteger
Definition SmartScriptMgr.h:1402
struct SmartAction::@75::@77 talk
uint32 index
Definition SmartScriptMgr.h:1419
struct SmartAction::@75::@123 wpPause
struct SmartAction::@75::@83 music
uint32 actionId
Definition SmartScriptMgr.h:1384
struct SmartAction::@75::@169 randomTimedEvent
uint32 despawnTime
Definition SmartScriptMgr.h:1019
struct SmartAction::@75::@128 setFly
uint32 goRespawnTime
Definition SmartScriptMgr.h:1196
struct SmartAction::@75::@115 ingamePhaseMask
uint32 factionID
Definition SmartScriptMgr.h:766
uint32 eventId
Definition SmartScriptMgr.h:1490
struct SmartAction::@75::@189 followGroup
uint32 pathId
Definition SmartScriptMgr.h:1471
SAIBool move
Definition SmartScriptMgr.h:892
struct SmartAction::@75::@178 doAction
struct SmartAction::@75::@149 moveToPos
std::array< uint32, MAX_EQUIPMENT_ITEMS > slots
Definition SmartScriptMgr.h:1121
struct SmartAction::@75::@127 setRun
struct SmartAction::@75::@187 radialSummon
struct SmartAction::@75::@99 setEventPhase
struct SmartAction::@75::@107 setInstanceData
uint32 questID
Definition SmartScriptMgr.h:821
uint32 bp3
Definition SmartScriptMgr.h:1369
uint32 pathID
Definition SmartScriptMgr.h:1032
uint32 emote
Definition SmartScriptMgr.h:811
struct SmartAction::@75::@102 removeAura
uint32 id
Definition SmartScriptMgr.h:1026
uint32 minId
Definition SmartScriptMgr.h:1318
uint32 phase
Definition SmartScriptMgr.h:897
uint32 sheath
Definition SmartScriptMgr.h:974
uint32 isNegative
Definition SmartScriptMgr.h:1385
uint32 creditType
Definition SmartScriptMgr.h:923
struct SmartAction::@75::@141 randTimedActionList
struct SmartAction::@75::@154 setRangedMovement
struct SmartAction::@75::@184 setGuid
Definition SmartScriptMgr.h:205
uint32 repeatMin
Definition SmartScriptMgr.h:216
uint32 repeatMax
Definition SmartScriptMgr.h:217
bool runOnce
Definition SmartScriptMgr.h:2014
uint32 link
Definition SmartScriptMgr.h:1997
bool IsAreatriggerScript() const
Definition SmartScriptMgr.h:2009
uint32 event_id
Definition SmartScriptMgr.h:1996
int32 entryOrGuid
Definition SmartScriptMgr.h:1994
uint32 GetScriptType() const
Definition SmartScriptMgr.h:2004
uint32 GetTargetType() const
Definition SmartScriptMgr.h:2007
uint32 GetActionType() const
Definition SmartScriptMgr.h:2006
struct SmartTarget::@200::@204 unitRange
float o
Definition SmartScriptMgr.h:1604
uint32 maxDist
Definition SmartScriptMgr.h:1610
uint32 range
Definition SmartScriptMgr.h:1731
float x
Definition SmartScriptMgr.h:1604
uint32 self
Definition SmartScriptMgr.h:1733
uint32 amount
Definition SmartScriptMgr.h:1732
struct SmartTarget::@200::@221 randomPoint
float y
Definition SmartScriptMgr.h:1604
float z
Definition SmartScriptMgr.h:1604
Definition WaypointDefines.h:37
float X
Definition WaypointDefines.h:48
float Z
Definition WaypointDefines.h:48
float Y
Definition WaypointDefines.h:48
Definition WaypointDefines.h:60
std::vector< WaypointNode > Nodes
Definition WaypointDefines.h:68