Ignore button press

Status
Not open for further replies.

Marioman13

Imaginationer
Veteran
Joined
Jan 3, 2015
Messages
41
Reaction score
6
First Language
English
Primarily Uses
Is there a script that allows you to ignore button presses when called?
 

Wavelength

MSD Strong
Global Mod
Joined
Jul 22, 2014
Messages
5,624
Reaction score
5,104
First Language
English
Primarily Uses
RMVXA
It actually depends on what button/functions you need ignored.  Why don't you tell us a little more about what you want to do?

By the way, cool avatar.
 
Last edited by a moderator:

EternalShadow

Veteran
Veteran
Joined
Sep 16, 2012
Messages
5,781
Reaction score
1,041
First Language
English
Primarily Uses
In a similar vein, I'm actually looking for a script that ignores -all- button presses until called up again. Essentially, to stop people pressing enter on text as events are timed up against the text. I would imagine he is looking for something similar.
 

Marioman13

Imaginationer
Veteran
Joined
Jan 3, 2015
Messages
41
Reaction score
6
First Language
English
Primarily Uses
It actually depends on what button/functions you need ignored.  Why don't you tell us a little more about what you want to do?

By the way, cool avatar.
In a similar vein, I'm actually looking for a script that ignores -all- button presses until called up again. Essentially, to stop people pressing enter on text as events are timed up against the text. I would imagine he is looking for something similar.
Yeah, I was talking about all button presses.

By the way, cool avatar.
Ha, thanks!
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,365
Reaction score
7,675
First Language
German
Primarily Uses
RMMV
to ignore all button presses is simply - make an autorun, that's what they do automatically: Ignore all player input until their commands are completed.


It's the selective ignore that's the problem, if only some inputs are to be ignored - and to solve that we need more info.


Edit:


Always remember: if all button presses are ignored, the game will basically be either frozen or in a cutscene
 
Last edited by a moderator:

Marioman13

Imaginationer
Veteran
Joined
Jan 3, 2015
Messages
41
Reaction score
6
First Language
English
Primarily Uses
to ignore all button presses is simply - make an autorun, that's what they do automatically: Ignore all player input until their commands are completed.

It's the selective ignore that's the problem, if only some inputs are to be ignored - and to solve that we need more info.

Edit:

Always remember: if all button presses are ignored, the game will basically be either frozen or in a cutscene
Well, I said script because I wanted to call a script that ignore button presses in an event with a script call.

The event is in the common events section of the database, and I only want to ignore button presses for a small amount of time, not the whole event.
 

EternalShadow

Veteran
Veteran
Joined
Sep 16, 2012
Messages
5,781
Reaction score
1,041
First Language
English
Primarily Uses
to ignore all button presses is simply - make an autorun, that's what they do automatically: Ignore all player input until their commands are completed.

It's the selective ignore that's the problem, if only some inputs are to be ignored - and to solve that we need more info.

Edit:

Always remember: if all button presses are ignored, the game will basically be either frozen or in a cutscene
And unfortunately, autoruns don't actually stop you speeding up text when pressing enter, so technically button presses still work in autoruns.
 

Marioman13

Imaginationer
Veteran
Joined
Jan 3, 2015
Messages
41
Reaction score
6
First Language
English
Primarily Uses
And unfortunately, autoruns don't actually stop you speeding up text when pressing enter, so technically button presses still work in autoruns.
Well, i guess i'll wait.
 

♥SOURCE♥

Too sexy for your party.
Veteran
Joined
Mar 14, 2012
Messages
693
Reaction score
411
Primarily Uses
Hello!

Is there a script that allows you to ignore button presses when called?
Now there is! Open the script editor and paste the following code in a new slot above Main:

# Ignore Input.# Version 1.0.0# 03/05/15 - DD/MM/YY# www.rpgmakersource.com# forums.rpgmakersource.com## Use Input.ignore = true/false in a Script Event Command.# Free to use on free or commercial games. Don't remove the original header.class << Input attr_accessor :ignore [:trigger?, :press?, :repeat?, :dir4, :dir8].each { |name| class_eval %Q( alias_method:)ignore_original_#{name}, :#{name}) def #{name}(*args) @ignore ? #{name[/\d/].nil? ? false : 0} : ignore_original_#{name}(*args) end)} endWhen you want the game to ignore input, add a Script command with the following:

Input.ignore = trueWhen you want the game to work normally again, add a Script command with the following:

Input.ignore = falseCheers!
 

Marioman13

Imaginationer
Veteran
Joined
Jan 3, 2015
Messages
41
Reaction score
6
First Language
English
Primarily Uses
Hello!

Now there is! Open the script editor and paste the following code in a new slot above Main:

# Ignore Input.# Version 1.0.0# 03/05/15 - DD/MM/YY# www.rpgmakersource.com# forums.rpgmakersource.com## Use Input.ignore = true/false in a Script Event Command.# Free to use on free or commercial games. Don't remove the original header.class << Input attr_accessor :ignore [:trigger?, :press?, :repeat?, :dir4, :dir8].each { |name| class_eval %Q( alias_method:)ignore_original_#{name}, :#{name}) def #{name}(*args) @ignore ? #{name[/\d/].nil? ? false : 0} : ignore_original_#{name}(*args) end)} endWhen you want the game to ignore input, add a Script command with the following:

Input.ignore = trueWhen you want the game to work normally again, add a Script command with the following:

Input.ignore = falseCheers!
I log off for a while, then when I log back in, I nearly jump out of my seat.

Thank you, very, very much! It works like a charm!

SOLVED! :D
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,365
Reaction score
7,675
First Language
German
Primarily Uses
RMMV
Marioman13, please do not quote entire posts to answer them, especially not if they are directly above your post.


And to have a topic closed, simply report the topic with the report button and a comment like "close" or so.


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 Profile Posts

Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD
How many parameters is 'too many'??

Forum statistics

Threads
105,867
Messages
1,017,062
Members
137,575
Latest member
akekaphol101
Top