Added a new fourth button in room14 to demonstrate this. Renamed BYPASS_LAST_SCENE to FORCE_LAST_SCENE_NULL to make it a bit clearer. Made events "finished" and "interrupted" signals connections as ONESHOT (so they are disconnected once the signal was received). Also removed some unused files, many others remain. And fixed some bugs here and there.
39 lines
973 B
Plaintext
39 lines
973 B
Plaintext
|
||
:use
|
||
|
||
# This event demonstrates the following:
|
||
#- fade out to black
|
||
#- show the pause menu (automatic transition disabled to manage those manually)
|
||
#- wait 2 seconds
|
||
#- change scene (automatic transition disabled to manage those manually) to reload this same room
|
||
|
||
set_global transition_manual true
|
||
|
||
# Fade out to black
|
||
transition fade_black out
|
||
wait 2
|
||
|
||
# Show main menu, automatic transition DISABLED
|
||
show_menu pause
|
||
|
||
# Showing menu
|
||
transition shards in
|
||
|
||
# Wait 2 seconds on menu
|
||
wait 2
|
||
|
||
# Transition out before hiding menu
|
||
transition fade_black out
|
||
|
||
# Hide the menu
|
||
hide_menu pause
|
||
wait 1
|
||
|
||
# Do NOT transition IN as this transition will be managed by the room's :setup event!
|
||
# If you transition IN here instead of room's :setup event, you will show the previous room
|
||
|
||
# Change scene to same scene, disabled automatic transition
|
||
change_scene res://game/rooms/room14/room14.tscn false
|
||
|
||
# Do not transition here either, as change_scene ends the execution of this script
|