Error in Ace Battle Engine

I couldn't find the official Ace Battle Engine thread so I guess I'm posting this here. I get this error message when I use the script:

59792-a95ea348b142d6e81519d72128bfc6ab.jpg


This happens whenever I close a menu window in battle, such as the equip window, the save window or the items window. It also happens with script windows like bestuaries and such. It's a pity, since this script seems really cool to use.

Btw the script is this in case you don't know it: https://yanflychannel.wordpress.com/rmvxa/battle-scripts/ace-battle-engine/

If anyone has any idea of how to solve it, it would be really appreciated.

I've moved this thread to RGSSx Script Support. Thank you.

How many scripts are you using? Can you provide a list? What your saying here is the first time I've seen this. I use ace battle engine like many others and there is no problems.
A random foolproof without knowing what other scripts you're using. Might work, might not work
Code:
class Game_Actor
  def screen_x
    return 0 unless SceneManager.scene_is?(Scene_Battle)
    status_window = SceneManager.scene.status_window
    return 0 if status_window.nil? || status_window.disposed?
    item_rect_width = (status_window.width-24) / $game_party.max_battle_members
    ext = SceneManager.scene.info_viewport.ox
    rect = SceneManager.scene.status_window.item_rect(self.index)
    constant = 128 + 12
    return constant + rect.x + item_rect_width / 2 - ext
  end
 
  #--------------------------------------------------------------------------
  # new method: screen_y
  #--------------------------------------------------------------------------
  def screen_y
    return Graphics.height - 120 unless SceneManager.scene_is?(Scene_Battle)
    return Graphics.height - 120 if SceneManager.scene.status_window.nil? || 
      SceneManager.scene.status_window.disposed?
    return Graphics.height - (SceneManager.scene.status_window.height * 7/8)
  end
end
Put below ace battle engine
Moved to: RGSSx Script Support

Thank you, I had literally zero idea where to post this. I'll keep this forum in mind the next time I come across an error.

How many scripts are you using? Can you provide a list? What your saying here is the first time I've seen this. I use ace battle engine like many others and there is no problems.

I tried this in a new project that only had the Yanfly Core and Battle Scripts and I got the same results, so I doubt it's a compatibility problem. I will provide a list if you insist, thought.

Btw the versions are 1.09 for the Core and 1.22 for the Battle Engine, in case that might be the problem.

Also, in the post in Yanfly's page there was a comment reportting the same problem. Unanswered, unfortunately.
A random foolproof without knowing what other scripts you're using. Might work, might not work
Code:
class Game_Actor
  def screen_x
    return 0 unless SceneManager.scene_is?(Scene_Battle)
    status_window = SceneManager.scene.status_window
    return 0 if status_window.nil? || status_window.disposed?
    item_rect_width = (status_window.width-24) / $game_party.max_battle_members
    ext = SceneManager.scene.info_viewport.ox
    rect = SceneManager.scene.status_window.item_rect(self.index)
    constant = 128 + 12
    return constant + rect.x + item_rect_width / 2 - ext
  end
 
  #--------------------------------------------------------------------------
  # new method: screen_y
  #--------------------------------------------------------------------------
  def screen_y
    return Graphics.height - 120 unless SceneManager.scene_is?(Scene_Battle)
    return Graphics.height - 120 if SceneManager.scene.status_window.nil? ||
      SceneManager.scene.status_window.disposed?
    return Graphics.height - (SceneManager.scene.status_window.height * 7/8)
  end
end
Put below ace battle engine

Thank you so much! It worked perfectly. You have helped me so much.

I think the thread can be closed.
you need to report it & ask for it to be closed 🙂
Oh okay.
Thread closed IgnoreMe

Original thread: https://forums.rpgmakerweb.com/threads/error-in-ace-battle-engine.90475/