Print enemy states to console.

Status
Not open for further replies.

Leah Prime

Intermediate Eventomancer
Veteran
Joined
Sep 14, 2013
Messages
54
Reaction score
0
First Language
English
Primarily Uses
RMMV
Hi.

How can i print all of an enemies states to the console?

would be really helpfull when debugging.

Thanks!
 

Engr. Adiktuzmiko

Chemical Engineer, Game Developer, Using BlinkBoy'
Veteran
Joined
May 15, 2012
Messages
14,682
Reaction score
3,003
First Language
Tagalog
Primarily Uses
RMVXA
enemy.states.each {|state| p state.name}

I think that would work
 
Last edited by a moderator:

Leah Prime

Intermediate Eventomancer
Veteran
Joined
Sep 14, 2013
Messages
54
Reaction score
0
First Language
English
Primarily Uses
RMMV
Bit of a late reply but....

i got this error when runing the script.

 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
40,098
Reaction score
13,704
First Language
English
Primarily Uses
RMMV
Where are you calling this from? It will only work if you run it in a battle event.

Code:
$game_troop.members.each {|enemy|  p enemy.name  enemy.states.each {|state| p state.name}}
 
Last edited by a moderator:

Leah Prime

Intermediate Eventomancer
Veteran
Joined
Sep 14, 2013
Messages
54
Reaction score
0
First Language
English
Primarily Uses
RMMV
Where are you calling this from? It will only work if you run it in a battle event.

$game_troop.members.each {|enemy| p enemy.name enemy.states.each {|state| p state.name}}
Thanks muchly, that worked.

i was totally running it from a battle event the entire time tho.
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
40,098
Reaction score
13,704
First Language
English
Primarily Uses
RMMV
This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.
 
Status
Not open for further replies.

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

Latest Threads

Latest Posts

Latest Profile Posts

How many parameters is 'too many'??
Yay, now back in action Happy Christmas time, coming back!






Back in action to develop the indie game that has been long overdue... Final Fallacy. A game that keeps on giving! The development never ends as the developer thinks to be the smart cookie by coming back and beginning by saying... "Oh bother, this indie game has been long overdue..." How could one resist such? No-one c
So I was playing with filters and this looked interesting...

Versus the normal look...

Kind of gives a very different feel. :LZSexcite:
To whom ever person or persons who re-did the DS/DS+ asset packs for MV (as in, they are all 48x48, and not just x2 the pixel scale) .... THANK-YOU!!!!!!!!! XwwwwX

Forum statistics

Threads
105,849
Messages
1,016,977
Members
137,563
Latest member
cexojow
Top