258 char* posX = strtok(
NULL,
" ");
259 char* posY = strtok(
NULL,
" ");
260 char* posZ = strtok(
NULL,
" ");
262 if (!posX || !posY || !posZ)
265 float x = float(atof(posX));
266 float y = float(atof(posY));
267 float z = float(atof(posZ));
269 char* triggeredStr = strtok(
NULL,
" ");
272 int l = strlen(triggeredStr);
273 if (strncmp(triggeredStr,
"triggered", l) != 0)
277 bool triggered = (triggeredStr !=
NULL);
279 caster->
CastSpell(x, y, z, spellId, triggered);
void SetSentErrorMessage(bool val)
Definition: Chat.h:138
Unit * getSelectedUnit()
Definition: Chat.cpp:591
Definition: Language.h:32
arena_t NULL
Definition: jemalloc_internal.h:624
G3D::int16 z
Definition: Vector3int16.h:46
uint32_t uint32
Definition: Define.h:150
G3D::int16 y
Definition: Vector2int16.h:38
uint32 extractSpellIdFromLink(char *text)
Definition: Chat.cpp:806
G3D::int16 x
Definition: Vector2int16.h:37
static bool CheckSpellExistsAndIsValid(ChatHandler *handler, uint32 spellId)
Definition: cs_cast.cpp:54
virtual void SendSysMessage(char const *str, bool escapeCharacters=false)
Definition: Chat.cpp:152
void CastSpell(SpellCastTargets const &targets, SpellInfo const *spellInfo, CustomSpellValues const *value, TriggerCastFlags triggerFlags=TRIGGERED_NONE, Item *castItem=NULL, AuraEffect const *triggeredByAura=NULL, ObjectGuid originalCaster=ObjectGuid::Empty)
Definition: Unit.cpp:869