Need help with a script call for a conditional

So I'm trying to figure out the script call for this if anyone can help that would be great. I'm trying to do something like
if actor (variable)'s class is knight do something but i can't figure out how to do it.
$gameActors.actor(ACTOR_ID).isClass($dataClasses[CLASS_ID])

Example: $gameActors.actor(3).isClass($dataClasses[1]). Checks if the actor with id 3 has the class with id 1

You can insert this into a conditional branch as a script.
$gameActors.actor(ACTOR_ID).isClass($dataClasses[CLASS_ID])

Example: $gameActors.actor(3).isClass($dataClasses[1]). Checks if the actor with id 3 has the class with id 1

You can insert this into a conditional branch as a script.
Worked like a charm thank you.
no problem!🙂

Just a quick tip. Use the @Name to reference someone's post instead of quoting it. 👍

Original thread: https://forums.rpgmakerweb.com/threads/need-help-with-a-script-call-for-a-conditional.79033/