How to check if actor has certain stat(s) with RGSS? - Printable Version +- Save-Point (https://www.save-point.org) +-- Forum: Games Development (https://www.save-point.org/forum-4.html) +--- Forum: Code Support (https://www.save-point.org/forum-20.html) +--- Thread: How to check if actor has certain stat(s) with RGSS? (/thread-2920.html) |
How to check if actor has certain stat(s) with RGSS? - Twin Matrix - 01-03-2009 How to check if actor has certain stat(s) with RGSS? ^^ I didn't get further than if $game_actor[1] ..lol. ^^ [Resolved] How to check if actor has certain stat(s) with RGSS? - DerVVulfman - 01-03-2009 My dear, I am glad you asked. You can access values like this $game_actors[index].name ... the actual character name $game_actors[index].character_name ... the characterset used $game_actors[index].character_hue ... the 'adjusted' hue of the characterset $game_actors[index].class_id ... the class ID value $game_actors[index].weapon_id ... the ID of the weapon $game_actors[index].armor1_id ... the ID of the shield $game_actors[index].armor2_id ... the ID of the helmet $game_actors[index].armor3_id ... the ID of the body armor $game_actors[index].armor4_id ... the ID of the accessory $game_actors[index].level ... the level $game_actors[index].exp ... the experience points $game_actors[index].skills ... a hash array of your skills. $game_actors[index].hp ... the current HP for your character $game_actors[index].sp ... the current SP for your character $game_actors[index].maxhp ... the maximum HP for your character $game_actors[index].maxsp ... the maximum SP for your character $game_actors[index].base_str ... the strength (based on all equipment n etc) $game_actors[index].base_dex ... the dexterity score $game_actors[index].base_agi ... the agility score $game_actors[index].base_int ... the intelligence score $game_actors[index].base_atk ... the attack strength $game_actors[index].base_pdef ... the physical defense value $game_actors[index].base_mdef ... the magical defense value $game_actors[index].base_eva ... the evasion value Others are available, just by looking at the def/methods in Game_Actor, be it battle animation ID values or state effects or the like. [Resolved] How to check if actor has certain stat(s) with RGSS? - Twin Matrix - 01-04-2009 Hehe. ^^ Well, I got that far, but there are 5 different things with "state" in them. Which one would I need, and what rgss command? I'm guessing ".include?(2)" wouldn't work, for, say, poisoned? [Resolved] How to check if actor has certain stat(s) with RGSS? - DerVVulfman - 01-04-2009 Something like... $game_actors[index].states.include?(3) 3 is the ID number for 'Venom' in the database. At least, I think you would be using the ID numbers [Resolved] How to check if actor has certain stat(s) with RGSS? - Twin Matrix - 01-04-2009 Cool, it works. ^^ Thanks! |