Actor Parameters

How do I access/ alter a $game_party.members.param

this is what i am using right now

$game_party.members[$game_system.leveling_actor].mhp += @temp_mhp unless $game_party.members[$game_system.leveling_actor] == nil$game_party.members[0].mhp += @temp_mhp if $game_party.members[$game_system.leveling_actor] == nil I have also tryed

Code:
$game_party.members[$game_system.leveling_actor].param(0)+= @temp_mhp unless $game_party.members[$game_system.leveling_actor] == nil$game_party.members[0].param(0) += @temp_mhp if $game_party.members[$game_system.leveling_actor] == nil
Don't alter params directly.

Add them to param_plus.

Code:
alias :old_param_plus :param_plusdef param_plus(param_id)  return  old_param_plus + @your_extra_stuff[param_id]end
Where your extra stuff is whatever you want it to be.
Thank you Tsukihime.

So how would I implement that into the method above.

How would I write it out to add $game_party_member.temp_mhp to $game_party_member.param_plus[0]

Would the numbers remain added to the parameter if i reset $game_party_member.temp_mhp to 0 after?
How would I write it out to add $game_party_member.temp_mhp to $game_party_member.param_plus[0]
I don't know, you could just say

def param_plus(param_id) old_param_plus(param_id) + temp_params(param_id)enddef temp_params(param_id) if param_id == 0 return temp_mhp endendUp to you how you want to design it.
Would the numbers remain added to the parameter if i reset $game_party_member.temp_mhp to 0 after?
No, the values are re-calculated everytime, so if your thing says 0, your HP will go back down.
so with that said, should I set up a var like $game_party_member.added_mhp?

Then to add, have the @temp_mhp add to $game_party_member.added_mhp on ok?
You could do

class Game_Actor attr_reader :temp_params alias 😮ld_init :initialize def initialize(*args) @temp_params = [0, 0, 0, 0, 0, 0, 0, 0] old_init(*args) end alias 😮ld_param_plus 😛aram_plus def param_plus(param_id) old_param_plus(param_id) + temp_params[param_id] endendThen you can access temp_params directly and change it all you like.Which is questionable design but it seems like you want to modify it directly.
I do. Thank you Tsukihime.

This is how I set it up now

This is the method to add the stats from the menu.

But I am getting an error, noted below.

  #--------------------------------------------------------------------------  # * Add the temp stats to Actor Stats  #--------------------------------------------------------------------------   def add_temp_stats    i = 0    ii = 0    iii = 0    iv = 0    actor = $game_party.members[$game_system.leveling_actor]    temp_param = []    #~  Fill array with temp params for disposal    8.times ={    temp_param = actor.temp_param    #<----- unexpected '\n'    i += 1    }#~  Add the values of the temp param elements    8.times ={    temp_param[ii] + temp_param[ii - 1] unless ii == 0    ii += 1    }#~  Add Temp params to the added params    8.times ={      $game_party.members[$game_system.leveling_actor].added_params(iii) unless $game_party.members[$game_system.leveling_actor] == nil      $game_party.members[0].added_params(iii) if $game_party.members[$game_system.leveling_actor] == nil      iii += 1    }    #~  Add added params to the param +    8.times ={      $game_party.members[$game_system.leveling_actor].param_plus(iv) unless $game_party.members[$game_system.leveling_actor] == nil      $game_party.members[0].param_plus(iv) if $game_party.members[$game_system.leveling_actor] == nil      iv += 1    }    #~  Resets temp stats to 0    reset_temp_stats  end[\code]This is how my game actor is set up.

Code:
#==============================================================================# ** Game_Actor#------------------------------------------------------------------------------#  This class handles actors. It is used within the Game_Actors class# ($game_actors) and is also referenced from the Game_Party class ($game_party).#==============================================================================class Game_Actor < Game_Battler  #--------------------------------------------------------------------------  # * Includes Module's Variables With Class  #--------------------------------------------------------------------------   include V_Level_Up_Stats::Specs   #--------------------------------------------------------------------------  # * Public Instance Variables  #--------------------------------------------------------------------------   attr_accessor :lvupp  attr_accessor :added_param[]  attr_accessor :temp_param[]   #--------------------------------------------------------------------------  # * For Creating An Alias  #--------------------------------------------------------------------------   alias v_lv_up_stats_gameactor_init_322875287                     initialize   #--------------------------------------------------------------------------  # * Object Initialization  #--------------------------------------------------------------------------   def initialize(actor_id)    super()    @lvupp = Points_Per_Level    @added_param = [0, 0, 0, 0, 0, 0, 0, 0]    @temp_param = [0, 0, 0, 0, 0, 0, 0, 0]    v_lv_up_stats_gameactor_init_322875287(actor_id)  end   #--------------------------------------------------------------------------  # * For Creating An Alias  #--------------------------------------------------------------------------   alias v_lv_up_stats_gameactor_param_plus_3228                    param_plus  #--------------------------------------------------------------------------  # * Altering Param +  #--------------------------------------------------------------------------   def param_plus(param_id)    return  old_param_plus(param_id) + @added_param[param_id]  end   #--------------------------------------------------------------------------  # * Processing Added Param  #--------------------------------------------------------------------------   def added_params(param_id)    return @added_param[param_id] + @temp_param[param_id]      end   #--------------------------------------------------------------------------  # * For Creating An Alias  #--------------------------------------------------------------------------   alias v_lv_up_ga_lu_74543335                                       level_up   #--------------------------------------------------------------------------  # * Level Up  #--------------------------------------------------------------------------  def level_up    @level += 1    SceneManager.goto(Scene_Level_Up_Stats)    v_lv_up_ga_lu_74543335()  end end
 
8.times will go from 1 to 8. Your array goes from element 0 to element 7. Try using [i - 1] instead of
I'm just doing this now i and it's not returning any error but it is not accually changing any stats

is this just to access them? 

Code:
        8.times {|i| actor.added_params(i) } unless actor == nil        8.times {|i| $game_party.members[0].param_plus(i) } if actor == nil        8.times {|ii| actor.param_plus(ii) } unless actor == nil        8.times {|ii| $game_party.members[0].param_plus(ii) } if actor == nil
8.times does actually iterate 0 to 7.

Remove the square brackets from your attr_accessors

Code:
  attr_accessor :added_param  attr_accessor :temp_param
Although I'm not really sure what you are trying to accomplish with the first part of the script. You have several lines that retrieve values and do nothing with them, and the entire method itself does not pass any values along to outside variables nor is it explicitly returning any. If you want to flush the temp params or added params, just set the array to [0, 0, 0, 0, 0, 0, 0, 0] and they will stop being added to the values.
actually I misread, and though you were iterating over i, but you weren't. Sorry.
That's ok Shaz.

I figured it out thanks everyone.

Original thread: https://forums.rpgmakerweb.com/threads/actor-parameters.16046/