Hi,
I try to get out the enemys level by script as part of an ability/item.
By Yanflys description it should be enemy.level ...but I get the message that enemy is not defined. (in and out of battle)
Maybe someone has a clue to help? 🙁
thx a lot 🙂
$gameTroop.members()[x].level <------- this is in the battle
As far as i know you can't trully give levels to enemies, that's why skills whose formula has a.level on them gets an error.
I've tried this before and all i got were zeros from skills, say may happen with anything else.
That indeed helped a lot! Thx to both of you 🙂
@mrcopra: I actually try to make a actor out of the enemy...works quite fine so far. I just need to reach his enemy index number for the class of the new actor and the name of the enemy...well - for the name. 😀
I tried it the same way like for the level now... Maybe you can give me a hand there 2?
For the ID
$gameActors.actor($gameVariables.value(1)).changeClass( $gameTroop.members()[0].id , false);
Here I get ... cannot read property 'traits' of undefined
For the Name
$gameActors.actor($gameVariables.value(1)).setName($gameTroop.members()[0].originalName);
That sadly gives me a unreadable name in some kind of buggy signs :/
The lvl command allrdy helped me a lot! Thank you 🙂
Try to use "a.level" for damage or healing formulas and you'll see that it won't work.
This is totally virtual.
The plugin will work with attributes that an enemy can have and that's it.
You can use a little trick to get index of enemy so you can use it in formula
$gameTroop.members()[b.index()].level