Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Attributes/Stats Points Distribution System for RMXP(Solved)

you can do this by scripting.
i cannot open my actor.rxdata files for the parameters(tables) in windows vista so
I am not sure if these are editable with regards to 'adding'.

try this in the script editor though:

PLEASE BACKUP FIRST..

this block is in Game_Actor:

Code:
  def base_int

    n = $data_actors[@actor_id].parameters[5, @level]

    weapon = $data_weapons[@weapon_id]

    armor1 = $data_armors[@armor1_id]

    armor2 = $data_armors[@armor2_id]

    armor3 = $data_armors[@armor3_id]

    armor4 = $data_armors[@armor4_id]

    n += weapon != nil ? weapon.int_plus : 0

    n += armor1 != nil ? armor1.int_plus : 0

    n += armor2 != nil ? armor2.int_plus : 0

    n += armor3 != nil ? armor3.int_plus : 0

    n += armor4 != nil ? armor4.int_plus : 0

    return [[n, 1].max, 999].min

  end

you can another block after this as the basic of charisma.
note that you should number it 6 as a parameter
like this:

Code:
  def base_cha

    n = $data_actors[@actor_id].parameters[6, @level]

    weapon = $data_weapons[@weapon_id]

    armor1 = $data_armors[@armor1_id]

    armor2 = $data_armors[@armor2_id]

    armor3 = $data_armors[@armor3_id]

    armor4 = $data_armors[@armor4_id]

    n += weapon != nil ? weapon.int_plus : 0

    n += armor1 != nil ? armor1.int_plus : 0

    n += armor2 != nil ? armor2.int_plus : 0

    n += armor3 != nil ? armor3.int_plus : 0

    n += armor4 != nil ? armor4.int_plus : 0

    return [[n, 1].max, 999].min

  end

then, in the Game_battler 1 class:
add this to the initialize method:

Code:
@cha_plus = 0    #adds a charisma/cha instance variable

this block is located in the Game_battler class:

Code:
  def int

    n = [[base_int + @int_plus, 1].max, 999].min

    for i in @states

      n *= $data_states[i].int_rate / 100.0

    end

    n = [[Integer(n), 1].max, 999].min

    return n

  end

now, add this:

Code:
  def cha

    n = [[base_cha + @cha_plus, 1].max, 999].min

    for i in @states

      n *= $data_states[i].int_rate / 100.0

    end

    n = [[Integer(n), 1].max, 999].min

    return n

  end

just a hypothesis, backup first before doing this..
 
Just so you know, that's a mighty short time to re-bump things in.

However, I'll help you by asking you this question first:

What do you actually want Charisma to do?

Without an answer to that question, no one can actually help you.
 
Unka Josh":3pc21hhh said:
Just so you know, that's a mighty short time to re-bump things in.

However, I'll help you by asking you this question first:

What do you actually want Charisma to do?

Without an answer to that question, no one can actually help you.

Sorry for constantly bumping.

I have found the script to make attributes,but before I do that,I need stats points distribution system (you have attributes,and when level up,you manually assign points to attributes).I know that it exists for RMVX,but I need one for RMXP.

I would really appreciate that,and maybe give credits to the helper in my game!

For Charisma,I would like it to be an attribute of a character.Higher the charisma,the character has greater chance to make a npc do something player wants in game.
That could be some mathematical formula...

Chance would be shown as percent,like 78%
 
Well, there's an easy way to do this if you want charisma to be a bonus to a variable in game...
Under control variable,
1) press random X...Y [001]
2) then control variable,
add variable [002]
3) If variable [001]= 75
(success)
else
(fail)

or
if you want charisma=character's level
2) add [character]'s level

or if you want charisma to equal character's level*3
2a) set variable [002] to [character]'s level
2b) multiply variable [002] by 3

all variable number's, character's names, etc. can be anything as long as where it says 2 and 2 they must be X and X, not X and Y...
 
teengamer":rdstmmze said:
Well, there's an easy way to do this if you want charisma to be a bonus to a variable in game...
Under control variable,
1) press random X...Y [001]
2) then control variable,
add variable [002]
3) If variable [001]= 75
(success)
else
(fail)

or
if you want charisma=character's level
2) add [character]'s level

or if you want charisma to equal character's level*3
2a) set variable [002] to [character]'s level
2b) multiply variable [002] by 3

all variable number's, character's names, etc. can be anything as long as where it says 2 and 2 they must be X and X, not X and Y...

Thanks.Now I need only stats points distribution system for rmxp.
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top