Joined
Aug 13, 2019
Messages
101
Reaction score
15
First Language
english
Primarily Uses
RMMV
hello.

I am using the storage boxes script by imp.

everything works fine but there is something that I don't like, and it is the following:

When you open a chest or closet , your inventory is shown on the left and the box on the right.

to move between the box and the inventory (vice versa) you must do it with the arrows (keyboard)

Example:

Right Arrow->You move to the box
Left Arrow->You move back to inventory.

Sin título.png

I want it to be able to move by pressing the left mouse button but it cannot, when clicking on the other side, the options "store" or "take" item appear, but the cursor does not go to the other side.

Is there a way to make the mouse cursor act like the keyboard arrows?

I use falcao mouse buttons script:

https://falcaorgss.wordpress.com/2012/09/17/mouse-system-buttons-update-1-5/

Thank you.
 

Roninator2

Gamer
Veteran
Joined
May 22, 2016
Messages
4,832
Reaction score
1,373
First Language
English
Primarily Uses
RMVXA
Ruby:
class Scene_ItemStorage < Scene_MenuBase
  alias r2_item_storage_mouse_cursor  update
  def update
    r2_item_storage_mouse_cursor
    update_mouse
  end
  def update_mouse
    if $mouse_cursor.visible
      Mouse.update
      $game_arrows.update
      mx, my = *Mouse.position
      $mouse_cursor.x = mx unless mx.nil?
      $mouse_cursor.y = my unless my.nil?   
    end
    if ($mouse_cursor.x > Graphics.width / 2) && @bag_window.active
      @bag_window.deactivate
      @box_window.activate
    elsif ($mouse_cursor.x < Graphics.width / 2) && @box_window.active
      @box_window.deactivate
      @bag_window.activate
    end
  end
end
 
Joined
Aug 13, 2019
Messages
101
Reaction score
15
First Language
english
Primarily Uses
RMMV
Ruby:
class Scene_ItemStorage < Scene_MenuBase
  alias r2_item_storage_mouse_cursor  update
  def update
    r2_item_storage_mouse_cursor
    update_mouse
  end
  def update_mouse
    if $mouse_cursor.visible
      Mouse.update
      $game_arrows.update
      mx, my = *Mouse.position
      $mouse_cursor.x = mx unless mx.nil?
      $mouse_cursor.y = my unless my.nil?
    end
    if ($mouse_cursor.x > Graphics.width / 2) && @bag_window.active
      @bag_window.deactivate
      @box_window.activate
    elsif ($mouse_cursor.x < Graphics.width / 2) && @box_window.active
      @box_window.deactivate
      @bag_window.activate
    end
  end
end

works perfect, thanks!

Do you think it is possible to do this but on the save and load game screen?

it won't let me move between different games with the mouse, only the keyboard.
 
Last edited:

Roninator2

Gamer
Veteran
Joined
May 22, 2016
Messages
4,832
Reaction score
1,373
First Language
English
Primarily Uses
RMVXA
Is that the default save and load screens?
 

Latest Threads

Latest Profile Posts



The project is going well, it's just I rarely share clips and stuff 'round here
I'm now free to do the game make! (sees diablo 4) Hmmmmmmm...... I'm not free!

3d Yandere RPG maker game by labylin

Forum statistics

Threads
131,773
Messages
1,223,233
Members
173,543
Latest member
Zanibad
Top