Creating an item that will level up the target actor only

Status
Not open for further replies.

Bonkers

Get ready to be Wowed!
Restaff
Joined
May 26, 2013
Messages
2,941
Reaction score
2,897
First Language
English
Primarily Uses
RMMV
I'd like to create an item that levels up the user, but from the tutorial I played the level up potion for the student was labeled as "Entire party" for the target.

Can I make a common event that processes target selected to level up?

Is there a way to set an actor that uses an item into a variable?

Thank you in advance.
 

Engr. Adiktuzmiko

Chemical Engineer, Game Developer, Using BlinkBoy'
Veteran
Joined
May 15, 2012
Messages
14,682
Reaction score
3,003
First Language
Tagalog
Primarily Uses
RMVXA
you can use the damage formula for the item to set a variable equal to the actor id...


if you want the target just put this on the damage formula


$game_variables[id] = b.actor.actor_id ; formula


id => index of the game variable to store the actor id


formula => damage formula in case you're using one


*use a instead of b if you want the user


then just use that variable to level up the actor using a common event


Or you can use this directly on the formula bar


b.actor.change_level(b.actor.level + value, false)
 
Last edited by a moderator:

Bonkers

Get ready to be Wowed!
Restaff
Joined
May 26, 2013
Messages
2,941
Reaction score
2,897
First Language
English
Primarily Uses
RMMV
Thank you for the quick response.  

When I tried the first method I entered in a variable used in the common event the item calls, I got the following results:  The entire party leveled, not just the user.  I had it tagged with "show message upon level up".

I attempted replacing b with a and got the same results.  I made an NPC to show me the value of that variable after the item was used and got 0, does this mean the variable is not storing the actor id correctly?

Afterwards I  tried the second method and used the b.actor.change_level(b.actor.level + 1, false) and their level remained the same.

I must be doing something wrong.  Would it help to show screen shots of the process in an effort to better understand my mistake?

 
 

Xypher

Veteran
Veteran
Joined
Apr 1, 2012
Messages
148
Reaction score
26
Primarily Uses
it would be b.id or b.change_level(b.level + 1, false)
 

Bonkers

Get ready to be Wowed!
Restaff
Joined
May 26, 2013
Messages
2,941
Reaction score
2,897
First Language
English
Primarily Uses
RMMV
That did it Xypher, thank you.  It's working beautifully now.
 

Celianna

Tileset artist
Veteran
Joined
Mar 1, 2012
Messages
10,557
Reaction score
5,592
First Language
Dutch
Primarily Uses
RMMV
This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.
 
Status
Not open for further replies.

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD
How many parameters is 'too many'??

Forum statistics

Threads
105,864
Messages
1,017,056
Members
137,573
Latest member
nikisknight
Top