Any Character Item Effect

Basically, I have a item that can randomly effect anyone, whether it's a enemy or a ally(or even you).

But the only options allow me to either let it effect only the enemies or only effect the allies.

What can I do?
Make an Effect that calls a Common Event.
Set a variable to a random value between 1 and 100. Name the variable AllyOrEnemy
Then make a Conditional Branch.
If AllyOrEnemy >50 Then
Do on enemies
ELSE
Do on Allies
End
You could refine that conditional in all sorts of ways e.g.
0-10 ~ one enemy
11-20 ~ two enemies
21-30 ~ three enemies
31-40 ~ four enemies
41-50 ~ all enemies

You could then differentiate the 51-100 block in the same way for allies, including having one mini-block for 'User'.

That way, the random effect could be as finely grained as you want.

Original thread: https://forums.rpgmakerweb.com/threads/any-character-item-effect.93904/