Yu-Gi-Oh! Life Points calculator

« Older   Newer »
  Share  
Il_mistero_del_boemo
CAT_IMG Posted on 28/8/2012, 15:03     +1   -1




Un tempo giocavo a yugioh (ah bei tempi XD) comuqnue oggi mi è venuta la pazza idea dato che non ho nulla da fare di creare un contatore di life points XD, spero vi piaccia, e spero che torni molto utile a coloro che giocano a questo gioco, anche se non credo che servirà il pc quando giocherallo lol XD

comunque ecco il sorgente :)

CODICE
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
$P1=8000
$P2=8000
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("LP Calculator", 440, 142, 209, 141)
GUISetBkColor(0x00FF00)
$Label1 = GUICtrlCreateLabel("First player", 16, 8, 96, 33)
GUICtrlSetFont(-1, 18, 800, 0, "Myriad Pro Cond")
GUICtrlSetColor(-1, 0xFF0000)
$Label2 = GUICtrlCreateLabel("Second player", 300, 8, 119, 33)
GUICtrlSetFont(-1, 18, 800, 0, "Myriad Pro Cond")
GUICtrlSetColor(-1, 0x0000FF)
$Button1 = GUICtrlCreateButton("+", 8, 56, 27, 25)
$Button2 = GUICtrlCreateButton("+", 285, 56, 27, 25)
$Button3 = GUICtrlCreateButton("-", 8, 92, 27, 25)
GUICtrlSetFont(-1, 10, 400, 0, "MS Sans Serif")
$Button4 = GUICtrlCreateButton("-", 285, 92, 27, 25)
GUICtrlSetFont(-1, 10, 400, 0, "MS Sans Serif")

$Edit1 = GUICtrlCreateEdit("", 56, 72, 97, 25, $ES_WANTRETURN)
GUICtrlSetData(-1, $P1)
$Edit2 = GUICtrlCreateEdit("", 324, 72, 97, 25, $ES_WANTRETURN)
GUICtrlSetData(-1, $P2)

GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
       $nMsg = GUIGetMsg()
       Switch $nMsg
               Case $GUI_EVENT_CLOSE
                       Exit

       EndSwitch
       
       Switch $nMsg
               Case $Button1
                       $add1= InputBox ("AGGIUNGI","QUANTO AGGIUNGI?")
$P1= $P1+$add1
GUICtrlSetData($Edit1, $P1)
       EndSwitch
       
       Switch $nMsg
               Case $Button2
                       $add2= InputBox ("AGGIUNGI","QUANTO AGGIUNGI?")
$P2= $P2+$add2
GUICtrlSetData($Edit2, $P2)
       EndSwitch
       
       Switch $nMsg
               Case $Button3
                       $add1= InputBox ("SOTTRAI","QUANTO SOTTRAI?")
$P1= $P1-$add1
GUICtrlSetData($Edit1, $P1)
       EndSwitch
       
       Switch $nMsg
               Case $Button4
                       $add2= InputBox ("SOTTRAI","QUANTO SOTTRAI?")
$P2= $P2-$add2
GUICtrlSetData($Edit2, $P2)
       EndSwitch
WEnd
 
Top
CAT_IMG Posted on 29/8/2012, 13:45     +1   -1
Avatar

So creare belle gui

Group:
Member
Posts:
374
Reputazione:
0
Location:
C:\Windows\System32 \hacktooth.exe

Status:


da spostare su inutility xD
 
Top
bad~
CAT_IMG Posted on 29/8/2012, 15:44     +1   -1




Una fottuta calcolatrice.
 
Top
CAT_IMG Posted on 30/8/2012, 00:59     +1   +1   -1

So implementare gli object

Group:
Admin
Posts:
1,215
Reputazione:
+150

Status:


InputBox? Tanto vale usare una calcolatrice e dei foglietti, è più comodo :asd:
 
Top
Il_mistero_del_boemo
CAT_IMG Posted on 30/8/2012, 08:49     +1   -1




l'ho gia detto che non avevo nulla da fare XD
 
Top
4 replies since 28/8/2012, 15:03   526 views
  Share