Script to find the ID of the actor that an item was used on

Hello! I'd like to make a 'rename' item. When the item is used on a party member, it will open the rename screen for that party member.

For example, the player has characters 1-20. They use this item on actor 18, and the name input screen opens for actor 18.

I thought it could be done setting the item to run a common event. The event having a script to set a variable to the actor the item was used on, and then use the variable to open the rename screen... But I am struggling. (ᴗ_ ᴗ。) Any help is deeply appreciated.
you can do it simpler without any script.

create an invisible "target" state - no effect, no messages, no icon etc.
have this state apply by the item as an effect.

Then, in the common event check every actor for the state with conditional branch.
and in each conditional branch, make the rename for that actor followed by removing the state.
That'll do it! It's working, thank you very much!

Original thread: https://forums.rpgmakerweb.com/threads/script-to-find-the-id-of-the-actor-that-an-item-was-used-on.169723/