Making the enemy have the same stats as an actor

CrestB

Villager
Member
Joined
Oct 30, 2016
Messages
29
Reaction score
2
First Language
English
Primarily Uses
RMMV
If I want the player to fight a party member as an enemy
is there a way I could put that party member's stats as that enemy's?
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,959
First Language
English
Primarily Uses
RMMV
So you want to set an enemy's HP, MP, atk, def, matk, mdef, agi and luk to that of a party member at the time you fight it?
 

CrestB

Villager
Member
Joined
Oct 30, 2016
Messages
29
Reaction score
2
First Language
English
Primarily Uses
RMMV
Exactly, sorry if I was alittle vague.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,959
First Language
English
Primarily Uses
RMMV
Do you want it to be a specific actor every time or whoever is occupying a particular party slot when the battle happens?
 

CrestB

Villager
Member
Joined
Oct 30, 2016
Messages
29
Reaction score
2
First Language
English
Primarily Uses
RMMV
Do you want it to be a specific actor every time or whoever is occupying a particular party slot when the battle happens?
A specific actor
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,959
First Language
English
Primarily Uses
RMMV
Okay, here's what you do. Make a troop event in the troop that contains the party member you'll be fighting, and insert the following script call:

Code:
var actor = $gameActors.actor(your actor ID here);
var stats = [actor.hp, actor.mp, actor.atk, actor.def, actor.mdf, actor.agi, actor.luk];
$dataEnemies[ID of your party member monster].params = stats;
Presto, your enemy now has the given actor's stats.
 

CrestB

Villager
Member
Joined
Oct 30, 2016
Messages
29
Reaction score
2
First Language
English
Primarily Uses
RMMV
Not sure it's working did do this right?

Code:
var actor = $gameActors.actor(22);
var stats = [actor.hp, actor.mp, actor.atk, actor.def, actor.mdf, actor.agi, actor.luk];
$dataEnemies[18].params = stats;
18 being the enemy ID
and 22 being the actor ID
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,959
First Language
English
Primarily Uses
RMMV
That should work. What is it not doing?
 

CrestB

Villager
Member
Joined
Oct 30, 2016
Messages
29
Reaction score
2
First Language
English
Primarily Uses
RMMV
I'm testing it as a basic actor, hardly any stats
and applied that code to the monster
and made that Actor monster's stats overpowered
but when I battled it died the monster died in the first couple of hits.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,959
First Language
English
Primarily Uses
RMMV
Note that this code will set the monster's stats to whatever the actor's were at the time of running it. It will overwrite whatever monster stats you've set in the database.
 

CrestB

Villager
Member
Joined
Oct 30, 2016
Messages
29
Reaction score
2
First Language
English
Primarily Uses
RMMV
Alright But I set the Actor's stats high with both their equipment and their class.
when I ran the troop with that script.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,959
First Language
English
Primarily Uses
RMMV
Can you show me a screenshot of your troop event, the enemy and the actor?
 

CrestB

Villager
Member
Joined
Oct 30, 2016
Messages
29
Reaction score
2
First Language
English
Primarily Uses
RMMV

CrestB

Villager
Member
Joined
Oct 30, 2016
Messages
29
Reaction score
2
First Language
English
Primarily Uses
RMMV
Crap, Kinda messed that up.
But I guess you get the point.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,959
First Language
English
Primarily Uses
RMMV
So what should the stats of the Champion class be at level 60?

Oh, FFS. Change the activation condition of your troop event to Turn 0+0*x.
 

CrestB

Villager
Member
Joined
Oct 30, 2016
Messages
29
Reaction score
2
First Language
English
Primarily Uses
RMMV
It was that simple? xD
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD
How many parameters is 'too many'??

Forum statistics

Threads
105,862
Messages
1,017,045
Members
137,569
Latest member
Shtelsky
Top