Hi!
I have a common event, which applies states too enemies.
However, the message set too be displayed upon state application does not show.
is there any way I can manually write too the battle log?
Thanks!
I'm not sure if it's necessary to try to write straight to the battle log in this instance, but I could be wrong. If you could post screenshots of the specific state page and common event, it would be easier to troubleshoot.
Ohh, ok, gotcha! In that case, do this:
if !$game_troop.members.empty? $game_troop.members.each do |member| state_num = 8 # set this to the number of states you have s = rand(max=state_num) # randomize which state is applied member.add_state[50+s] # add the state endendIf you want it to select between specific states (ie. only A1 and B1) narrow the range and group those states together.
Now i get this error.
script 'Game_interpereter' like 1411: ArgumentError occured
wrong number of arguments (0 for 1)
also, that script seems too be adding a random state too each enemy
Instead of random, I want it too be alternating between enemies. like enemy index 1 gets 51, enemy index 2 gets 52, enemy index 3 gets 51, etc.
ie: enemy index 1 gets state 51, enemy index 2 gets state 52, enemy
So after spending a bunch of time looking through code trying to find out why the state text doesn't show up when applied through a common event, I came up with a much easier way to do what you want :S.
Just put this line into the Formula: line of your skill:
b.add_state(52 - (b.index % 2)); 0Set the state you want to apply to the first enemy as 51 and the state you want to apply to the next enemy as 52. It will then cycle between the two states and add them to all enemies.
I actually decided too not use this skill in the end.
But this information will surely prove useful later, thanks!
just because it bugs me every time I read it,
too = as well. Drop an o every time you write it (the word is to, not too), because you're making me concentrate on your mis-spelling rather than your issue.
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.