Jump to content
Sign in to follow this  
raydellick

Variable / Event help please!

Recommended Posts

Any incredibly awesome variable / event people out there right now?

I recieved help building an event earlier that forces 2 different actors to match up in exp and level. Example: Actor 1 is lvl 5 and has 1000 exp total and actor 2 joined the party then actor 2 would change from WHATEVER he is at matching exactly those numbers if he was lower. Vice versa.

It works perfectly...Even tested the opposite direction. Awesome. Good to go...The first time its run. It even runs perfectly switching back to the other character AGAIN. But if I run it a 2nd time either direction...

All of a sudden whatever actor is switched out gains exp. There is nothing in the variable that designates an increase for either actor OUTSIDE of matching up to whoever is highest. And this increase in exp continues with every switch in/out from then on.

Here is the event

 @>Control Variables: [0007:Actor 1 Exp] = [Actor 1]'s EXP
 @>Control Variables: [0009:Actor 1 Level] = [Actor 1]'s Level
 @>Control Variables: [0008:Actor 2 Exp] = [Actor 2]'s EXP
 @>Control Variables: [0011:Actor 2 Level] = [Actor 2]'s Level
 @>Conditional Branch: Variable [0007:Actor 1's Exp] > Variable [[0007:Actor 2's Exp]
      @>Control Variables: [0010:XP Difference] += Variable [Actor 1]'s EXP
      @>Control Variables: [0010:XP Difference] += Variable [Actor 2]'s EXP
      @>Change EXP: [Actor 1], + Variable [0010:XP Difference]
      @>
      Else
      @>Control Variables: [0010:XP Difference] += Variable [Actor 2]'s EXP
      @>Control Variables: [0010:XP Difference] += Variable [Actor 1]'s EXP
      @>Change EXP: [Actor 2], + Variable [0010:XP Difference]
      @>
      Branch End


What would cause the experience gain from THAT event?

Share this post


Link to post
Share on other sites

Are you sure that's how you set up the event? Because that's wrong. What you're doing according to what you wrote is this:

You add together the experience of the two characters and then give the combined experience to the one with more experience, making the difference even greater.

 

You should provide a screenshot of the event to show us exactly how you set it up.

Share this post


Link to post
Share on other sites

@raydellick, please don't double post within 72 hours. I have merged your posts now.

Share this post


Link to post
Share on other sites

Okay, that's better. I see one mistake with your event:

In the first part of the conditional branch if Rayd has more experience than Animal you increase Rayd's experience. You should be increasing Animal's.

 

The second part of the conditional branch is fine.

Share this post


Link to post
Share on other sites

It is correct sorry.

 

Both of the characters names are the same lol...And I double checked to make sure the right ones were in the right places.

 

He transforms into different graphics/classes which normally wouldnt be an issue and I wouldnt need this script at all...However I need his equipment to change from whatever he has equipped to this other set and then if he transforms back to re-equip what ever he had before which I cannot find an event for. Outside of what you saw what else would be increasing an exp gain?

Share this post


Link to post
Share on other sites

You don't really need to do all this if you just want to change class/graphics and equipment of one actor.

To change his gear, you need first to give him the armor (Party>Change Armor), then you force equip them on him (Actor>Change Equipment).

When you change it back to normal, you do the inverse, unequiping the armor first, then removing it from inventory.

Share this post


Link to post
Share on other sites

This one is pretty easy.

 

Try either setting XP Difference to 0 at the start of the contents or setting the XP Difference variable instead of adding to it.

 

The variable doesn't initialize back to 0. That's something you have to do. So, you have a residual number hanging around that XP Difference variable every time you use it.

Share this post


Link to post
Share on other sites

Hi raydellick! Please don't forget to tag your topic, thanks ^-^

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
Top ArrowTop Arrow Highlighted