Message Window Pause Sign Repositioning

Status
Not open for further replies.

Palsa

General of Aurda
Veteran
Joined
Dec 21, 2012
Messages
343
Reaction score
84
First Language
English
Primarily Uses
I'm sure that it's a simple edit, but scripting is not my thing. ^_^;


Basically, what I'm looking at is to have the pause sign at the bottom of the message window moved to the right, rather then in the center.


Example:





Or alternatively, but not necessary, replace it with a custom animation. :)


I've looked through the help file and script editor, but no matter what I try it always ends in failure, and I can't seem to find a script covering this.


An additional note: I'm using Modern Algebra's ATS: Message Options, so any script would have to be compatible with it.


If anyone could manage this, I'd be greatly appreciative. ^_^
 
Last edited by a moderator:

djDarkX

Retro & Remastered Music Guru
Veteran
Joined
Jan 17, 2013
Messages
2,699
Reaction score
1,892
First Language
Music
Primarily Uses
RMMV
THANK YOU FOR ASKING THIS!  I was trying to figure this out on my own, but this would greatly help out if someone knew how to do this.  I checked Window_Message and looked for the various "pause" keywords in the base scripts but found nothing.  Hopefully someone will chime in with an answer.
 

Yato

(aka Racheal)
Veteran
Joined
Mar 17, 2012
Messages
826
Reaction score
346
Primarily Uses
As simple as it really should be, it's not. Probably because it's part of the windowskin, it's handled by the base Window class which is not in the editor. One solution I used back in an early VX game was to remake the pause graphic and handle its display in a non-default way. Maybe someone has a better solution, but I'll see what I can do for Ace.
 
Last edited by a moderator:

TheoAllen

Self-proclaimed jack of all trades
Veteran
Joined
Mar 16, 2012
Messages
4,805
Reaction score
5,501
First Language
Indonesian
Primarily Uses
RMVXA
It's easier to replace it with animation than repositioning the pause cursor to another place. As I remember, there's no built in funtion to do that. So, what do you mean by "animation"? A image with framesets or from animation database?
 
Last edited by a moderator:

djDarkX

Retro & Remastered Music Guru
Veteran
Joined
Jan 17, 2013
Messages
2,699
Reaction score
1,892
First Language
Music
Primarily Uses
RMMV
Basically, taking the pause input graphic, the one shown in the image above, and placing it either to the left, in the center (default) or to the right.  Kinda wish we had access to the Window class as that seems to contain the meat of the system and would make for a very interesting look-through.  I know you can mess with the Window class (check Yanfly's Cursor script) and the window skin (which you can make a window frame selection menu using an if/else condition via scripts), but this one eludes me.
 

Yato

(aka Racheal)
Veteran
Joined
Mar 17, 2012
Messages
826
Reaction score
346
Primarily Uses
I'm sure it could be done better, but this should do the job.

class Window_Message < Window_Base
#--------------------------------------------------------------------------
# * Initialize
#--------------------------------------------------------------------------
alias move_pause_graphic_initialize initialize
def initialize
move_pause_graphic_initialize
make_pause_sprite
end
#--------------------------------------------------------------------------
# * Free
#--------------------------------------------------------------------------
alias move_pause_graphic_dispose dispose
def dispose
move_pause_graphic_dispose
@pause_sprite.dispose
end
#--------------------------------------------------------------------------
# * Make Pause Sprite
#--------------------------------------------------------------------------
def make_pause_sprite
@pause_sprite = Sprite.new
@pause_sprite.bitmap = self.windowskin
@pause_sprite.src_rect = Rect.new(96, 64, 16, 16)
@pause_sprite.z = self.z + 10
@pause_sprite.visible = false
end
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
alias move_pause_graphic_update update
def update
move_pause_graphic_update
update_pause_sprite if @pause_sprite.visible
end
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
def update_pause_sprite
frame = Graphics.frame_count % 60 / 15
@pause_sprite.src_rect.x = 96 + 16 * (frame % 2)
@pause_sprite.src_rect.y = 64 + 16 * (frame / 2)
end
#--------------------------------------------------------------------------
# * Set Pause
#--------------------------------------------------------------------------
def pause=(pause)
@pause_sprite.x = self.x + self.width - padding - 12
@pause_sprite.y = self.y + self.height - padding - 4
@pause_sprite.visible = pause
end
end
Because of the nature of the change, I have to overwrite input_pause, at very least to get rid of the old graphic. As a result, this should go above the message option script you listed. If you are using the scroll review feature of that script, I will need to write a quick little compatibility scriptlet. I just didn't bother yet because I don't know if you're using that feature of the script or not.

[Edit] Nevermind, I didn't need to overwrite that method. I've updated it so now it just overrides the pause= method. :) Now it doesn't matter if it goes above or below that other script.
 
Last edited by a moderator:

Palsa

General of Aurda
Veteran
Joined
Dec 21, 2012
Messages
343
Reaction score
84
First Language
English
Primarily Uses
Wow, that was fast! :D

It's working great, thank you Racheal! :D
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,766
Reaction score
12,202
First Language
English
Primarily Uses
RMMV
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.
 
Status
Not open for further replies.

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

Benku wrote on Magnus0808's profile.
Hey man you helped me out a long time ago with a plugin i was wondering if you can help me out one more time since its literally the last thing i need help with if not is cool but id figured id ask you one more soild.
Stream will be live shortly with a guest stream! Tonight, a new guest joins~ Feel free to drop by!
Finally told my boss I need a day off. Tomorrow will be my first in 23 days.
Kind of a goofy question but has the pandemic inspired you in any way?

Forum statistics

Threads
95,421
Messages
929,039
Members
125,649
Latest member
Laser_Kirin
Top