Is it possible to script check if actor is at a party?

Is there a script to check if the party has an actor with ID (x)?
ex) if actor A has in a party. in this case, the Actor ID number is 4.
check Actor 4 in party.

I know I can check that the actor is at the party in the conditional branch, but I'm getting too messy with the conditional branch because I have to put a lot of lists in one event.

"$gameSwitches.value(3) === false"
I think can check switch on/off like this, but I'm not sure if the actor is in the party.

I don't know if it will help, but it's for use in HIME's Hidden Choice Conditions.
In the HIME plugin, if choice 3 is hidden when switch 2 is OFF.
In this case, 『 hide_choice(3, "$gameSwitches.value(2) === false") 』 uses this script.
$gameParty.members().contains($gameActors.actor(4))
this?

would return true if actor 4 is in party, false if not in the party.
$gameParty.members().contains($gameActors.actor(4))
this?

would return true if actor 4 is in party, false if not in the party.

Yes thx!

Original thread: https://forums.rpgmakerweb.com/threads/is-it-possible-to-script-check-if-actor-is-at-a-party.122571/