Raizen

Veteran
Veteran
Joined
Oct 24, 2012
Messages
382
Reaction score
670
First Language
Portuguese
Primarily Uses
RMMV
Akea Animated Battle Cursor
 
Compatible with: RMVXAce
Compatibility :good
Usage difficulty: easy
 
Usage Condition

 Can be modified and distributed as long as the credits remain
  for portuguese users: Here
 
Script functions
[x] Enables Actor and Enemy Cursor, it can be animated or not
[x] It is highly compatible with any Scene_Battle based battle script, if a battle script is not compatible with this one, leave a message with the script.
 
 
Script
 
http://pastebin.com/raw.php?i=yhtbiGkN

 
Images
You can use my cursor if you wish
ebUoci5.png


Images are in portuguese, but all the script has been translated to english
 
BlI0bqR.png
XqUvGAJ.png
 
 
Credits
 
 Raizen for the script
 
Joined
Sep 21, 2012
Messages
10
Reaction score
2
First Language
Spanish
Primarily Uses
Sorry to bother yourself Raizen,it is possible to make the cursor position based in the battler size? I want to put the cursor above monsters/actors. Excuse me for my bad english and greetings from Argentina.

Here is a example:

Sin_t_tulo.png


I dont have problem with actors because they have the same size. But in the monsters case not,i tried to adjust the y position and does not look good in different battlers size.
 

Raizen

Veteran
Veteran
Joined
Oct 24, 2012
Messages
382
Reaction score
670
First Language
Portuguese
Primarily Uses
RMMV
Here I made the change for you xD.

I had thought when I did the script about putting the height value to count, but there was a BIG problem with that, is that if you are using animated battlers, the bitmap will have an extremely high height because of the spritesheet, and I would end up doing it only compatible with my system xD, so thats why I chose a constant.

Basically the below code will work just fine, IF you only use static enemies which looks like the case :)

Code:
#=======================================================#        Akea Animated Battle Cursor# Author: Raizen# Community: [URL="http://www.centrorpg.com/#"]http://www.centrorpg.com/#[/URL] Compatibility: RMVXAce##=======================================================# =========================Don't Modify==============================$included ||= Hash.new$included[:akea_battlecursor] = truemodule Akea_BattleCursor# =========================Don't Modify==============================# Configuration starts Here#=======================================================#        INSTRUCTIONS# Simple, put the script above main and below any other battle scripts# (for better compatibility)# And then configure below, the scripts shows an animated battle cursor.#=======================================================# If animated, this is the framerate update of the animation, the higher the slower.Cursor_Update = 10# Show the default windows that identify the enemies and actors?Show_Windows = false# Show battler names?Show_Name = true# Name of fot, put '' to be used default fontFont_Name = 'Georgia' # Size of font, put 0 to use default font sizeFont_Size = 18#==============================================================================# ** Enemy Configuration#==============================================================================# Font Color for Enemies, following the default R, G, B and on the end put the# opacity of the font, being 0 invisible until 255 full visibleEnemy_Font_Color = [255, 100, 100, 255]# Name of cursor image, must be in the folder Graphics/AkeaEnemy_Cursor = 'Enemy_Cursor'# Number of frames the enemy cursor has, if not animated put# Enemy_Frames = 1Enemy_Frames = 5# Cursor position over the enemies# E_Cursor_Position = [x position, y position]E_Cursor_Position = [0, 0]# Position of enemy name# E_Name_Position = [x position, y position]E_Name_Position = [0, -30]# Name of cursor image, must be in the folder Graphics/Akea# In case you do not use visible actors, put# Actor_Cursor = ''Actor_Cursor = 'Actor_Cursor'#==============================================================================# ** Actor configuration# Not necessary IF you do not use visible actors#==============================================================================# Font color for the actors, following the default R, G, B and on the end put the# opacity of the font, being 0 invisible until 255 full visibleActor_Font_Color = [100, 255, 150, 255]# Numver of frames from the actor cursor, if not animated put# Actor_Frames = 1Actor_Frames = 5# Cursor Position over the actors# A_Cursor_Position = [x position, y position]A_Cursor_Position = [-55, -70]# # Name position of the actors# A_Name_Position = [x position, y position]A_Name_Position = [-10, -10]#==============================================================================# ** HERE starts the script#==============================================================================end#==============================================================================# ** Scene_Battle#------------------------------------------------------------------------------#  Esta classe executa o processamento da tela de batalha.#==============================================================================class Scene_Battle < Scene_Basealias :akea_bc_start :startalias :akea_bc_update :updatealias :akea_bc_select_enemy_selection :select_enemy_selectionalias :akea_bc_on_skill_ok :on_skill_okalias :akea_bc_on_enemy_cancel :on_enemy_cancelalias :akea_bc_on_item_ok :on_item_okalias :akea_bc_on_actor_cancel :on_actor_cancelalias :akea_bc_select_actor_selection :select_actor_selectionalias :akea_bc_terminate :terminatealias :akea_bc_turn_start :turn_startalias :akea_bc_next_command :next_command  #--------------------------------------------------------------------------  # * Inicialização do processo  #--------------------------------------------------------------------------  def start    @bc_cursor = Array.new    @bc_enemy_cursor = Array.new    @bc_actor_cursor = Array.new    @akea_target_all = false    akea_bc_start    akea_bc_create_pictures  end  def akea_bc_create_pictures    @bc_actor_size = $game_party.battle_members.size    @bc_frame_position = 0    for n in 0...all_battle_members.size      next unless all_battle_members[n].use_sprite?      @bc_cursor[n] = Sprite.new      @bc_cursor[n].bitmap = Bitmap.new(Graphics.width, Graphics.height)      #@bc[n].bitmap.font.size = 48      rect = Rect.new(0, 0, 200, 50)      if all_battle_members[n].actor?        @bc_cursor[n].bitmap.font.color = Color.new(Akea_BattleCursor::Actor_Font_Color[0], Akea_BattleCursor::Actor_Font_Color[1], Akea_BattleCursor::Actor_Font_Color[2], Akea_BattleCursor::Actor_Font_Color[3])        @bc_actor_cursor[n] = Sprite.new        @bc_actor_cursor[n].bitmap = Cache.akea(Akea_BattleCursor::Actor_Cursor)        @bc_actor_cursor[n].src_rect.set(0, 0, @bc_actor_cursor[n].bitmap.width/Akea_BattleCursor::Actor_Frames, @bc_actor_cursor[n].bitmap.height)        @bc_actor_cursor[n].opacity = 0      else        @bc_enemy_cursor << Sprite.new        @bc_enemy_cursor.last.bitmap = Cache.akea(Akea_BattleCursor::Enemy_Cursor)        @bc_enemy_cursor.last.src_rect.set(0, 0, @bc_enemy_cursor.last.bitmap.width/Akea_BattleCursor::Enemy_Frames, @bc_enemy_cursor.last.bitmap.height)        @bc_enemy_cursor.last.opacity = 0        @bc_cursor[n].bitmap.font.color = Color.new(Akea_BattleCursor::Enemy_Font_Color[0], Akea_BattleCursor::Enemy_Font_Color[1], Akea_BattleCursor::Enemy_Font_Color[2], Akea_BattleCursor::Enemy_Font_Color[3])      end      @bc_cursor[n].bitmap.font.size = Akea_BattleCursor::Font_Size unless Akea_BattleCursor::Font_Size == 0      @bc_cursor[n].bitmap.font.name = Akea_BattleCursor::Font_Name unless Akea_BattleCursor::Font_Name == ''      @bc_cursor[n].bitmap.draw_text(rect, all_battle_members[n].name, 0) if Akea_BattleCursor::Show_Name      @bc_cursor[n].z = 105      if all_battle_members[n].enemy?        @bc_cursor[n].x = all_battle_members[n].screen_x + Akea_BattleCursor::E_Name_Position[0]        @bc_cursor[n].y = all_battle_members[n].screen_y + Akea_BattleCursor::E_Name_Position[1]      else        @bc_cursor[n].x = all_battle_members[n].screen_x + Akea_BattleCursor::A_Name_Position[0]        @bc_cursor[n].y = all_battle_members[n].screen_y + Akea_BattleCursor::A_Name_Position[1]      end      @bc_cursor[n].opacity = 0    end  end  def update(*args, &block)    akea_bc_update    show_bc_info  end  def show_bc_info    if @enemy_window.active      @bc_enemy_cursor.each{|cursor| cursor.opacity -= 30}      @bc_actor_cursor.each{|cursor| cursor.opacity -= 30}      @bc_cursor.each{|cursor| cursor.opacity -= 30}      if @akea_target_all        for n in 0...@bc_enemy_cursor.size          if $game_troop.members[n].alive?            @bc_cursor[n + $game_party.members.size].opacity += 60            @bc_enemy_cursor[n].x = $game_troop.members[n].screen_x + Akea_BattleCursor::E_Cursor_Position[0]            @bc_enemy_cursor[n].y = $game_troop.members[n].screen_y + Akea_BattleCursor::E_Cursor_Position[1] - @spriteset.enemy_sprites[n].bitmap.height            @bc_enemy_cursor[n].opacity += 60          end        end      else        p @spriteset.enemy_sprites[0].bitmap.height        @bc_enemy_cursor[@enemy_window.enemy.index].x = $game_troop.members[@enemy_window.enemy.index].screen_x + Akea_BattleCursor::E_Cursor_Position[0]        @bc_enemy_cursor[@enemy_window.enemy.index].y = $game_troop.members[@enemy_window.enemy.index].screen_y + Akea_BattleCursor::E_Cursor_Position[1] - @spriteset.enemy_sprites[@enemy_window.enemy.index].bitmap.height        @bc_enemy_cursor[@enemy_window.enemy.index].opacity += 60        @bc_cursor[@enemy_window.enemy.index + $game_party.members.size].opacity += 60      end      update_bc_enemy_cursor    elsif @actor_window.active      if all_battle_members[0].use_sprite?        @bc_enemy_cursor.each{|cursor| cursor.opacity -= 30}        @bc_actor_cursor.each{|cursor| cursor.opacity -= 30}        @bc_cursor.each{|cursor| cursor.opacity -= 30}        if @akea_target_all          for n in 0...@bc_actor_cursor.size            @bc_actor_cursor[n].x = all_battle_members[n].screen_x + Akea_BattleCursor::A_Cursor_Position[0]            @bc_actor_cursor[n].y = all_battle_members[n].screen_y + Akea_BattleCursor::A_Cursor_Position[1]            @bc_actor_cursor[n].opacity += 60            @bc_cursor[n].opacity += 60          end        else          @bc_actor_cursor[@actor_window.index].x = all_battle_members[@actor_window.index].screen_x + Akea_BattleCursor::A_Cursor_Position[0]          @bc_actor_cursor[@actor_window.index].y = all_battle_members[@actor_window.index].screen_y + Akea_BattleCursor::A_Cursor_Position[1]          @bc_actor_cursor[@actor_window.index].opacity += 60          @bc_cursor[@actor_window.index].opacity += 60        end      end      update_bc_actor_cursor    else      for n in 0...all_battle_members.size        next unless all_battle_members[n].use_sprite?        @bc_cursor[n].opacity -= 30      end        @bc_enemy_cursor.each{|cursor| cursor.opacity -= 30}        @bc_actor_cursor.each{|cursor| cursor.opacity -= 30}    end  end  def update_bc_enemy_cursor    return unless Graphics.frame_count % Akea_BattleCursor::Cursor_Update == 0    if @bc_frame_position >= Akea_BattleCursor::Enemy_Frames - 1      @bc_frame_position = 0    else      @bc_frame_position += 1    end    @bc_enemy_cursor.each{|cursor| cursor.src_rect.set(@bc_frame_position*@bc_enemy_cursor[0].bitmap.width/Akea_BattleCursor::Enemy_Frames, 0, @bc_enemy_cursor[0].bitmap.width/Akea_BattleCursor::Enemy_Frames, @bc_enemy_cursor[0].bitmap.height)}  end  def update_bc_actor_cursor    return unless Graphics.frame_count % Akea_BattleCursor::Cursor_Update == 0    if @bc_frame_position >= Akea_BattleCursor::Actor_Frames - 1      @bc_frame_position = 0    else      @bc_frame_position += 1    end    @bc_actor_cursor.each {|cursor| cursor.src_rect.set(@bc_frame_position*@bc_actor_cursor[0].bitmap.width/Akea_BattleCursor::Actor_Frames, 0, @bc_actor_cursor[0].bitmap.width/Akea_BattleCursor::Actor_Frames, @bc_actor_cursor[0].bitmap.height)}  end  #--------------------------------------------------------------------------  # * Início do turno  #--------------------------------------------------------------------------  def turn_start    for n in 0...all_battle_members.size      next unless all_battle_members[n].use_sprite?      @bc_cursor[n].opacity = 0    end    @bc_enemy_cursor.each{|cursor| cursor.opacity = 0}    @bc_actor_cursor.each{|cursor| cursor.opacity = 0}    akea_bc_turn_start  end  #--------------------------------------------------------------------------  # * Seleção da escolha de inimigos  #--------------------------------------------------------------------------  def select_enemy_selection    akea_bc_select_enemy_selection    @enemy_window.hide unless Akea_BattleCursor::Show_Windows  end  #--------------------------------------------------------------------------  # * Seleção da escolha de heróis  #--------------------------------------------------------------------------  def select_actor_selection    akea_bc_select_actor_selection    @actor_window.hide if all_battle_members[0].use_sprite? && !Akea_BattleCursor::Show_Windows  end  #--------------------------------------------------------------------------  # * Habilidade [Confirmação]  #--------------------------------------------------------------------------  def on_skill_ok    @force_window = true    akea_bc_on_skill_ok    @force_window = false    if @skill.for_opponent?      @skill_window.hide    else      @skill_window.hide if all_battle_members[0].use_sprite?    end  end  #--------------------------------------------------------------------------  # * Entrada de comandos para o próximo herói  #--------------------------------------------------------------------------  def next_command    if @force_window && @skill.for_opponent?        @akea_target_all = true        select_enemy_selection      elsif @force_window        @akea_target_all = true        select_actor_selection      else        @akea_target_all = false        akea_bc_next_command    end  end  #--------------------------------------------------------------------------  # * Inimigo [Cancelamento]  #--------------------------------------------------------------------------  def on_enemy_cancel    akea_bc_on_enemy_cancel    @akea_target_all = false    case @actor_command_window.current_symbol    when :skill      @skill_window.show.activate    when :item      @item_window.show.activate    end  end  #--------------------------------------------------------------------------  # * Herói [Cancelamento]  #--------------------------------------------------------------------------  def on_actor_cancel    akea_bc_on_actor_cancel    @akea_target_all = false    case @actor_command_window.current_symbol    when :skill      @skill_window.show.activate    when :item      @item_window.show.activate    end  end  #--------------------------------------------------------------------------  # * Item [Confirmação]  #--------------------------------------------------------------------------  def on_item_ok    akea_bc_on_item_ok    if @item.for_opponent?      @item_window.hide    else      @item_window.hide if all_battle_members[0].use_sprite?    end  end  #--------------------------------------------------------------------------  # * Finalização do processo  #--------------------------------------------------------------------------  def terminate    for n in 0...all_battle_members.size      next unless all_battle_members[n].use_sprite?      @bc_cursor[n].bitmap.dispose      @bc_cursor[n].dispose    end    @bc_actor_cursor.each{|cursor| cursor.bitmap.dispose}    @bc_actor_cursor.each{|cursor| cursor.dispose}    @bc_enemy_cursor.each{|cursor| cursor.bitmap.dispose}    @bc_enemy_cursor.each{|cursor| cursor.dispose}    akea_bc_terminate  endend#==============================================================================# ** Cache#------------------------------------------------------------------------------#  Este modulo carrega cada gráfico, cria um objeto de Bitmap e retém ele.# Para acelerar o carregamento e preservar memória, este módulo matém o# objeto de Bitmap em uma Hash interna, permitindo que retorne objetos# pré-existentes quando mesmo Bitmap é requerido novamente.#==============================================================================module Cache  #--------------------------------------------------------------------------  # * Carregamento dos gráficos de animação  #     filename : nome do arquivo  #     hue      : informações da alteração de tonalidade  #--------------------------------------------------------------------------  def self.akea(filename)    load_bitmap("Graphics/Akea/", filename)  endend#==============================================================================# ** Window_BattleActor#------------------------------------------------------------------------------#  Esta janela para seleção de heróis na tela de batalha.#==============================================================================class Window_BattleActor < Window_BattleStatus  #--------------------------------------------------------------------------  # * Movimento do cursor para baixo  #     wrap : cursor retornar a primeira ou ultima posição  #--------------------------------------------------------------------------  def cursor_down(wrap = false)    super(true)  end  #--------------------------------------------------------------------------  # * Movimento do cursor para cima  #     wrap : cursor retornar a primeira ou ultima posição  #--------------------------------------------------------------------------  def cursor_up(wrap = false)    super(true)  end  #--------------------------------------------------------------------------  # * Movimento do cursor para direita  #     wrap : cursor retornar a primeira ou ultima posição  #--------------------------------------------------------------------------  def cursor_right(wrap = false)    cursor_down  end  #--------------------------------------------------------------------------  # * Movimento do cursor para esquerda  #     wrap : cursor retornar a primeira ou ultima posição  #--------------------------------------------------------------------------  def cursor_left(wrap = false)    cursor_up  endend#==============================================================================# ** Window_BattleEnemy#------------------------------------------------------------------------------#  Esta janela para seleção de inimigos na tela de batalha.#==============================================================================class Window_BattleEnemy < Window_Selectable  #--------------------------------------------------------------------------  # * Aquisição do número de colunas  #--------------------------------------------------------------------------  def col_max    if Akea_BattleCursor::Show_Windows      return 2    else      return 1    end  end  #--------------------------------------------------------------------------  # * Movimento do cursor para baixo  #     wrap : cursor retornar a primeira ou ultima posição  #--------------------------------------------------------------------------  def cursor_down(wrap = false)    super(true)  end  #--------------------------------------------------------------------------  # * Movimento do cursor para cima  #     wrap : cursor retornar a primeira ou ultima posição  #--------------------------------------------------------------------------  def cursor_up(wrap = false)    super(true)  end  #--------------------------------------------------------------------------  # * Movimento do cursor para direita  #     wrap : cursor retornar a primeira ou ultima posição  #--------------------------------------------------------------------------  def cursor_right(wrap = false)    cursor_down  end  #--------------------------------------------------------------------------  # * Movimento do cursor para esquerda  #     wrap : cursor retornar a primeira ou ultima posição  #--------------------------------------------------------------------------  def cursor_left(wrap = false)    cursor_up  endend#==============================================================================# ** Spriteset_Battle#------------------------------------------------------------------------------#  Esta classe reune os sprites da tela de batalha. Esta classe é usada # internamente pela classe Scene_Battle. #==============================================================================class Spriteset_Battle  attr_reader :enemy_spritesend
 
Last edited by a moderator:

mangaka7

Villager
Member
Joined
Jan 10, 2014
Messages
8
Reaction score
0
First Language
English
Primarily Uses
RMMV
Hi there,

I have a problem with this script. When I use a spell that targets the user (self), the arrows and name will appear for all actors. Here's a pic:

I am using Yami Battle Symphony and I did a test with just these 2 scripts. Is your script not compatible or am I doing something wrong?

Thank you!

lgXTaX2.jpg
 

Raizen

Veteran
Veteran
Joined
Oct 24, 2012
Messages
382
Reaction score
670
First Language
Portuguese
Primarily Uses
RMMV
Are you sure the spell is one specific target?

The script does that in two settings, if the spells targets all users, or if it targets a random user, since if its a random user I can't put the arrow on a specific actor :)
 

Halrawk

Veteran
Veteran
Joined
Dec 14, 2012
Messages
97
Reaction score
24
First Language
English
Primarily Uses
I just tested this out using only your animated battler and battle cursor. When you use any skill that targets "The User" it puts cursors on the whole party.
 
Joined
Apr 30, 2012
Messages
216
Reaction score
35
First Language
Spanish
Primarily Uses
Espero que Rpg Maker Mv soporte Rgss3,asi puedo seguir usando este hermoso script.

I just hope to use this beautiful script in Rpg Maker Mv.
 

mangaka7

Villager
Member
Joined
Jan 10, 2014
Messages
8
Reaction score
0
First Language
English
Primarily Uses
RMMV
Are you sure the spell is one specific target?

The script does that in two settings, if the spells targets all users, or if it targets a random user, since if its a random user I can't put the arrow on a specific actor :)
As Halrawk said, any skill that targets "The User" puts cursors on the whole party. Everything else works fine though.
 

diddlydoo

Villager
Member
Joined
Jan 7, 2016
Messages
12
Reaction score
0
First Language
English
Primarily Uses
Im using battle symphony and I cant for the life of me have the cursor show on my actors. It shows up fine when its time to select an enemy but will NOT shot on my battlers?! i just copy/pasted the script and renamed the cursors to what they need to be.
 

Roninator2

Gamer
Veteran
Joined
May 22, 2016
Messages
2,899
Reaction score
642
First Language
English
Primarily Uses
RMVXA
Hello, I'm getting an error. Probably a compatibility with my scripts. It was working at one time but now there's an issue. 


I getting an error on line 206 with code @bc_cursor[n].opacity -= 30.


I have yanfly battle system with victor animated battlers and yanfly victory aftermath.


The error comes up after the battle is won and the spoils are tallied, just as the game would normally go back to the map.


If I rem that line out the next error is on line 327 - @bc_cursor[n].bitmap.dispose


Then line 328 - @bc_cursor[n].dispose


with those three rem'd out, it seems to work.


So I guess just FYI. Thanks


*update - I was getting other problems as well. When pressing right in battle to skip player input, there was an error.


When selecting a spell like heal for a player, I could not select any character except the first one. I figured these out. They were by other script problems.


I guess the scripts I added/changed scripts have changed things. I had issues with VE Target Arrow so I started using yours. Now I have issues with yours and VE script works fine. Go figure.


*next update - The VE script is having the same issue I had before now. But now I know what the issue is, I just don't know how to fix it. I left a comment on victors wordpress for target arrow. Maybe he'll give an answer. It does not highlight the correct enemy, but when I hit the arrow key, then it works.


I have now put your script back in and with those three lines commented out it's working again. At least from what I can tell so far. Holy hell, this is getting crazy.


*another point. The reason I had to switch to VE was because the arrow keys input does not let me scroll through the enemies. Only the mouse will select all enemies. I'm not sure which way to go now. It does work both ways without any battle cursor.


*hopefully my last update. At the moment my testing shows that everything is working. So probably your script works, I just had other problems.
 
Last edited by a moderator:

SaburoX

Veteran
Veteran
Joined
Jan 27, 2013
Messages
87
Reaction score
8
Primarily Uses
I tried using this with Journey Battle System (tankentai) and got the following error:

battlecursorerror.jpg
 

UncannyBoots

Veteran
Veteran
Joined
Feb 1, 2020
Messages
41
Reaction score
5
First Language
English
Primarily Uses
RMVXA
I am getting a similar error to this:
I getting an error on line 206 with code @bc_cursor[n].opacity -= 30.
Except it is on line 166, and the error is a NoMethodError, "undefined method 'opacity'". It happens as soon as I select a skill, right as you would select an enemy. The game will crash right there with that error. I have even tried it in an empty default project and the same thing happens.

Is there any fix for this? For the record, I seem to have compatibility issues with MOG's and Victor's cursor scripts so I would love it if I could get this to work, as it doesn't seem to be a compatibility thing since it also crashes in the default project.
Thank you
 

Roninator2

Gamer
Veteran
Joined
May 22, 2016
Messages
2,899
Reaction score
642
First Language
English
Primarily Uses
RMVXA
tried it in an empty default project
The script is expecting a side vide battle system.
But the other code listed gives the same error.
I found the solution though. line 166 - change it to this...
Ruby:
            @bc_cursor.each{|cursor| cursor.opacity -= 30 unless cursor.nil?}
 

UncannyBoots

Veteran
Veteran
Joined
Feb 1, 2020
Messages
41
Reaction score
5
First Language
English
Primarily Uses
RMVXA
The script is expecting a side vide battle system.
But the other code listed gives the same error.
I found the solution though. line 166 - change it to this...
Ruby:
            @bc_cursor.each{|cursor| cursor.opacity -= 30 unless cursor.nil?}
Yep, that worked. Thank you!
 

UncannyBoots

Veteran
Veteran
Joined
Feb 1, 2020
Messages
41
Reaction score
5
First Language
English
Primarily Uses
RMVXA
I'm actually having another issue with this script now. When a skill's scope is "none" or "user", the window where you select an actor to use the skill on still opens, despite the scope only being allowed to be used on the user, or not used on anyone at all.
I tried changing the def "on_skill_ok" at line 260 to this:
Code:
  def on_skill_ok
    @force_window = true
    akea_bc_on_skill_ok
    @force_window = false
    if !@skill.need_selection?
      @skill_window.hide
      next_command
    elsif @skill.for_opponent?
      @skill_window.hide
    else
      @skill_window.hide if all_battle_members[0].use_sprite?
    end
  end

I added the "!skill.need_selection?" which is from the default Screen_Battle script. My theory was that doing so would tell the script that when using a skill that has a scope of none or for user, it doesn't need a selection and so it should go on to the next command.

It's a step in the right direction perhaps but it doesn't exactly fix the issue, in fact now it crashes the game.

What happens is that it does indeed go to the next command, but the actor selection window still opens. And then when selecting an actor, the game then crashes with the error: "Script 'Scene_Battle' line 375: NoMethodError occured. undefined method 'input' for nil:NilClass".

What would be the solution to this? In summary: I'd like for the scope "user" or "none" to work as it should, but this script interferes with that and changes them to having to select an actor as if the scope was "One Ally" instead

EDIT: This might only be a temporary solution, but commenting out the line "@force_window = true" under "def on_skill_ok" fixes the problem, as far as I have tested.
I'm not too knowledgeable about scripting, but I believe that after that line, an alias is called. When an alias is called, does it then call the parent script's corresponding 'def'? If that is the case, then I believe Scene_Battle will then call "next_command" from its own "def on_skill_ok" and the rest of on_skill_ok is skipped. So then it goes to Akea's next_command function and since force_window is still set to true, the "elsif force_window" will activate, calling "select_actor_selection", no matter what the skill's scope is. So I thought to myself, just removing the setting of the "force_window" to true might give me some leads as to how to solve this. And it turns out it might actually be the solution? But I'm not too comfortable with this as I am not sure if the setting of "@force_window = true" line has a purpose or not. Well, I'll update if I run into any more issues.
 
Last edited:

Latest Threads

Latest Posts

Latest Profile Posts

Observation Log 1 on the planet of "RPGMAKERWEB": Local RMXP community seems to have very few survivors. Their script tech-level is in the early Stone Age(about the same as 66RPG in 2007).
Some cats/wolves/squirrels are spotted, they are likely friendly. :3
Keep working on establishing more meaningful contacts.
May try to use the "I Come in Peace" protocol if encounter any hostiles.
Using hiddenone's QTE tutorial I've been able to setup a simple fishing system. Instead of just the pointer moving, the goal moves as well. Holding the action button scrolls the pointer and pressing the down arrow key hooks the fish. The speed of both is variable as well as the number of successful hooks needed for a catch.
When someone helps you solve a problem, it's good to report the thread so it can be closed, but it's also nice to go back and post in the thread to let them know their suggestion actually worked. And, you know, to say thanks for helping.

Forum statistics

Threads
108,925
Messages
1,040,632
Members
141,377
Latest member
Demonblabla
Top