Displaying Actors in Battle (yes, again, one of these...)

I know this must get asked a lot, but how may you display the actors in the battle screen of VX Ace? Maybe more precisely, what must be done to do so? I know there are a lot of scripts and engines out there that modify the battle system to work this way, but I am more interested in simply manually editing the code as to display the actor sprites.

What I have so far:

There is already a "dummy" actor sprite that is refreshed, updated, and disposed properly, except that the use_sprite? boolean is set to false, because its an actor.

However, I have set this variable to true, which causes the game to get an image for the actor.

Strangely, the only way to make the actor appear is by having the game ignore the update_origin method for the Sprite_Battler class

Here's the excerpt of the class that presents the situation

class Sprite_Battler < Sprite_Base .... #-------------------------------------------------------------------------- # * Frame Update #-------------------------------------------------------------------------- def update super if @battler @use_sprite = @battler.use_sprite? if @use_sprite update_bitmap #update_origin #not sure why I have to ignore this method... update_position end setup_new_effect setup_new_animation update_effect else self.bitmap = nil @effect_type = nil end end ....  #--------------------------------------------------------------------------

  # * Update Origin

  #--------------------------------------------------------------------------

  def update_origin

    if bitmap

      self.ox = bitmap.width / 2

      self.oy = bitmap.height

#perhaps it's pushing the sprite off the screen?

    end

  end

....

end

Seriously, when I ignore this method, the actor is displayed. If I don't ignore it, then the actor sprite disappears. The enemy sprites appear regardless. All of the battlers' origins are messed up because of this, though...

Any ideas, explanations, or modifications on how to fix this issue and display these sprites would be appreciated!
Whoops, that code wasn't supposed to end up like that...

Hopefully it's still legible.
why not look at battler scripts out there... try looking at Yanfly's visual battlers for example


anyway on your code, you'd need to probably adjust the ox and oy depending on the actor... try putting /2 too on the oy
I've moved this thread to RGSSx Script Support. Please be sure to post your threads in the correct forum next time. Thank you.


Maximus32, please avoid double posting, as it is against the forum rules. You can review our forum rules here. Thank you.
Alright, thank you for the info, Shaz.

Adjusting the oy component as you suggested worked. It seems the sprite was off screen after all...

I do appreciate the engines and script extensions (and I am using a few already), it's just that I like to crack the code myself for understanding.

Thus, my issue has been resolved. Thanks!
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.

Original thread: https://forums.rpgmakerweb.com/threads/displaying-actors-in-battle-yes-again-one-of-these.25358/