Sign in to follow this  
Followers 0
AlmarM

GUI Wont Show

4 posts in this topic

#1 ·  Posted (edited)

My GUI wont show :S

Whats wrong ?

#include <GUIConstants.au3>
#include <Sound.au3>

$GUI = GUICreate("The Legend of Zelda The Minish Cap Songs.", 250, 250, -1, -1)
$SongChoose = GUICtrlCreateCombo("Choose ur Song", 10, 10, 230)
GUICtrlSetData($SongChoose, "Boss|Boss 2|Cave|Cloud Tops|Cloud Tops 2|Cloud Tops 2|Credits|Cucco Chasing Game|Cucco Chasing Game 2|Dark Hyrule Castle|Deepwood Shrine|Elemtall Sanctuary|Elemtall Sancuary 2|Fairy Fountain|File Select|Flashback|Flashback 2|Game Over|Hyrule Town|Hyrule Town 2|Hyrule Town 3|Hyrule Town 4|Minish Village|Minish Village 2|Minish Village 3|Minish Woods|Minish Woods2|Mt. Crenel|Opening Store|Palace of Winds| Picori Festival|Royal Crypt|Syrup the Witch|Temple of Dropelets|The Lost Woods|Vaati Transfigured")
GUISetState(@SW_SHOW, $GUI)

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $nMsg = $GUI_EVENT_CLOSE
            ExitLoop
        Case $SongChoose
            $Song = GUICtrlRead($SongChoose)
            Switch $Song
            Case "Boss"
                _Boss()
            Case "Boss 2"
                _Boss_2()
            Case "Cave"
                _Cave()
            Case "Cloud Tops"
                _Cloud_Tops()
            Case "Cloud Tops 2"
                _Cloud_Tops_2()
            Case "Credits"
                _Credits()
            Case "Cucco Chasing Game"
                _Cucco_Chasing_Game()
            Case "Cucco Chasing Game 2"
                _Cucco_Chasing_Game_2()
            Case "Dark Hyrule Castle"
                _Dark_Hyrule_Castle()
            Case "Deepwood Shrine"
                _Deepwood_Shrine()
            Case "Elemtall Sanctuary"
                _Elemtall_Sanctuary()
            Case "Elemtall Sanctuary 2"
                _Elemtall_Sanctuary_2()
            Case "Fairy Fountain"
                _Fairy_Fountain()
            Case "File Select"
                _File_Select()
            Case "Flashback"
                _Flashback()
            Case "Flashback 2"
                _Flashback_2()
            Case "Game Over"
                _Game_Over()
            Case "Hyrule Town"
                _Hyrule_Town()
            Case "Hyrule Town 2"
                _Hyrule_Town_2()
            Case "Hyrule Town 3"
                _Hyrule_Town_3()
            Case "Hyrule Town 4"
                _Hyrule_Town_4()
            Case "Minish Village"
                _Minish_Village()
            Case "Minish Village 2"
                _Minish_Village_2()
            Case "Minish Village 3"
                _Minish_Village_3()
            Case "Minish Woods"
                _Minish_Woods()
            Case "Minish Woods 2"
                _Minish_Woods_2()
            Case "Mt. Crenel"
                _Mt_Crenel()
            Case "Opening Store"
                _Opening_Store()
            Case "Palace of Winds"
                _Palace_of_Winds()
            Case "Picori Festival"
                _Picori_Festival()
            Case "Royal Crypt"
                _Royal_Crypt()
            Case "Syrup the Witch"
                _Syrup_the_Witch()
            Case "Temple of Droplets"
                _Temple_of_Droplets()
            Case "The Lost Woods"
                _The_Lost_Woods()
            Case "Vaati Transfigured"
                _Vaati_Transfigured()
            EndSwitch
    EndSwitch
WEnd
Edited by AlmarM

Minesweeper

A minesweeper game created in autoit, source available.

_Mouse_UDF

An UDF for registering functions to mouse events, made in pure autoit.

2D Hitbox Editor

A 2D hitbox editor for quick creation of 2D sphere and rectangle hitboxes.

Share this post


Link to post
Share on other sites



Hi,

Case $nMsg = $GUI_EVENT_CLOSE

should be

Case $GUI_EVENT_CLOSE

Mega


Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Share this post


Link to post
Share on other sites

Haha, Thx :)

Didnt knew it was that simple :)


Minesweeper

A minesweeper game created in autoit, source available.

_Mouse_UDF

An UDF for registering functions to mouse events, made in pure autoit.

2D Hitbox Editor

A 2D hitbox editor for quick creation of 2D sphere and rectangle hitboxes.

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

You could also save yourself some code:

$Song = GUICtrlRead($SongChoose)
Call("_" & StringReplace($Song, " ", "_"))

This would eliminate a long Switch...EndSwitch...

Edited by weaponx

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0