Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Sub Table1_KeyDown(ByVal Keycode)
- If Keycode = AddCreditKey Then
- Credits = Credits + 1
- DOF 114, DOFOn
- If(Tilted = False) Then
- DMDFlush
- DMD "black.jpg", "", "CREDITS " &credits, 500
- PlaySound "fx_coin"
- If NOT bGameInPlay Then ShowTableInfo
- End If
- End If
- If keycode = PlungerKey Then
- Plunger.Pullback
- End If
- If hsbModeActive Then
- EnterHighScoreKey(keycode)
- Exit Sub
- End If
- ' Table specific
- ' Normal flipper action
- If bGameInPlay AND NOT Tilted Then
- If keycode = LeftTiltKey Then Nudge 90, 6:PlaySound "fx_nudge", 0, 1, -0.1, 0.25:CheckTilt
- If keycode = RightTiltKey Then Nudge 270, 6:PlaySound "fx_nudge", 0, 1, 0.1, 0.25:CheckTilt
- If keycode = CenterTiltKey Then Nudge 0, 7:PlaySound "fx_nudge", 0, 1, 1, 0.25:CheckTilt
- If keycode = LeftFlipperKey Then SolLFlipper 1:InstantInfoTimer.Enabled = True
- If keycode = RightFlipperKey Then SolRFlipper 1:InstantInfoTimer.Enabled = True
- If keycode = StartGameKey Then
- If((PlayersPlayingGame <MaxPlayers) AND(bOnTheFirstBall = True) ) Then
- If(bFreePlay = True) Then
- PlayersPlayingGame = PlayersPlayingGame + 1
- TotalGamesPlayed = TotalGamesPlayed + 1
- DMDFlush
- DMD "black.jpg", " ", PlayersPlayingGame & " PLAYERS", 500
- PlaySound "so_fanfare1"
- Else
- If(Credits> 0) then
- PlayersPlayingGame = PlayersPlayingGame + 1
- TotalGamesPlayed = TotalGamesPlayed + 1
- Credits = Credits - 1
- DMDFlush
- DMD "black.jpg", " ", PlayersPlayingGame & " PLAYERS", 500
- PlaySound "so_fanfare1"
- Else
- ' Not Enough Credits to start a game.
- DOF 114, DOFOff
- DMDFlush
- DMD "black.jpg", "CREDITS " &credits, "INSERT COIN", 500
- PlaySound "so_nocredits"
- End If
- End If
- End If
- End If
- Else ' If (GameInPlay)
- If keycode = StartGameKey Then
- If(bFreePlay = True) Then
- If(BallsOnPlayfield = 0) Then
- ResetForNewGame()
- End If
- Else
- If(Credits> 0) Then
- If(BallsOnPlayfield = 0) Then
- Credits = Credits - 1
- ResetForNewGame()
- End If
- Else
- ' Not Enough Credits to start a game.
- DOF 114, DOFOff
- DMDFlush
- DMD "black.jpg", "CREDITS " &credits, "INSERT COIN", 500
- ShowTableInfo
- End If
- End If
- End If
- End If ' If (GameInPlay)
- if keycode = "3" then StartNextMode
- if keycode = "4" then winmode mode(0)
- End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement