Checking for actor's parameters

I'm working on a stat-checking system that hearkens to western RPG's where some events and dialogue options
check a party members relevant attributes to measure success in a particular task like bashing a lock to a chest, picking a lock or persuading NPC's.

I got most of the bits down.
I would set a variable that matches an actors current parameter (which can be any stat like Strength or Agility) then set another
variable I call "Dice" to be randomly set between 0 and any other number of my choice.

If that "dice" lands anywhere within the determined actor's stat, the player succeeds at a given task.

However, I found out it isn't so easy and I clearly have to type in a script command to define a particular actors stat.

I just need some simple instructions on how to do that.
Thanks.
Whenever searching for a variable about game actors or party members, console (f8 once you launch your game) is your friend.
For example typing in $gameActors.actor(1) shows all info about actor 1.
$gameParty.members prints you all members of the party and you can read all info you need about them. It is an array, so if you need info about concrete party member, simply use $gameParty.members[0] for the first party member, etc.
Example:
I want to determine for my event if first party member has high enough level, but don't remember the exact code for it. So I'll launch the game, open the console, type in $gameParty.members[0] and scroll through his properties until I see "level: 1". This tells me that the full code I need is $gameParty.members[0].level
I am telling you like this, because you posted this in Learning javascript and finding actor's exact properties for stats is pretty much a similar thing, although maybe a bit more difficult. So to make it like learning, I typed in a hint, but not the exact solution.
Don't forget the () for $gameParty.members(), because it is a function. 🙂

Original thread: https://forums.rpgmakerweb.com/threads/checking-for-actors-parameters.82887/