For $n = 0 to 4
If $aScores[$n+1][0] < $Height Then
$Striche[$n] = $Height - $aScores[$n][0]
EndIf
Next
; ===============================================================================================================================
; #SOUND#========================================================================================================================
Global $sPropeller = _SoundOpen(@ScriptDir & "\Sounds\propeller.wav")
Global $sFall = _SoundOpen(@ScriptDir & "\Sounds\falldown.wav")
Global $sJump = _SoundOpen(@ScriptDir & "\Sounds\Jump.wav")
Global $sRakete = _SoundOpen(@ScriptDir & "\Sounds\Jetpack.wav")
Global $sSprung = _SoundOpen(@ScriptDir & "\Sounds\Feder.wav")
Global $sSf = _SoundOpen(@ScriptDir & "\Sounds\springshoes.wav")
Global $sTrampolin = _SoundOpen(@ScriptDir & "\Sounds\trampoline.wav")
Global $sExpl = _SoundOpen(@ScriptDir & "\Sounds\explodingplatform2.wav")
Global $sBreak = _SoundOpen(@ScriptDir & "\Sounds\lomise.wav")
Global $sJumpOnMon = _SoundOpen(@ScriptDir & "\Sounds\jumponmonster.wav")
; ===============================================================================================================================
If $gruen_n[0][0] < 60 + $Doodle_Width And $gruen_n[0][0] + $Plat_Width > 60 + $Doodle_Width Then
$x = $Width - 60
Else
$x = 60
EndIf
GUISetState(@SW_SHOW)
While 1
Sleep(20)
If Not $gfWeAreActive Then ContinueLoop
If $iStatus <> $ST_options Then $changestate = 1
Switch $iStatus
Case $ST_playing
$y25 = $Height / 2 - 37.5
$y26 = $y25 + 36
$iStatus = _DrawGame_CheckInput()
Case $ST_paused
$iStatus = _DrawPause_CheckInput()
Case $ST_pause_menu
$iStatus = _DrawPauseMenu_CheckInput()
Case $ST_game_over
$iStatus = _DrawGameOver_CheckInput()
Case $ST_enter_score
$iStatus = _DrawEnterScore_CheckInput()
Case $ST_scores
$iStatus = _DrawScores_CheckInput()
Case $ST_main_menu
$iStatus = _DrawMain_CheckInput()
Case $ST_options
If $changestate Then $optionspage = 1
$iStatus = _DrawOptions_CheckInput()
EndSwitch
WEnd
Local $aMouseInfo = GUIGetCursorInfo($GUI1)
If @error Then
_MouseDownEvent(0)
Return $ST_main_menu
ElseIf _MouseDownEvent($aMouseInfo[2]) Then
;~ MsgBox(0,$aMouseInfo[0],$aMouseInfo[1])
Select
Case $aMouseInfo[0] > 153 And $aMouseInfo[0] < 266 And $aMouseInfo[1] > 295 And $aMouseInfo[1] < 335
Return $ST_options
Case $aMouseInfo[0] > 48 And $aMouseInfo[0] < 151 And $aMouseInfo[1] > 122 And $aMouseInfo[1] < 159
;~ MsgBox(0, '', "Spielen")
_NewGame()
Return $ST_playing
Case $aMouseInfo[0] > 77 And $aMouseInfo[0] < 183 And $aMouseInfo[1] > 179 And $aMouseInfo[1] < 217
Return $ST_scores
Case $aMouseInfo[0] > 186 And $aMouseInfo[0] < 214 And $aMouseInfo[1] > 423 And $aMouseInfo[1] < 444 And $wintermod
$wintermod = 0
_LoadSkin()
Return $ST_main_menu
Case $aMouseInfo[0] > 151 And $aMouseInfo[0] < 182 And $aMouseInfo[1] > 423 And $aMouseInfo[1] < 443 And Not $wintermod
$wintermod = 1
_LoadSkin('winter')
Return $ST_main_menu
Case $aMouseInfo[0] > 280 And $aMouseInfo[0] < 296 And $aMouseInfo[1] > 4 And $aMouseInfo[1] < 20
ende()
Case $aMouseInfo[0] > 1 And $aMouseInfo[1] > 431 and $aMouseInfo[0] < 36 and $aMouseInfo[1] < 451 and not $NoobyMod
_LoadSkin("nooby")
Case $aMouseInfo[0] > 1 And $aMouseInfo[1] > 431 and $aMouseInfo[0] < 36 and $aMouseInfo[1] < 451 and $NoobyMod
$NoobyMod = False
_LoadSkin('')
Case Else
EndSelect
EndIf
Return $ST_main_menu
EndFunc ;==>_DrawMain_CheckInput
Local $aMouseInfo = GUIGetCursorInfo($GUI1)
If @error Then
_MouseDownEvent(0)
Return $ST_options
ElseIf _MouseDownEvent($aMouseInfo[2]) Then
Select
Case $aMouseInfo[0] > 169 And $aMouseInfo[0] < 273 And $aMouseInfo[1] > 350 And $aMouseInfo[1] < 389
IniWrite($datapath, "Optionen", "movement", $movement)
IniWrite($datapath, "Optionen", "soundoff", $soundoff)
IniWrite($datapath, "Optionen", "directionalShooting", $DirectionalShooting)
IniWrite($datapath, "Optionen", "sensible", $mousesensible)
IniWrite($datapath, "Optionen", "speed", $speed)
Return $ST_main_menu
Case $aMouseInfo[0] > 45 And $aMouseInfo[0] < 90 And $aMouseInfo[1] > 133 And $aMouseInfo[1] < 141 and $optionspage = 1
$movement = 0
Case $aMouseInfo[0] > 116 And $aMouseInfo[0] < 196 And $aMouseInfo[1] > 133 And $aMouseInfo[1] < 141 and $optionspage = 1
$movement = 1
Case $aMouseInfo[0] > 51 And $aMouseInfo[0] < 69 And $aMouseInfo[1] > 251 And $aMouseInfo[1] < 260 and $optionspage = 1
$soundoff = 0
Case $aMouseInfo[0] > 123 And $aMouseInfo[0] < 147 And $aMouseInfo[1] > 251 And $aMouseInfo[1] < 260 and $optionspage = 1
$soundoff = 1
Case $aMouseInfo[0] > 76 And $aMouseInfo[0] < 93 And $aMouseInfo[1] > 319 And $aMouseInfo[1] < 329 and $optionspage = 1
$DirectionalShooting = 1
Case $aMouseInfo[0] > 163 And $aMouseInfo[0] < 186 And $aMouseInfo[1] > 315 And $aMouseInfo[1] < 329 and $optionspage = 1
$DirectionalShooting = 0
Case $aMouseInfo[0] > 280 And $aMouseInfo[0] < 296 And $aMouseInfo[1] > 4 And $aMouseInfo[1] < 20
ende()
Case $aMouseInfo[0] > 145 And $aMouseInfo[0] < 217 And $aMouseInfo[1] > 414 And $aMouseInfo[1] < 447 and $optionspage = 1
$optionspage = 2
Case $aMouseInfo[0] > 85 And $aMouseInfo[0] < 144 And $aMouseInfo[1] > 414 And $aMouseInfo[1] < 447 and $optionspage = 2
$optionspage = 1
EndSelect
_GDIPlus_GraphicsDrawImage($Buffer, $Scorebackground, 0, 0)
For $n = 1 To 5
If $aScores[$n][0] > 0 Then
_GDIPlus_GraphicsDrawString($Buffer, $aScores[$n][0], $Width - 90, 188 + ($n - 1) * 23, "Comic Sans MS", 12)
_GDIPlus_GraphicsDrawString($Buffer, " "&$aScores[$n][1], $Width - 250, 188 + ($n - 1) * 23, "Comic Sans MS", 12)
EndIf
Next
_GDIPlus_GraphicsDrawImage($Buffer, $Doodle_Rechts, $x1, $y)
_GDIPlus_GraphicsDrawImage($Buffer, $Platform_gruen, 50, 400)
_GDIPlus_GraphicsDrawImage($Buffer, $imgBeenden, $Width - 20, 4)
;~ _GDIPlus_GraphicsDrawImageRect($Graphic, $Bitmap, 0, 0, $Width, $Height)
_WinAPI_RedrawWindow($GUI1, 0, 0, $RDW_INTERNALPAINT)
Local $aMouseInfo = GUIGetCursorInfo($GUI1)
If @error Then
_MouseDownEvent(0)
Return $ST_scores
ElseIf _MouseDownEvent($aMouseInfo[2]) Then
If $aMouseInfo[0] > 161 And $aMouseInfo[0] < 267 And $aMouseInfo[1] > 380 And $aMouseInfo[1] < 421 Then
Return $ST_main_menu
ElseIf $aMouseInfo[0] > 280 And $aMouseInfo[0] < 296 And $aMouseInfo[1] > 4 And $aMouseInfo[1] < 20 Then
ende()
EndIf
EndIf
Return $ST_scores
EndFunc ;==>_DrawScores_CheckInput
If Not $paused Then Return $ST_playing
Local $aMouseInfo = GUIGetCursorInfo($GUI1)
If @error Then
_MouseDownEvent(0)
Return $ST_pause_menu
ElseIf _MouseDownEvent($aMouseInfo[2]) Then
Select
Case $aMouseInfo[0] > 99 And $aMouseInfo[0] < 203 And $aMouseInfo[1] > 172 And $aMouseInfo[1] < 208
$paused = 0
_NewGame()
Return $ST_playing
Case $aMouseInfo[0] > 97 And $aMouseInfo[0] < 202 And $aMouseInfo[1] > 252 And $aMouseInfo[1] < 288
$paused = 0
Return $ST_main_menu
Case $aMouseInfo[0] > 280 And $aMouseInfo[0] < 296 And $aMouseInfo[1] > 4 And $aMouseInfo[1] < 20
ende()
;~ Case $aMouseInfo[0] > 0 And $aMouseInfo[0] < 276 And $aMouseInfo[1] > 0 And $aMouseInfo[1] < 34
;~ Opt("Mousecoordmode", 1)
;~ Do
;~ $aMouseInfo = GUIGetCursorInfo($GUI1)
;~ WinMove($GUI1, "", $aMouseInfo[0]-($Width/2), $aMouseInfo[1]-17, $Width, $Height, 1)
;~ Until not _IsPressed(01, $dll)
;~ Opt("Mousecoordmode", 0)
EndSelect
EndIf
;~ If (_IsPressed(01, $dll) and ) Then
;~ $mpos = MouseGetPos()
;~ $drag = 1
;---------------------------------------------------------------------Monster--------------------------------------------------------
If $score > $monsterscore Then
Switch $Mobexist
Case 1
If $coordcheck = False Then
$coordold = $coord1
$coordcheck = True
EndIf
If $coord1 = $coordold or $coord1 = $coordold + 6 Then
$moveright *= -1
EndIf
$coord1 += $moveright
Mobcheck()
Case 2
If $coordcheck = False Then
$coordold = $coord1
$coordcheck = True
EndIf
If $coord1 = $coordold or $coord1 = $coordold + 6 Then
$moveright = $moveright * -1
EndIf
$coord1 += $moveright
Mobcheck()
Case 3
If $mobset = 0 Then
If $coordcheck = False Then
$coord3 = $coord2+33
$coordcheck = True
EndIf
Mobcheck()
EndIf
Case 4
If $coordcheck = False Then
$coordold = $coord2
$coordcheck = True
EndIf
If $coord2 = $coordold or $coord2 = $coordold - 6 Then
$moveright = $moveright *-1
EndIf
$coord2 -= 2
If $mobtimeron = False Then
$mobtimeron = True
$mobtimer = TimerInit()
EndIf
$mobdiff = TimerDiff($mobtimer)
If $mobdiff >= $change Then
$change += 150
$aktuellerMob = Eval("Flug" & $Bild)
;MsgBox(0,"",$aktuellerMob)
$Bild += 1
If $Bild > 2 Then
$Bild = 1
EndIf
EndIf
If $coord2 < -100 Then
$Mobexist = 0
EndIf
Mobcheck()
Case 5
;~ If $coord1 > 230 or $coord1 < 39 Then
;~ If $coord1 < 39 Then
;~ $coord1 = 40
;~ EndIf
;~ $moveright = $moveright *-1
;~ EndIf
If $coord1 > 261-39 Then $moveright = -3
If $coord1 < 39 Then $moveright = 3
$coord1 += $moveright
If $moveright < 0 Then
$aktuellerMob = $MoveMobl
Else
$aktuellerMob = $MoveMobr
EndIf
If $coordcheck = False Then
$coordold = $coord2
$choordcheck = True
EndIf
$coordold += $Platmovespeed
If $coord2 > $coordold +5 or $coord2 < $coordold Then
$moveup = $moveup *-1
EndIf
$coord2 += $moveup
Mobcheck()
Case 6
If $ufoset = 0 Then
If $coordcheck = False Then
$coordold = $coord1
$coordcheck = True
EndIf
If $coord1 <= $coordold or $coord1 >= $coordold + 5 Then
$moveright *= -1
EndIf
$coord1 += $moveright
Mobcheck(96)
EndIf
Case 7
If $coordcheck = False Then
$coordold = $coord1
$coordcheck = True
EndIf
If $coord1 = $coordold or $coord1 > $coordold + $Width/3 Then
$moveright *= -1
EndIf
$coord1 += $moveright
Mobcheck()
Case -1
If $setloch = 0 Then
If not $protected And(($coord1 <= $x + $Doodle_Width - $DOODLE_BORDER And $coord1 + $mobwidth >= $x + $Doodle_Width) or ($coord1 <= $x And $coord1 + $mobwidth >= $x) or ($coord1 >= $x And $coord1 + $mobwidth <= $x + $Doodle_Width)) And (($y <= $coord2 + $mobheight And $y + $Doodle_Height >= $coord2 + $mobheight) or ($y <= $coord2 And $y + $Doodle_Height >= $coord2 + $mobheight)) Then
$letdie = 1
EndIf
EndIf
Case 8
If $coordcheck = False Then
$coordold = $coord2
$coordcheck = True
EndIf
If $coord1 <= 10 or $coord1 >= $Width-10-$mobwidth Then
$moveright = $moveright *-1
EndIf
$coord2 -= 2
$coord1 += $moveright
If $mobtimeron = False Then
$mobtimeron = True
$mobtimer = TimerInit()
EndIf
$mobdiff = TimerDiff($mobtimer)
If $mobdiff >= $change Then
$change += 150
$aktuellerMob = Eval("Flug2" & $Bild)
;MsgBox(0,"",$aktuellerMob)
$Bild += 1
If $Bild > 2 Then
$Bild = 1
EndIf
EndIf
If $coord2 < -150 Then
$Mobexist = 0
EndIf
Mobcheck()
Case 0 and $raketeon = 0 and $huton = 0
CreateMob()
EndSwitch
$coord2 += $Platmovespeed
$coord3 += $Platmovespeed
If $coord2 > 460 Then
$Mobexist = 0
EndIf
EndIf
If $huton = 0 and $raketeon = 0 Then
Local $aMouseInfo = GUIGetCursorInfo($GUI1)
If @error Then
_MouseDownEvent(0)
ElseIf _MouseDownEvent($aMouseInfo[2]) Then
If $AktuellerDoodle <> $Doodle_Schuss Then $aAktuellerDoodle = $AktuellerDoodle
$geschossen = 1
If $DirectionalShooting Then
If $aMouseInfo[1] < $y Then
$mouseX = $aMouseInfo[0] - $x - 27
$mouseY = $y - $aMouseInfo[1]
$verhX = $mouseX / $mouseY
If UBound($schuss) = 1 Then
_Array2DAdd($schuss, $x+27.5&"|"&$y-11&"|"&$mBewegX&"|"&$mBewegY)
EndIf
_Array2DAdd($schuss, $x+27.5&"|"&$y-11&"|"&$mBewegX&"|"&$mBewegY)
EndIf
Else
$mBewegX = 0
$mBewegY = 10
If UBound($schuss) = 1 Then
_Array2DAdd($schuss, $x+27.5&"|"&$y-11&"|"&$mBewegX&"|"&$mBewegY)
EndIf
_Array2DAdd($schuss, $x+27.5&"|"&$y-11&"|"&$mBewegX&"|"&$mBewegY)
EndIf
EndIf
If $geschossen > 0 Then
$geschossen += 1
EndIf
If $geschossen >= 15 Then
$geschossen = 0
$AktuellerDoodle = $aAktuellerDoodle
EndIf
If $geschossen < 15 And $geschossen > 0 Then
If (($DirectionalShooting And $aMouseInfo[1] < $y) or not $DirectionalShooting) Then
If $Sprungf = 0 Then
$AktuellerDoodle = $Doodle_Schuss
Else
$AktuellerDoodle = $Doodle_Sf_Schuss
EndIf
EndIf
EndIf
EndIf
;~ If not $DirectionalShooting Then $AktuellerDoodle = $Doodle_Schuss
;~ EndIf
For $n = 2 to UBound($schuss) - 1
$schuss[$n][1] += $Platmovespeed
$schuss[$n][1] -= $schuss[$n][3]
$schuss[$n][0] += $schuss[$n][2]
If $schuss[$n][1] < -100 Then
_ArrayDelete($schuss, $n)
ExitLoop
Else
EndIf
If $Mobexist > 0 Then
If ($coord1 <= $schuss[$n][0] And $coord1 +$mobwidth>= $schuss[$n][0]) And ($schuss[$n][1] >= $coord2 And $schuss[$n][1] - 15 <= $coord2 + $mobheight) Then
$mobdead -= 1
If $mobdead = 0 Then $Mobexist = 0
_ArrayDelete($schuss, $n)
ExitLoop
EndIf
EndIf
Next
If $huton = 0 And $raketeon = 0 and not $letdie Then
For $n = 0 To UBound($gruen_n, 1) - 1 Step 1
If $gruen_n[$n][3] = 7 Then $gruen_n[$n][3] = 6
If $untersprung = 0 Then
Local $range = 20, $change = $sprungkraft * $t - ($grav / 2) * $t ^ 2
If $change < -10 Then $range = _Min(-$change, 40)
If $gruen_n[$n][2] = 6 Then
$multip = 2
Else
$multip = 1
EndIf
Select
Case ($gruen_n[$n][0] <= $x + $Doodle_Width - $DOODLE_BORDER And $gruen_n[$n][0] + $Plat_Width*$multip >= $x + $DOODLE_BORDER) And ($y + $Doodle_Height - $range <= $gruen_n[$n][1] And $y + $Doodle_Height >= $gruen_n[$n][1] and $gruen_n[$n][2] > -1)
If $yalt + 1 < $y Then
If $gruen_n[$n][2] = 3 Then
$braunf[$n] = 1
If not $soundoff Then _SoundPlay($sBreak)
Else
If $gruen_n[$n][2] = 4 Then
If $weisweg[$n] = 0 Then
If $soundoff = 0 And $rotweg[$n] = 0 And $weisweg[$n] = 0 Then
If $sprung = 0 And $Sprungf = 0 Then _SoundPlay($sJump)
If $Sprungf = 1 Then _SoundPlay($sSf)
If $sprungtr = 1 Then _SoundPlay($sTrampolin)
If $sprung = 1 Then _SoundPlay($sSprung)
EndIf
If $gruen_n[$n][2] = 4 Then
$weisweg[$n] = 1
EndIf
EndIf
EndIf
EndSelect
EndIf
Next
EndIf
If $untereplatte = 1 Then
If $y + $Doodle_Height > $Height - 20 And $y + $Doodle_Height < $Height Then
If $soundoff = 0 Then _SoundPlay($sJump)
$yboden = $Height
$t = 0
$t = $Zeitschrit
$untereplatte = 1
EndIf
EndIf
;~ For $n = 0 to Ubound(
$x += $MoveSpeed * $t / 10
;~ If $raketeon = 0 And $huton = 0 Then
;~ If $ybodenalt > $yboden Then $scoreplus += Abs(($yboden - $ybodenalt))
;~ EndIf
$scoreplus += Round($Platmovespeed)
$strichscore = $scoreplus + $y
;~
If $y - 5 > $Height Then $die = True
If $huton = 1 Then
$plus = 15
ElseIf $raketeon = 1 Then
$plus = 30
Else
$plus = 10
EndIf
If $scoreplus > $score Then
$score += $plus
EndIf
;======================HUT
If $huton = 1 Then
If $timeron = 0 Then
If $soundoff = 0 Then _SoundPlay($sPropeller, 0)
$huttimer = _Timer_Init()
$timeron = 1
$tnorm = $t
$t = $hutt
EndIf
$Platmovespeed = 15
$time = _Timer_Diff($huttimer)
If $hutbild = 0 Then
If $AktuellerDoodle = $DoodleHutl Then
$AktuellerDoodle = $DoodleHutl1
ElseIf $AktuellerDoodle = $DoodleHutr Then
$AktuellerDoodle = $DoodleHutr1
EndIf
$hutbild = 1
Else
If $AktuellerDoodle = $DoodleHutl1 Then
$AktuellerDoodle = $DoodleHutl
ElseIf $AktuellerDoodle = $DoodleHutr1 Then
$AktuellerDoodle = $DoodleHutr
EndIf
$hutbild = 0
EndIf
If $time >= 3000 Then
$t = $tnorm
$huton = 0
$timeron = 0
If $AktuellerDoodle = $DoodleHutr Then
$AktuellerDoodle = $Doodle_Rechts
Else
$AktuellerDoodle = $Doodle_Links
EndIf
EndIf
EndIf
;~ MsgBox(0, "", $scoreplus&"|"&$strichscore)
;=========================Protection
If $protected Then
If not $protectiontimer Then
$ptimer = _Timer_Init()
$protectiontimer = 1
EndIf
If _Timer_Diff($ptimer) > 10000 Then
$protected = 0
$protectiontimer = 0
EndIf
EndIf
;=========================Rakete
If $raketeon = 1 Then
If $timerrakon = 0 Then
If $soundoff = 0 Then _SoundPlay($sRakete, 0)
$raketentimer = _Timer_Init()
$timerrakon = 1
$tnorm = $t
$t = $hutt
If $AktuellerDoodle = $Doodle_Rechts Then
$AktuellerDoodle = $DoodleRakr
Else
$AktuellerDoodle = $DoodleRakl
EndIf
EndIf
$Platmovespeed = 30
$time = _Timer_Diff($raketentimer)
If $time >= 3000 Then
$raketeon = 0
$timerrakon = 0
$t = $tnorm
If $AktuellerDoodle = $DoodleRakr Then
$AktuellerDoodle = $Doodle_Rechts
Else
$AktuellerDoodle = $Doodle_Links
EndIf
If $fSprung = 0 Then
If $sprungtr = 1 Then
If $Angle = 360 Then
$Angle = 0
$untersprung = 0
$fSprung = 1
Else
$untersprung = 1
$Angle += 15
EndIf
EndIf
EndIf
If $letdie Then
If $dAngle = 360 Then
$dAngle = 0
$letdie = 0
$die = True
Else
$dAngle += 30
EndIf
EndIf
;~ MsgBox(0, "", $aScores[1][0])
If $move = 1 Then
$untereplatte = 0
If $huton = 0 And $raketeon = 0 and not $letdie Then
$yboden += $Platmovespeed
EndIf
For $n = 0 to UBound($Striche)-1
If $strichscore-5 <= $aScores[$n+1][0] and $strichscore+5 >= $aScores[$n+1][0] and $Striche[$n] = -10 Then
$Striche[$n]= -5
EndIf
If $Striche[$n] <> -10 Then $Striche[$n] += $Platmovespeed
Next
If $activepressed > -1 Then
If $gruen_n[$activepressed][2] = 0 Then $activepressed = -1
EndIf
If not _IsPressed(01) Then
$activepressed = -1
EndIf
For $n = 0 To UBound($gruen_n) - 1
If _IsPressed(01) Then
$nMsg = MouseGetPos()
If (_PointIsInEllipse($nMsg[0], $nMsg[1], $gruen_n[$n][0] + ($Plat_Width+20) / 2, $gruen_n[$n][1] +22.5, $Plat_Width+20, 45)=0 and $gruen_n[$n][2] = 7) or $activepressed > -1 Then
If $activepressed = -1 Then
$activepressed = $n
Else
;-----------------------------------------------------------------------------------------Mobs 2----------------------------------------------------------------------
Switch $Mobexist
Case 1
_GdiPlus_GraphicsDrawImage($Buffer,$Monster_Gruen,$coord1,$coord2)
Case 2
_GdiPlus_GraphicsDrawImage($Buffer,$Monster_Lila,$coord1,$coord2)
Case 3
If $mobset = 0 Then _GdiPlus_GraphicsDrawImage($Buffer,$Yeti,$coord1,$coord2+5)
If UBound($schuss) >= 3 Then
For $n = 2 To UBound($schuss)-1
_GdiPlus_GraphicsDrawImage($Buffer,$Kugel,$schuss[$n][0],$schuss[$n][1])
Next
Endif
If $protected Then _GDIPlus_GraphicsDrawImageRect($Buffer, $protect, $x+$Doodle_Width/2 - $Protect_Width/2, $y+$Doodle_Height/2 - $Protect_Height/2, 100, 100)
For $n = 0 to UBound($Striche)-1
If $Striche[$n] <> -10 Then
_GdiPlus_GraphicsDrawImage($Buffer,$Strich,$Width - 49,$Striche[$n])
_GDIPlus_GraphicsDrawString ($Buffer, $aScores[$n+1][1], $Width, $Striche[$n]-12, "Comic Sans MS", 7, 0x0001)
;~ MsgBox(0, $n, $aScores[$n+1][1]&"|"&$aScores[$n+1][0])
If $die Then
If Not $soundoff Then _SoundPlay($sFall)
Return $ST_game_over
EndIf
Return $ST_playing
EndFunc ;==>_DrawGame_CheckInput
Func Mobcheck($scheinheight = 0)
If (($coord1 <= $x + $Doodle_Width - $DOODLE_BORDER And $coord1 + $mobwidth >= $x + $Doodle_Width- $DOODLE_BORDER) or ($coord1 <= $x And $coord1 + $mobwidth >= $x) or ($coord1 >= $x And $coord1 + $mobwidth <= $x + $Doodle_Width)) And (($y <= $coord2 + $mobheight + $scheinheight And $y + $Doodle_Height >= $coord2 + $mobheight + $scheinheight) or ($y <= $coord2 And $y + $Doodle_Height >= $coord2 + $mobheight)) and not $protected Then
If $huton = 1 or $raketeon = 1 Then
$Mobexist = 0
Else
$die = True
EndIf
EndIf
If (($coord1 <= $x + $Doodle_Width - $DOODLE_BORDER And $coord1 + $mobwidth >= $x + $Doodle_Width- $DOODLE_BORDER) or ($coord1 <= $x And $coord1 + $mobwidth >= $x) or ($coord1 >= $x And $coord1 + $mobwidth <= $x + $Doodle_Width)) And ($y + $Doodle_Height <= $coord2 And $y + $Doodle_Height + 15 >= $coord2) Then
If $yalt + 1 < $y Then
If not $soundoff Then _SoundPlay($sJumpOnMon)
$t = $Zeitschrit
$yboden = $coord2
$Mobexist = 0
If $sprung = 1 Then
$sprung = 0
$sprungkraft /= 1.5
EndIf
If $sprungtr = 1 Then
$fSprung = 0
$sprungtr = 0
$sprungkraft /= 2
EndIf
If $Sprungf = 1 Then
If $AktuellerDoodle = $Doodle_sf_r Then
$AktuellerDoodle = $Doodle_sf_gesch_r
Else
$AktuellerDoodle = $Doodle_sf_gesch_l
EndIf
If $Sprungnu = 6 Then
$Sprungf = 0
$Sprungnu = 0
$sprungkraft = 50
If $AktuellerDoodle = $Doodle_sf_gesch_r Then
$AktuellerDoodle = $Doodle_Rechts
Else
$AktuellerDoodle = $Doodle_Links
EndIf
Else
$Sprungnu += 1
EndIf
If @error Then Return SetError(@error, @extended, False)
$GDIP_STATUS = $aResult[0] Return $aResult[0] = 0
EndFunc ;==>_GDIPlus_ImageAttributesSetWrapMode
Func _GDIPlus_GraphicsDrawImageRectRectTrans($hGraphics, $hImage, $iSrcX, $iSrcY, $iSrcWidth = "", $iSrcHeight = "", _
$iDstX = "", $iDstY = "", $iDstWidth = "", $iDstHeight = "", $iUnit = 2, $nTrans = 1)
Local $tColorMatrix, $x, $hImgAttrib, $iW = _GDIPlus_ImageGetWidth($hImage), $iH = _GDIPlus_ImageGetHeight($hImage)
If $iSrcWidth = 0 Or $iSrcWidth = "" Then $iSrcWidth = $iW If $iSrcHeight = 0 Or $iSrcHeight = "" Then $iSrcHeight = $iH If $iDstX = "" Then $iDstX = $iSrcX If $iDstY = "" Then $iDstY = $iSrcY If $iDstWidth = "" Then $iDstWidth = $iSrcWidth If $iDstHeight = "" Then $iDstHeight = $iSrcHeight If $iUnit = "" Then $iUnit = 2
;;create color matrix data
$tColorMatrix = DllStructCreate("float[5];float[5];float[5];float[5];float[5]")
;blending values:
$x = DllStructSetData($tColorMatrix, 1, 1, 1) * DllStructSetData($tColorMatrix, 2, 1, 2) * DllStructSetData($tColorMatrix, 3, 1, 3) * _
DllStructSetData($tColorMatrix, 4, $nTrans, 4) * DllStructSetData($tColorMatrix, 5, 1, 5)
;;create an image attributes object and update its color matrix
$hImgAttrib = DllCall($ghGDIPdll, "int", "GdipCreateImageAttributes", "ptr*", 0)
$hImgAttrib = $hImgAttrib[1] DllCall($ghGDIPdll, "int", "GdipSetImageAttributesColorMatrix", "ptr", $hImgAttrib, "int", 1, _
"int", 1, "ptr", DllStructGetPtr($tColorMatrix), "ptr", 0, "int", 0)
;;draw image into graphic object with alpha blend
DllCall($ghGDIPdll, "int", "GdipDrawImageRectRectI", "hwnd", $hGraphics, "hwnd", $hImage, "int", $iDstX, "int", _
$iDstY, "int", $iDstWidth, "int", $iDstHeight, "int", $iSrcX, "int", $iSrcY, "int", $iSrcWidth, "int", _
$iSrcHeight, "int", $iUnit, "ptr", $hImgAttrib, "int", 0, "int", 0)
;;clean up
DllCall($ghGDIPdll, "int", "GdipDisposeImageAttributes", "ptr", $hImgAttrib)
Return
EndFunc ;==>_GDIPlus_GraphicsDrawImageRectRectTrans
; #FUNCTION# ====================================================================================================================
; Name...........: _GDIPlus_GraphicsRotateTransform
; Description ...: Updates the world transformation matrix of a Graphics object with the product of itself and a rotation matrix
; Syntax.........: _GDIPlus_GraphicsRotateTransform($hGraphics, $nAngle[,$iOrder = 0])
; Parameters ....: $hGraphics - Pointer to a Graphics object
; $nAngle - The angle, in degrees, of rotation
; $iOrder - Order of matrices multiplication:
; |0 - The rotation matrix is on the left
; |1 - The rotation matrix is on the right
; Return values .: Success - True
; Failure - False and either:
; |@error and @extended are set if DllCall failed
; |$GDIP_STATUS contains a non zero value specifying the error code
; Remarks .......: None
; Related .......: _GDIPlus_GraphicsMultiplyTransform
; Link ..........; @@MsdnLink@@ GdipRotateWorldTransform
; Example .......; No
; ===============================================================================================================================
Func _GDIPlus_GraphicsRotateTransform($hGraphics, $nAngle, $iOrder = 0)
Local $aResult = DllCall($ghGDIPdll, "uint", "GdipRotateWorldTransform", "hwnd", $hGraphics, "float", $nAngle, "int", $iOrder)
If @error Then Return SetError(@error, @extended, False)
$GDIP_STATUS = $aResult[0] Return $aResult[0] = 0
EndFunc ;==>_GDIPlus_GraphicsRotateTransform
; #FUNCTION# ====================================================================================================================
; Name...........: _GDIPlus_GraphicsResetTransform
; Description ...: Sets the world transformation matrix of a Graphics object to the identity matrix
; Syntax.........: _GDIPlus_GraphicsResetTransform($hGraphics)
; Parameters ....: $hGraphics - Pointer to a Graphics object
; Return values .: Success - True
; Failure - False and either:
; |@error and @extended are set if DllCall failed
; |$GDIP_STATUS contains a non zero value specifying the error code
; Remarks .......: None
; Related .......: None
; Link ..........; @@MsdnLink@@ GdipResetWorldTransform
; Example .......; No
; ===============================================================================================================================
Func _GDIPlus_GraphicsResetTransform($hGraphics)
Local $aResult = DllCall($ghGDIPdll, "uint", "GdipResetWorldTransform", "hwnd", $hGraphics)
If @error Then Return SetError(@error, @extended, False)
$GDIP_STATUS = $aResult[0] Return $aResult[0] = 0
EndFunc ;==>_GDIPlus_GraphicsResetTransform
; #FUNCTION# ====================================================================================================================
; Name...........: _GDIPlus_GraphicsTranslateTransform
; Description ...: Updates a Graphics object's world transformation matrix with the product of itself and a translation matrix
; Syntax.........: _GDIPlus_GraphicsTranslateTransform($hGraphics, $nDX, $nDY[,$iOrder = 0])
; Parameters ....: $hGraphics - Pointer to a Graphics object
; $nDX - Horizontal component of the translation
; $nDY - Vertical component of the translation
; $iOrder - Order of matrices multiplication:
; |0 - The translation matrix is on the left
; |1 - The translation matrix is on the right
; Return values .: Success - True
; Failure - False and either:
; |@error and @extended are set if DllCall failed
; |$GDIP_STATUS contains a non zero value specifying the error code
; Remarks .......: None
; Related .......: None
; Link ..........; @@MsdnLink@@ GdipTranslateWorldTransform
; Example .......; No
; ===============================================================================================================================
Func _GDIPlus_GraphicsTranslateTransform($hGraphics, $nDX, $nDY, $iOrder = 0)
Local $aResult = DllCall($ghGDIPdll, "uint", "GdipTranslateWorldTransform", "hwnd", $hGraphics, "float", $nDX, "float", $nDY, "int", $iOrder)
If @error Then Return SetError(@error, @extended, False)
$GDIP_STATUS = $aResult[0] Return $aResult[0] = 0
EndFunc ;==>_GDIPlus_GraphicsTranslateTransform
Func _MouseDownEvent($fDown = 0)
; Author: ProgAndy
Local Static $fSaved = 0
Local $fState = $fSaved $fSaved = $fDown Return $fDown And ($fState <> $fDown)
EndFunc ;==>_MouseDownEvent
Func _Array2DAdd(ByRef $avArray, $sValue='')
If ( Not IsArray($avArray) ) Then
SetError(1)
Return 0
EndIf
Local $UBound2nd = UBound($avArray,2)
If @error = 2 Then
ReDim $avArray[UBound($avArray)+1] $avArray[UBound($avArray)-1] = $sValue Else
Local $arValue ReDim $avArray[UBound($avArray)+1][$UBound2nd]
If $sValue = '' Then
For $i = 0 To $UBound2nd-2
$sValue &= '|'
Next
EndIf
$arValue = StringSplit($sValue, '|')
If $arValue[0] <> $UBound2nd Then
SetError(2)
Return 0
EndIf
For $i = 0 To $UBound2nd-1
$avArray[UBound($avArray)-1][$i] = $arValue[$i+1] Next
EndIf
Return -1
EndFunc ;==>_Array2DAdd
Doodle Jump vs. Mega Jump! 10/16/2011 - Off Topic - 47 Replies Hi OT,
Ihr kennt sicherlich die iPhone/iPod Spiele Doodle und Mega Jump, moechte mal wissen welches ihr besser findet und natuerlich eure Scores!
Ich fang dann mal an:
Ich habe frueher nur Doodle Jump gespielt, weil ich
Mega Jump nicht kannte, aber Doodle Jump wurde mir schnell lw, nun spiele ich nur noch Mega Jump,
weil ich es vielfaeltiger finde!
[NEW]Doodle Jump für den PC [HOT] 10/07/2011 - Tutorials - 77 Replies Heyhoo hier da draußen!!!
Ich habe kürzlich im Internet Doodle Jump für den PC gefunden!!! Download link ist unten.
1. Ihr ladet euch die Version 8 runter.
http://img693.imageshack.us/img693/9886/15619650. jpg
Doodle Jump [Win7] AutoIt 05/23/2011 - AutoIt - 25 Replies Doodle Jump für PC
So hier ist die aktuelle Version von Doodle Jump für den Pc.
Die Datei ist sowohl als .exe Datei, als auch als .au3 Datei verfügbar.
Aktuelle Version:
Doodle Jump V8 Download als Win.rar Archiv