(Yanfly) Picture Common Events- 'Release' Behavior Fix?

VTDraws

Filthy Point-&-Click casual
Veteran
Joined
Apr 17, 2017
Messages
56
Reaction score
9
First Language
English
Primarily Uses
RMMV
So I've been using this script to build my game's point-and-click UI for some time now, and recently made a very simple system of holding down a button on-screen that closes the player's eyes [blackening the screen], and then opens them once you release the button [fading in the screen].
[I also made this work with covering their ears. Both were to aid in tiny 'don't look at the scary thing' events in-game where you have to close your eyes in time before an event's timer runs out. I digress.]

In Yanfly's plugin, there's 4 behaviors you can attach common events to, on pictures.
Click - Activates the CE once upon click
Repeat - Activates the CE every 6 frames while holding
Hold - Activates the CE every frame while holding
Release - [THIS is the troublemaker] Activates a CE upon Releasing the Button

My system looks like this:
Common event 1: CLOSE EYES [Activates either via Click or Hold, both work.]

Trigger: None
Contents:

Control Switches: #0002 EYES CLOSED = ON
Show Picture: #100, Black Screen, Upper Left (0,0), (100%,100%), 255, Normal


This closes the character's eyes and keeps the EYES CLOSED switch ON.

Common event 2: OPEN EYES [Activates via Release, aka stopping your click]

Trigger: None
Contents:

Fadeout Screen
Wait: 30 frames
Erase Picture: #100
Fadein Screen
Control Switches: #0002 EYES CLOSED = OFF


This opens the character's eyes and turns the EYES CLOSED switch OFF.

This system works PERFECTLY if you ONLY click, hold, and then release at whatever point you want.

Here's my predicament:
Yanfly's plugin has a weird behavior for 'RELEASE' as a behavior for picture common events. If you move your cursor out of the picture's boundaries while still holding your mouse, and THEN you release, it doesn't count it and doesn't activate the 'RELEASE' common event.
I want there to be a way that, just like with 'REPEAT' and 'HOLD', if you move your cursor out of the picture's boundary, it'll count that as 'RELEASE', and will activate the 'RELEASE' common event.

REPEAT and HOLD seem to have this capability, according to Yanfly's own in-plugin words:

- REPEAT -
If the mouse is clicked and then held (or if the touch screen is pushed and
held), as long as the mouse is above the picture area and the common event
value listed is above 0, then this will trigger once every 6 frames until
the player releases the mouse (or stops touching the screen) or moves the
mouse outside of the picture boundaries.


- HOLD -
If the mouse is clicked and then held (or if the touch screen is pushed and
held), as long as the mouse is above the picture area and the common event
value listed is above 0, then this will trigger every frame until the player
releases the mouse (or stops touching the screen) or moves the mouse outside
of the picture boundaries.
But RELEASE does not. [And I only JUST NOW realized that it DOES stipulate 'releases the mouse above this picture']

- RELEASE -
Upon releasing the clicked mouse (or the moment the player stops touching
the screen) and releases the mouse above this picture and if the picture's
common event value listed is above 0, then this will trigger upon release.

If anyone could help with this, it'd be greatly appreciated. Either I need a change to the plugin code that'll allow RELEASE to register 'moving cursor out of picture boundary AND 'releasing click above this picture', or I need a way to make this system somehow work with RELEASE or HOLD.

Please and thank you in advance.


EDIT #1:
If there was a way to have a NEW behavior added, OR to change 'release' to something else, that'd be perfect.
It'd be exactly what I need if there was a way to have the behavior go:

Mouse cursor -> over picture
[no Common Event activation]
Mouse cursor -> leaves picture
[ACTIVATES COMMON EVENT ID]

That way I could have two events:
Click - TURNS ON SWITCH
Move Mouse Away - TURNS OFF SWITCH [only if switch is ON, to avoid mousing over the icon by accident and activating a common event.]
 
Last edited:

VTDraws

Filthy Point-&-Click casual
Veteran
Joined
Apr 17, 2017
Messages
56
Reaction score
9
First Language
English
Primarily Uses
RMMV

VTDraws

Filthy Point-&-Click casual
Veteran
Joined
Apr 17, 2017
Messages
56
Reaction score
9
First Language
English
Primarily Uses
RMMV
Bump again! Still really need help if anyone has any scripting knowledge. ^^
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,956
First Language
English
Primarily Uses
RMMV
Unfortunately I don't have that plugin at present and they're behind a paywall now, so I can't look at it to see if I can intuit a fix.
 

VTDraws

Filthy Point-&-Click casual
Veteran
Joined
Apr 17, 2017
Messages
56
Reaction score
9
First Language
English
Primarily Uses
RMMV
Unfortunately I don't have that plugin at present and they're behind a paywall now, so I can't look at it to see if I can intuit a fix.
Ughhh I know. I respect that they want their work paid for now, but with them being gone it makes it really hard to get support.

I got this plugin back when it was free, BUT I bought the whole pack fair and square to get the whole suite. Is there any way I could share just this one script with you privately to get some help, or is that against forum rules? :S
 
Last edited:

VTDraws

Filthy Point-&-Click casual
Veteran
Joined
Apr 17, 2017
Messages
56
Reaction score
9
First Language
English
Primarily Uses
RMMV
Bumping- any idea if sharing this 1 script with you for support would be against forum rules, @Trihan ? I bought the extension pack recently, though I already had this script as a freebie from way back when. So it's been purchased, I'd just need to share it for getting help.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,956
First Language
English
Primarily Uses
RMMV
I'm not 100% sure.
 

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,956
First Language
English
Primarily Uses
RMMV
I got it. Will try to take a look tomorrow.
 

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

Latest Threads

Latest Profile Posts

All of the auditions for our game are so good, I'm so glad I'm not in charge of choosing completely. lol I just can't with some of them. I listen to them on repeat. XD
Working on a Patch to integrate AlphaABS into random generated Dungeons. Was a bit tricky, but the outcome is a real Life Changer!!

Will release it the next days!
Been pretty busy... but I got a better headset for recording and listening today. Dad says that he'll consider taking me to Great Wolf Lodge for the first time once I finish summer classes (my final semester!) I'll be taking my plushie friends with me: Bendy, Lolbit, and Helen Henny. (I WUV PLUSHIES!)
SF_Monster3,4 added!


My only regret is the portal mirror effect is too subtle to show up in these GIFs. It probably just needs more sparkles. :LZSwink:

Forum statistics

Threads
105,650
Messages
1,015,290
Members
137,327
Latest member
Mezzy
Top