p_mm.gd
Script of main menu screen, here script loads when main menu starts.
# ALWAYS extend script from Node, else game will crash, cause script handler error.
extends Node
# Calls ONLY when main menu loaded.
func _menu_init(mm : MainMenu):
# Register all our new gameplay scripts here, before gameplay actually starts.
# GameAPI.RunOutsideScript("script_name1")
# GameAPI.RunOutsideScript("script_name2")
# # # # # # # # # # # # # # # # #
# now we can do other things...
#mainmenu.version_title.text += " (Mod by ... ver. 0.1)"
#mainmenu.selected_button.position.y -= 64
# also we can separate different code for different game builds, like
# for Windows and Android. You can do it very easy!
# just use if statement with OS.has_feature("windows") or OS.has_feature("mobile")
# Called every frame in main menu
func _menu_process(delta):
pass
Last updated