Item with different effects depending on user?

GammaVector

Veteran
Veteran
Joined
Feb 12, 2014
Messages
126
Reaction score
50
First Language
English
Primarily Uses
RMMZ
Okay, so. I have a consumable item which calls a common event upon use. I want this item to to have different effects depending upon who it's used on. Is there ANY possible way to do this? I feel like there should be some kind of script call that can tell me what actor the item was used on...But I don't have the foggiest idea what it might be.
 

caethyril

^_^
Veteran
Joined
Feb 21, 2018
Messages
2,419
Reaction score
1,830
First Language
EN
Primarily Uses
RMMZ
In your event you can use the option under Control Variables > Game Data > Last to get the most recent target actor ID, then check that using a Conditional Branch, e.g.
Code:
◆Control Variables:#0010 actor ID = Last Target Actor ID
◆If:actor ID = 1
  ◆Text:None, None, Window, Bottom
  :    :Target was actor 1.
  ◆
:End
◆If:actor ID = 2
  ◆Text:None, None, Window, Bottom
  :    :Target was actor 2.
  ◆
:End
◆Comment:etc
 

GammaVector

Veteran
Veteran
Joined
Feb 12, 2014
Messages
126
Reaction score
50
First Language
English
Primarily Uses
RMMZ
In your event you can use the option under Control Variables > Game Data > Last to get the most recent target actor ID, then check that using a Conditional Branch, e.g.
Code:
◆Control Variables:#0010 actor ID = Last Target Actor ID
◆If:actor ID = 1
  ◆Text:None, None, Window, Bottom
  :    :Target was actor 1.
  ◆
:End
◆If:actor ID = 2
  ◆Text:None, None, Window, Bottom
  :    :Target was actor 2.
  ◆
:End
◆Comment:etc

Good lord, I feel like such an idiot for not realizing it was Right There. Thanks very much for the assist.
 

Latest Threads

Latest Posts

Latest Profile Posts

here's another RPG Maker remake idea: "Plumbers Don't Wear Ties". I'll salute to whomever does this
I won't finish it today, I only will have time to work on that next Saturday, what a shame... :(
I made something for @LittenDev [as he requested]
It's been a weird while. I've been so torn down that even playing video games has been something I avoided. But I shouldn't forget two things. One, I love RPG Maker for a reason. Two, only way to eat an elephant is a bite at a time.

Forum statistics

Threads
111,385
Messages
1,060,721
Members
144,728
Latest member
Izaya_Nozomu
Top