I don't know if the "Flash" of the most current generations are different, but I played the versions of GB Color.
I made a system similar to this using events only, but I don't remember all the details.
Common Event: Dark Inside -> Trigger: Process Paralel -> Switch: Dark Place
Code:
◆Control Variables:#0019 Dark-ScreeX = Screen X of Player
◆Control Variables:#0020 Dark-ScreeY = Screen Y of Player
◆Control Variables:#0020 Dark-ScreeY -= 24
◆Show Picture:#20, Effect-Dark_Place, Center ({Dark-ScreeX},{Dark-ScreeY}), (100%,100%), 255, Normal
◆Tint Screen:(0,0,0,0), 15 frames
◆Loop
◆Control Variables:#0019 Dark-ScreeX = Screen X of Player
◆Control Variables:#0020 Dark-ScreeY = Screen Y of Player
◆Control Variables:#0020 Dark-ScreeY -= 24
◆Move Picture:#20, Center ({Dark-ScreeX},{Dark-ScreeY}), (100%,100%), 255, Normal, 2 frames (Wait)
◆If:Dark Place is OFF
◆Break Loop
◆
:End
◆
:Repeat Above
Common Event: Item Flash -> Trigger: None
Code:
◆If:Dark Place is OFF
◆Text:None, Window, Bottom
:Text:You cannot use the flashlight at this time.
◆
:Else
◆Control Switches:#0020 Dark Place = OFF
◆Wait:10 frames
◆Move Picture:#20, Center ({Dark-ScreeX},{Dark-ScreeY}), (1000%,1000%), 0, Normal, 30 frames (Wait)
◆Erase Picture:#20
◆
:End
Database -> Items -> Create a new item
Name: Flash
Icon: Touch or
Consume: No
Scope: None
Occasion: Menu Screen
Type: None
Effects: Common Event -> Item Flash
Map: Outside the cave -> Event that transfers inside:
Code:
◆Tint Screen:(-255,-255,-255,0), 15 frames (Wait)
◆Transfer Player:Cave-Inside (36,49)
◆Control Switches:#0020 Dark Place = ON
Map: Inside the cave -> Event that transfers outside:
Code:
◆Control Switches:#0020 Dark Place = OFF
◆Transfer Player:Cave-OutSide (7,7)
◆Erase Picture:#20
◆Tint Screen:(0,0,0,0), 15 frames (Wait)
References:
Edit:
@barrydwiseman
When I made this explanation it was not on my computer, so I found some flaws.
I updated and corrected it, also attached is an image that will be used as the Picture of ID 20.
One of the problems is that the "Loop" within the first event does not stop even when the Switch is turned off, causing the whitening effect to not happen.
Another is that the item was enabled to be used in battle as well (Always).
If you find it necessary I create a playable and editable demo.