TryCastSpell
function · spell · primitive
- Address
0x6e4b60· 1685 bytes, up to0x6e51f4- Signature
uint8_t __fastcall (CGUnit *caster, uint32_t spell, CGItem *item, uint64_t target)- Meaning
- Runs the local cast refusals, fills the pending cast, pushes it in flight and sends or raises the cursor
- Confidence
- verified, proof one
- Finding
- spell/cast#cast-attempt-refusals
Finding: Cast attempt refusals in spell: cast
0x6e4b60(caster, spell, item, target guid) returns 1 when the cast was sent or targeting began,
else 0. Its first checks, in order, each return 0:
| check | refused when | report |
|---|---|---|
| inputs | no caster, no record, Attributes & 0x40 | none |
0x494a50(2) | it returns 0 | none |
| profession | Effect[0] 47 | toggles a window, nothing sent |
| dead | 0x605f30 and not Attributes & 0x800000 | 0x13 |
| Attack | Effect[0] 78 | 0x6131a0 on the target, nothing sent |
| looting | Effect[0] 99, 127, or 53, 54, 92 | 0x82, 0x83, 0x61 |
| same spell | spell is the in-flight one | sound igPlayerInviteDecline |
The derivation is in the doc.
Callers 2
- PressPetAction ui
- CastSpellAsActivePlayer spell
Callees 31
- SndInterfacePlayItemSound sound
- SndInterfacePlayInterfaceSound sound
- ClntObjMgrGetActivePlayer objectlayer
- CheckActivePlayer ui
- SignalCurrentSpellCastChanged ui
- ToggleCraftWindow ui
- ToggleTradeSkill ui
- SetCursorMode ui
- SetBaseCursorMode ui
- GameObjectCacheGetRecord dbcache
- IsActivePlayerUnit objectlayer
- IsDeadOrGhost objectlayer
- CheckCasterStateForSpell objectlayer
- CGUnit_C::HasAttackTarget objectlayer
- CGUnit_C::GetLootGuid objectlayer
- CGUnit_C::CanStartMeleeAttack objectlayer
- CGUnit_C::StartAttack objectlayer
- CWorld::CreateMapEntity terrain
- CWorld::SetEntityFlag terrain
- FindSkillLineAbility spell
- ReportCastFailure spell
- IsCastInFlight spell
- CheckSpellTotemsAndReagents spell
- CheckSpellEquippedItem spell
- CheckSpellTargetRange spell
- IsSpellTargeting spell
- CancelCast spell
- SetInFlightSpell spell
- SpellHasAttackStartBits spell
- SpellSuppressesAttackStart spell
- ArmCastTargets spell
Calls and jumps by a bare address, from tables/calls.tsv.