Jump to content

Recommended Posts

Hello!

 

I want to modify xparams like hit (chance to hit) or cri (critical chance), but I can't seem to find the default formulas~

 

I was searching through Game_BattlerBase but nope ~ or I've overlooked something.

 

Basically I want to know from what are these parameters calculated of and how to change them~

 

To be honest I just want to change only cri xparameter, nothing else.

 

Thanks! ~

Share this post


Link to post
Share on other sites

It's a sum of features.

  def xparam(xparam_id)
    features_sum(FEATURE_XPARAM, xparam_id)
  end

E.g. crit being 2.

 

It grabs all features from equipment, class, actor, enemy, state, etc and grabs all features they have with specific code and id. Crit being code 22 and id 2.

  • Like 1

Share this post


Link to post
Share on other sites

Hmm I see ~ but... Can I add a base value that would be calculated from string?

 

For example, besides these features from equipment and such ~ there would be a base value based on actor's luck ~ how should I go about this?

Share this post


Link to post
Share on other sites

Something like this? (Didn't test, but the idea should be right)

class Game_Actor < Game_Battler
  alias :mrts_xparam :xparam
  def xparam(xparam_id)
    value = mrts_xparam(xparam_id)
    if (xparam_id == 2)
     value += param(7) #or something
    end
    return value
  end
end
  • Like 2

Share this post


Link to post
Share on other sites

Oooh now I see what you mean ~

It works ~ it just need some tweaking~

I think I'll be fine now.

 

Thank you for help!

9RWO0dm.png This thread is closed, due to being solved. If for some reason anybody would like to re-open this thread, just send me a PM. (=

Share this post


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

  • Recently Browsing   0 members

    No registered users viewing this page.

×
Top ArrowTop Arrow Highlighted