MZ Visustella ATB Plugin - How to check if a target is in a casting state?

Hey yall, just trying to see if there's a way to use a scriptcall in the conditional branch to check if the target of a skill/item is in the Casting stage of their action.
Yeah, they have battler.isAtbCastingState() (change the battler reference). Don't know how it's different from checking battler._tpbState === "casting"
Yeah, they have battler.isAtbCastingState() (change the battler reference). Don't know how it's different from checking battler._tpbState === "casting"

I tried changing to "target.isAtbCastingState()" but that doesn't seem to be recognized.
Where are you using the notetag (edit: script)? It would be 'target' inside most VS notetags. If you're using it in a common event, if they're updated already, you can use Last Actor Enemy Id / Last Target Enemy Index. So I think it's like, actors/enemies:
$gameActors.actor($gameTemp.lastActionData(4)).isAtbCastingState()
$gameTroop.members()[$gameTemp.lastActionData(5)-1].isAtbCastingState()
Depending on where used, you can also get the target with BattleManager._targets[0].isAtbCastingState()

EDIT: fixed wrong syntax with $gameTroop.members()
Where are you using the notetag (edit: script)? It would be 'target' inside most VS notetags. If you're using it in a common event, if they're updated already, you can use Last Actor Enemy Id / Last Target Enemy Index. So I think it's like, actors/enemies:
$gameActors.actor($gameTemp.lastActionData(4)).isAtbCastingState()
$gameTroop.members()[$gameTemp.lastActionData(5)-1].isAtbCastingState()
Depending on where used, you can also get the target with BattleManager._targets[0].isAtbCastingState()

EDIT: fixed wrong syntax with $gameTroop.members()

Lol should have realized that using a common event would have work differently then if it was in the battle event. But yes this worked perfectly! Thank you for the help!

Original thread: https://forums.rpgmakerweb.com/threads/visustella-atb-plugin-how-to-check-if-a-target-is-in-a-casting-state.181148/