Outhere

Black & Red 1.0.1

Nov 12th, 2021 (edited)
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 52.13 KB | None | 0 0
  1. ' ***********************************************************************
  2. ' VISUAL PINBALL X EM Script by JPSalas
  3. ' Basic EM script up to 4 players
  4. ' uses core.vbs for extra functions
  5. ' Black & Reed / IPD No. 4413 / INDER 1975 / 1 Player
  6. ' ***********************************************************************
  7.  
  8. 'DOF Config by Outhere
  9. '101 Left Flipper
  10. '102 Right Flipper
  11. '103 Left Slingshot
  12. '104
  13. '105 Right Slingshot
  14. '106
  15. '107 Bumper Left
  16. '108
  17. '109 Bumper Right
  18. '110 Ball Release
  19. '111 BonusKicker
  20. '112 Knocker
  21. '116 Chimes
  22. '117 Chimes
  23. '118 Chimes
  24. '119 Chimes
  25.  
  26. Option Explicit
  27. Randomize
  28.  
  29. ' core.vbs constants
  30. Const BallSize = 50 ' 50 is the normal size
  31. Const BallMass = 1.7 ' 1 is the normal ball mass.
  32.  
  33. ' load extra vbs files
  34. LoadCoreFiles
  35.  
  36. Sub LoadCoreFiles
  37. On Error Resume Next
  38. ExecuteGlobal GetTextFile("core.vbs")
  39. If Err Then MsgBox "Can't open core.vbs"
  40. On Error Resume Next
  41. ExecuteGlobal GetTextFile("controller.vbs")
  42. If Err Then MsgBox "Can't open controller.vbs"
  43. End Sub
  44.  
  45. ' Valores Constants
  46. Const cGameName = "BlackRed" ' B2S name
  47. Const MaxPlayers = 1 ' 1 to 4 can play
  48. Const MaxMultiplier = 3 ' limit bonus multiplier
  49. Const BallsPerGame = 3 ' 3 or 5
  50. Const FreePlay = False ' Free play or coins
  51. Const Special1 = 79000 ' extra ball or credit
  52. Const Special2 = 91000
  53. 'Const Special3 = 92000
  54.  
  55. ' Global variables
  56. Dim PlayersPlayingGame
  57. Dim CurrentPlayer
  58. Dim Credits
  59. Dim Bonus
  60. Dim BallsRemaining(4)
  61. Dim BonusMultiplier
  62. Dim ExtraBallsAwards(4)
  63. Dim Special1Awarded(4)
  64. Dim Special2Awarded(4)
  65. 'Dim Special3Awarded(4)
  66. Dim Score(4)
  67. Dim HighScore
  68. Dim Match
  69. Dim Tilt
  70. Dim TiltSensitivity
  71. Dim Tilted
  72. Dim Add10
  73. Dim Add100
  74. Dim Add1000
  75. Dim Add10000
  76. Dim x
  77.  
  78. ' Control variables
  79. Dim BallsOnPlayfield
  80.  
  81. ' Boolean variables
  82. Dim bAttractMode
  83. Dim bFreePlay
  84. Dim bGameInPlay
  85. Dim bOnTheFirstBall
  86. Dim bExtraBallWonThisBall
  87. Dim bJustStarted
  88. Dim bBallInPlungerLane
  89. Dim bBallSaverActive
  90.  
  91. ' core.vbs variables
  92. Dim cbLeft
  93. Dim cbRight
  94.  
  95. ' *********************************************************************
  96. ' Common rutines to all the tables
  97. ' *********************************************************************
  98.  
  99. Sub Table1_Init()
  100. Dim x
  101.  
  102. ' Init som objects, like walls, targets
  103. VPObjects_Init
  104.  
  105. LoadEM
  106.  
  107. Set cbLeft = New cvpmCaptiveBall
  108. With cbLeft
  109. .InitCaptive CapTrigger1, CapWall1, CapKicker1, 0
  110. .ForceTrans = .9
  111. .MinForce = 3.5
  112. .CreateEvents "cbLeft"
  113. .Start
  114. End With
  115.  
  116. Set cbRight = New cvpmCaptiveBall
  117. With cbRight
  118. .InitCaptive CapTrigger2, CapWall2, CapKicker2, 0
  119. .ForceTrans = .9
  120. .MinForce = 3.5
  121. .CreateEvents "cbRight"
  122. .Start
  123. End With
  124.  
  125. ' load highscore
  126. Loadhs
  127. ScoreReel1.SetValue HSScore(1)
  128. If B2SOn then
  129. Controller.B2SSetScorePlayer 1, HSScore(1)
  130. End If
  131. UpdateCredits
  132.  
  133. ' init all the global variables
  134. bFreePlay = FreePlay
  135. bAttractMode = False
  136. bOnTheFirstBall = False
  137. bGameInPlay = False
  138. bBallInPlungerLane = False
  139. BallsOnPlayfield = 0
  140. Tilt = 0
  141. TiltSensitivity = 6
  142. Tilted = False
  143. Match = 0
  144. bJustStarted = True
  145. Add10 = 0
  146. Add100 = 0
  147. Add1000 = 0
  148.  
  149. ' setup table in game over mode
  150. EndOfGame
  151.  
  152. 'turn on GI lights
  153. vpmtimer.addtimer 1000, "GiOn '"
  154.  
  155. ' Remove desktop items in FS mode
  156. If Table1.ShowDT then
  157. For each x in aReels
  158. x.Visible = 1
  159. Next
  160. Else
  161. For each x in aReels
  162. x.Visible = 0
  163. Next
  164. End If
  165.  
  166. ' Start the RealTime timer
  167. RealTime.Enabled = 1
  168.  
  169. ' Load table color
  170. LoadLut
  171. End Sub
  172.  
  173. '******
  174. ' Keys
  175. '******
  176.  
  177. Sub Table1_KeyDown(ByVal Keycode)
  178.  
  179. If keycode = LeftMagnaSave Then bLutActive = True
  180. If keycode = RightMagnaSave Then
  181. If bLutActive Then NextLUT:End If
  182. End If
  183.  
  184. If EnteringInitials then
  185. CollectInitials(keycode)
  186. Exit Sub
  187. End If
  188.  
  189. ' add coins
  190. If Keycode = AddCreditKey Then
  191. If(Tilted = False)Then
  192. AddCredits 1
  193. PlaySound "fx_coin"
  194. End If
  195. End If
  196.  
  197. ' plunger
  198. If keycode = PlungerKey Then
  199. Plunger.Pullback
  200. PlaySoundAt "fx_plungerpull", plunger
  201. End If
  202.  
  203. ' tilt keys
  204. If keycode = LeftTiltKey Then Nudge 90, 8:PlaySound "fx_nudge", 0, 1, -0.1, 0.25:CheckTilt
  205. If keycode = RightTiltKey Then Nudge 270, 8:PlaySound "fx_nudge", 0, 1, 0.1, 0.25:CheckTilt
  206. If keycode = CenterTiltKey Then Nudge 0, 9:PlaySound "fx_nudge", 0, 1, 1, 0.25:CheckTilt
  207.  
  208. ' keys during game
  209.  
  210. If bGameInPlay AND NOT Tilted Then
  211. If keycode = LeftFlipperKey Then SolLFlipper 1
  212. If keycode = RightFlipperKey Then SolRFlipper 1
  213.  
  214. If keycode = StartGameKey Then
  215. If((PlayersPlayingGame <MaxPlayers)AND(bOnTheFirstBall = True))Then
  216.  
  217. If(bFreePlay = True)Then
  218. PlayersPlayingGame = PlayersPlayingGame + 1
  219. UpdatePlayersPlaying
  220. 'PlaySound "so_fanfare1"
  221. Else
  222. If(Credits> 0)then
  223. PlayersPlayingGame = PlayersPlayingGame + 1
  224. Credits = Credits - 1
  225. UpdateCredits
  226. UpdateBallInPlay
  227. UpdatePlayersPlaying
  228. Else
  229. ' Not Enough Credits to start a game.
  230. 'PlaySound "so_nocredits"
  231. End If
  232. End If
  233. End If
  234. End If
  235. Else
  236.  
  237. If keycode = StartGameKey Then
  238. If(bFreePlay = True)Then
  239. If(BallsOnPlayfield = 0)Then
  240. ResetScores
  241. ResetForNewGame()
  242. End If
  243. Else
  244. If(Credits> 0)Then
  245. If(BallsOnPlayfield = 0)Then
  246. Credits = Credits - 1
  247. UpdateCredits
  248. ResetScores
  249. ResetForNewGame()
  250. End If
  251. Else
  252. ' Not Enough Credits to start a game.
  253. 'PlaySound "so_nocredits"
  254. End If
  255. End If
  256. End If
  257. End If ' If (GameInPlay)
  258. End Sub
  259.  
  260. Sub Table1_KeyUp(ByVal keycode)
  261.  
  262. If keycode = LeftMagnaSave Then bLutActive = False
  263.  
  264. If EnteringInitials then
  265. Exit Sub
  266. End If
  267.  
  268. If bGameInPlay AND NOT Tilted Then
  269. ' teclas de los flipers
  270. If keycode = LeftFlipperKey Then SolLFlipper 0
  271. If keycode = RightFlipperKey Then SolRFlipper 0
  272. End If
  273.  
  274. If keycode = PlungerKey Then
  275. Plunger.Fire
  276. If bBallInPlungerLane Then
  277. PlaySoundAt "fx_plunger", plunger
  278. Else
  279. PlaySoundAt "fx_plunger_empty", plunger
  280. End If
  281. End If
  282. End Sub
  283.  
  284. '******************
  285. ' Table stop/pause
  286. '******************
  287.  
  288. Sub table1_Paused
  289. End Sub
  290.  
  291. Sub table1_unPaused
  292. End Sub
  293.  
  294. Sub table1_Exit
  295. Savehs
  296. 'Controller.Stop
  297. End Sub
  298.  
  299. '********************
  300. ' Flippers
  301. '********************
  302.  
  303. Sub SolLFlipper(Enabled)
  304. If Enabled Then
  305. PlaySoundAt SoundFXDOF("fx_flipperup", 101, DOFOn, DOFFlippers), LeftFlipper
  306. LeftFlipper.EOSTorque = 0.75:LeftFlipper.RotateToEnd
  307. Else
  308. PlaySoundAt SoundFXDOF("fx_flipperdown", 101, DOFOff, DOFFlippers), LeftFlipper
  309. LeftFlipper.EOSTorque = 0.3:LeftFlipper.RotateToStart
  310. End If
  311. End Sub
  312.  
  313. Sub SolRFlipper(Enabled)
  314. If Enabled Then
  315. PlaySoundAt SoundFXDOF("fx_flipperup", 102, DOFOn, DOFFlippers), RightFlipper
  316. RightFlipper.EOSTorque = 0.75:RightFlipper.RotateToEnd
  317. Else
  318. PlaySoundAt SoundFXDOF("fx_flipperdown", 102, DOFOff, DOFFlippers), RightFlipper
  319. RightFlipper.EOSTorque = 0.3:RightFlipper.RotateToStart
  320. End If
  321. End Sub
  322.  
  323. ' flippers hit Sound
  324.  
  325. Sub LeftFlipper_Collide(parm)
  326. PlaySound "fx_rubber_flipper", 0, parm / 60, pan(ActiveBall), 0, Pitch(ActiveBall), 0, 0, AudioFade(ActiveBall)
  327. End Sub
  328.  
  329. Sub RightFlipper_Collide(parm)
  330. PlaySound "fx_rubber_flipper", 0, parm / 60, pan(ActiveBall), 0, Pitch(ActiveBall), 0, 0, AudioFade(ActiveBall)
  331. End Sub
  332.  
  333. '***********
  334. ' GI lights
  335. '***********
  336.  
  337. Sub GiOn 'enciende las luces GI
  338. Dim bulb
  339. For each bulb in aGiLights
  340. bulb.State = 1
  341. Next
  342. End Sub
  343.  
  344. Sub GiOff 'apaga las luces GI
  345. Dim bulb
  346. For each bulb in aGiLights
  347. bulb.State = 0
  348. Next
  349. End Sub
  350.  
  351. '**************
  352. ' TILT
  353. '**************
  354.  
  355. Sub CheckTilt
  356. Tilt = Tilt + TiltSensitivity
  357. TiltDecreaseTimer.Enabled = True
  358. If Tilt> 15 Then
  359. Tilted = True
  360. TiltReel.SetValue 1
  361. If B2SOn then
  362. Controller.B2SSetTilt 1
  363. end if
  364. DisableTable True
  365. ' BallsRemaining(CurrentPlayer) = 0 'player looses the game
  366. TiltRecoveryTimer.Enabled = True 'wait for all the balls to drain
  367. End If
  368. End Sub
  369.  
  370. Sub TiltDecreaseTimer_Timer
  371. If Tilt> 0 Then
  372. Tilt = Tilt - 0.1
  373. Else
  374. TiltDecreaseTimer.Enabled = False
  375. End If
  376. End Sub
  377.  
  378. Sub DisableTable(Enabled)
  379. If Enabled Then
  380. GiOff
  381. LeftFlipper.RotateToStart
  382. RightFlipper.RotateToStart
  383. Bumper001.Force = 0
  384. Bumper002.Force = 0
  385. LeftSlingshot.Disabled = 1
  386. RightSlingshot.Disabled = 1
  387. Else
  388. GiOn
  389. Bumper001.Force = 10
  390. Bumper002.Force = 10
  391. LeftSlingshot.Disabled = 0
  392. RightSlingshot.Disabled = 0
  393. End If
  394. End Sub
  395.  
  396. Sub TiltRecoveryTimer_Timer()
  397. ' all the balls have drained
  398. If(BallsOnPlayfield = 0)Then
  399. EndOfBall()
  400. TiltRecoveryTimer.Enabled = False
  401. End If
  402. ' otherwise repeat
  403. End Sub
  404.  
  405. '***************************************************************
  406. ' Supporting Ball & Sound Functions v3.0
  407. ' includes random pitch in PlaySoundAt and PlaySoundAtBall
  408. '***************************************************************
  409.  
  410. Dim TableWidth, TableHeight
  411.  
  412. TableWidth = Table1.width
  413. TableHeight = Table1.height
  414.  
  415. Function Vol(ball) ' Calculates the Volume of the sound based on the ball speed
  416. Vol = Csng(BallVel(ball) ^2 / 2000)
  417. End Function
  418.  
  419. Function Pan(ball) ' Calculates the pan for a ball based on the X position on the table. "table1" is the name of the table
  420. Dim tmp
  421. tmp = ball.x * 2 / TableWidth-1
  422. If tmp> 0 Then
  423. Pan = Csng(tmp ^10)
  424. Else
  425. Pan = Csng(-((- tmp) ^10))
  426. End If
  427. End Function
  428.  
  429. Function Pitch(ball) ' Calculates the pitch of the sound based on the ball speed
  430. Pitch = BallVel(ball) * 20
  431. End Function
  432.  
  433. Function BallVel(ball) 'Calculates the ball speed
  434. BallVel = (SQR((ball.VelX ^2) + (ball.VelY ^2)))
  435. End Function
  436.  
  437. Function AudioFade(ball) 'only on VPX 10.4 and newer
  438. Dim tmp
  439. tmp = ball.y * 2 / TableHeight-1
  440. If tmp> 0 Then
  441. AudioFade = Csng(tmp ^10)
  442. Else
  443. AudioFade = Csng(-((- tmp) ^10))
  444. End If
  445. End Function
  446.  
  447. Sub PlaySoundAt(soundname, tableobj) 'play sound at X and Y position of an object, mostly bumpers, flippers and other fast objects
  448. PlaySound soundname, 0, 1, Pan(tableobj), 0.1, 0, 0, 0, AudioFade(tableobj)
  449. End Sub
  450.  
  451. Sub PlaySoundAtBall(soundname) ' play a sound at the ball position, like rubbers, targets, metals, plastics
  452. PlaySound soundname, 0, Vol(ActiveBall), pan(ActiveBall), 0.4, 0, 0, 0, AudioFade(ActiveBall)
  453. End Sub
  454.  
  455. '***********************************************
  456. ' JP's VP10 Rolling Sounds + Ballshadow v3.0
  457. ' uses a collection of shadows, aBallShadow
  458. '***********************************************
  459.  
  460. Const tnob = 19 'total number of balls, 20 balls, from 0 to 19
  461. Const lob = 0 'number of locked balls
  462. Const maxvel = 26 'max ball velocity
  463. ReDim rolling(tnob)
  464. InitRolling
  465.  
  466. Sub InitRolling
  467. Dim i
  468. For i = 0 to tnob
  469. rolling(i) = False
  470. Next
  471. End Sub
  472.  
  473. Sub RollingUpdate()
  474. Dim BOT, b, ballpitch, ballvol, speedfactorx, speedfactory
  475. BOT = GetBalls
  476.  
  477. ' stop the sound of deleted balls and hide the shadow
  478. For b = UBound(BOT) + 1 to tnob
  479. rolling(b) = False
  480. StopSound("fx_ballrolling" & b)
  481. aBallShadow(b).Y = 3000
  482. Next
  483.  
  484. ' exit the sub if no balls on the table
  485. If UBound(BOT) = lob - 1 Then Exit Sub 'there no extra balls on this table
  486.  
  487. ' play the rolling sound for each ball and draw the shadow
  488. For b = lob to UBound(BOT)
  489. aBallShadow(b).X = BOT(b).X
  490. aBallShadow(b).Y = BOT(b).Y
  491.  
  492. If BallVel(BOT(b))> 1 Then
  493. If BOT(b).z <30 Then
  494. ballpitch = Pitch(BOT(b))
  495. ballvol = Vol(BOT(b))
  496. Else
  497. ballpitch = Pitch(BOT(b)) + 25000 'increase the pitch on a ramp
  498. ballvol = Vol(BOT(b)) * 10
  499. End If
  500. rolling(b) = True
  501. PlaySound("fx_ballrolling" & b), -1, ballvol, Pan(BOT(b)), 0, ballpitch, 1, 0, AudioFade(BOT(b))
  502. Else
  503. If rolling(b) = True Then
  504. StopSound("fx_ballrolling" & b)
  505. rolling(b) = False
  506. End If
  507. End If
  508.  
  509. ' rothbauerw's Dropping Sounds
  510. If BOT(b).VelZ <-1 and BOT(b).z <55 and BOT(b).z> 27 Then 'height adjust for ball drop sounds
  511. PlaySound "fx_balldrop", 0, ABS(BOT(b).velz) / 17, Pan(BOT(b)), 0, Pitch(BOT(b)), 1, 0, AudioFade(BOT(b))
  512. End If
  513.  
  514. ' jps ball speed control
  515. If BOT(b).VelX AND BOT(b).VelY <> 0 Then
  516. speedfactorx = ABS(maxvel / BOT(b).VelX)
  517. speedfactory = ABS(maxvel / BOT(b).VelY)
  518. If speedfactorx <1 Then
  519. BOT(b).VelX = BOT(b).VelX * speedfactorx
  520. BOT(b).VelY = BOT(b).VelY * speedfactorx
  521. End If
  522. If speedfactory <1 Then
  523. BOT(b).VelX = BOT(b).VelX * speedfactory
  524. BOT(b).VelY = BOT(b).VelY * speedfactory
  525. End If
  526. End If
  527. Next
  528. End Sub
  529.  
  530. '**********************
  531. ' Ball Collision Sound
  532. '**********************
  533.  
  534. Sub OnBallBallCollision(ball1, ball2, velocity)
  535. PlaySound "fx_collide", 0, Csng(velocity) ^2 / 2000, Pan(ball1), 0, Pitch(ball1), 0, 0, AudioFade(ball1)
  536. End Sub
  537.  
  538. '************************************
  539. ' Diverse Collection Hit Sounds v3.0
  540. '************************************
  541.  
  542. Sub aMetals_Hit(idx):PlaySoundAtBall "fx_MetalHit":End Sub
  543. Sub aMetalWires_Hit(idx):PlaySoundAtBall "fx_MetalWire":End Sub
  544. Sub aRubber_Bands_Hit(idx):PlaySoundAtBall "fx_rubber_band":End Sub
  545. Sub aRubber_LongBands_Hit(idx):PlaySoundAtBall "fx_rubber_longband":End Sub
  546. Sub aRubber_Posts_Hit(idx):PlaySoundAtBall "fx_rubber_post":End Sub
  547. Sub aRubber_Pins_Hit(idx):PlaySoundAtBall "fx_rubber_pin":End Sub
  548. Sub aRubber_Pegs_Hit(idx):PlaySoundAtBall "fx_rubber_peg":End Sub
  549. Sub aPlastics_Hit(idx):PlaySoundAtBall "fx_PlasticHit":End Sub
  550. Sub aGates_Hit(idx):PlaySoundAtBall "fx_Gate":End Sub
  551. Sub aWoods_Hit(idx):PlaySoundAtBall "fx_Woodhit":End Sub
  552. Sub aTargets_Hit(idx):ActiveBall.VelZ = BallVel(Activeball) * (RND / 2):End Sub
  553.  
  554. '************************************************************************************************************************
  555. ' Only for VPX 10.2 and higher.
  556. ' FlashForMs will blink light or a flasher for TotalPeriod(ms) at rate of BlinkPeriod(ms)
  557. ' When TotalPeriod done, light or flasher will be set to FinalState value where
  558. ' Final State values are: 0=Off, 1=On, 2=Return to previous State
  559. '************************************************************************************************************************
  560.  
  561. Sub FlashForMs(MyLight, TotalPeriod, BlinkPeriod, FinalState)
  562.  
  563. If TypeName(MyLight) = "Light" Then
  564. If FinalState = 2 Then
  565. FinalState = MyLight.State
  566. End If
  567. MyLight.BlinkInterval = BlinkPeriod
  568. MyLight.Duration 2, TotalPeriod, FinalState
  569. ElseIf TypeName(MyLight) = "Flasher" Then
  570. Dim steps
  571. steps = Int(TotalPeriod / BlinkPeriod + .5)
  572. If FinalState = 2 Then
  573. FinalState = ABS(MyLight.Visible)
  574. End If
  575. MyLight.UserValue = steps * 10 + FinalState
  576. MyLight.TimerInterval = BlinkPeriod
  577. MyLight.TimerEnabled = 0
  578. MyLight.TimerEnabled = 1
  579. ExecuteGlobal "Sub " & MyLight.Name & "_Timer:" & "Dim tmp, steps, fstate:tmp=me.UserValue:fstate = tmp MOD 10:steps= tmp\10 -1:Me.Visible = steps MOD 2:me.UserValue = steps *10 + fstate:If Steps = 0 then Me.Visible = fstate:Me.TimerEnabled=0:End if:End Sub"
  580. End If
  581. End Sub
  582.  
  583. '****************************************
  584. ' Init table for a new game
  585. '****************************************
  586.  
  587. Sub ResetForNewGame()
  588. 'debug.print "ResetForNewGame"
  589. Dim i
  590.  
  591. bGameInPLay = True
  592. bBallSaverActive = False
  593.  
  594. StopAttractMode
  595. If B2SOn then
  596. Controller.B2SSetGameOver 0
  597. end if
  598.  
  599. GiOn
  600.  
  601. CurrentPlayer = 1
  602. PlayersPlayingGame = 1
  603. UpdatePlayersPlaying
  604. bOnTheFirstBall = True
  605. For i = 1 To MaxPlayers
  606. Score(i) = 0
  607. ExtraBallsAwards(i) = 0
  608. Special1Awarded(i) = False
  609. Special2Awarded(i) = False
  610. 'Special3Awarded(i) = False
  611. BallsRemaining(i) = BallsPerGame
  612. Next
  613. BonusMultiplier = 1
  614. Bonus = 0
  615. UpdateBallInPlay
  616.  
  617. Clear_Match
  618.  
  619. ' init other variables
  620. Tilt = 0
  621.  
  622. ' init game variables
  623. Game_Init()
  624.  
  625. ' start a music?
  626. ' first ball
  627. vpmtimer.addtimer 2000, "FirstBall '"
  628. End Sub
  629.  
  630. Sub FirstBall
  631. 'debug.print "FirstBall"
  632. ' reset table for a new ball, rise droptargets ++
  633. ResetForNewPlayerBall()
  634. CreateNewBall()
  635. End Sub
  636.  
  637. ' (Re-)init table for a new ball or player
  638.  
  639. Sub ResetForNewPlayerBall()
  640. 'debug.print "ResetForNewPlayerBall"
  641. AddScore 0
  642.  
  643. ' reset multiplier to 1x
  644.  
  645. ' turn on lights, and variables
  646. bExtraBallWonThisBall = False
  647. ResetNewBallLights
  648. ResetNewBallVariables
  649. End Sub
  650.  
  651. ' Crete new ball
  652.  
  653. Sub CreateNewBall()
  654. BallRelease.CreateSizedBallWithMass BallSize / 2, BallMass
  655. BallsOnPlayfield = BallsOnPlayfield + 1
  656. UpdateBallInPlay
  657. UpdateCurrentPlayer
  658. PlaySoundAt SoundFXDOF("fx_Ballrel", 110, DOFPulse, DOFContactors), BallRelease
  659. BallRelease.Kick 90, 4
  660. End Sub
  661.  
  662. ' player lost the ball
  663.  
  664. Sub EndOfBall()
  665. 'debug.print "EndOfBall"
  666. ' Lost the first ball, now it cannot accept more players
  667. bOnTheFirstBall = False
  668.  
  669. 'No bonus count in this table
  670. ' StartBonusCount
  671.  
  672. vpmtimer.addtimer 400, "EndOfBall2 '"
  673. End Sub
  674.  
  675. ' After bonus count go to the next step
  676. '
  677. Sub EndOfBall2()
  678. 'debug.print "EndOfBall2"
  679.  
  680. Tilted = False
  681. Tilt = 0
  682. TiltReel.SetValue 0
  683. If B2SOn then
  684. Controller.B2SSetTilt 0
  685. end if
  686. DisableTable False
  687.  
  688. ' win extra ball?
  689. If(ExtraBallsAwards(CurrentPlayer)> 0)Then
  690. 'debug.print "Extra Ball"
  691.  
  692. ' if so then give it
  693. ExtraBallsAwards(CurrentPlayer) = ExtraBallsAwards(CurrentPlayer)- 1
  694.  
  695. ' turn off light if no more extra balls
  696. If(ExtraBallsAwards(CurrentPlayer) = 0)Then
  697. XtraBall.SetValue 0
  698. If B2SOn then
  699. Controller.B2SSetShootAgain 0
  700. End If
  701. End If
  702.  
  703. ' extra ball sound?
  704.  
  705. ' reset as in a new ball
  706. ResetForNewPlayerBall()
  707. CreateNewBall()
  708. Else ' no extra ball
  709.  
  710. BallsRemaining(CurrentPlayer) = BallsRemaining(CurrentPlayer)- 1
  711.  
  712. ' last ball?
  713. If(BallsRemaining(CurrentPlayer) <= 0)Then
  714. StartBonusCount
  715. 'CheckHighScore()
  716. Else
  717.  
  718. ' this is not the last ball, chack for new player
  719. EndOfBallComplete()
  720. End If
  721. End If
  722. End Sub
  723.  
  724. Sub EndOfBallComplete()
  725. 'debug.print "EndOfBallComplete"
  726. Dim NextPlayer
  727.  
  728. ' other players?
  729. If(PlayersPlayingGame> 1)Then
  730. NextPlayer = CurrentPlayer + 1
  731. ' if it is the last player then go to the first one
  732. If(NextPlayer> PlayersPlayingGame)Then
  733. NextPlayer = 1
  734. End If
  735. Else
  736. NextPlayer = CurrentPlayer
  737. End If
  738.  
  739. 'debug.print "Next Player = " & NextPlayer
  740.  
  741. ' end of game?
  742. If((BallsRemaining(CurrentPlayer) <= 0)AND(BallsRemaining(NextPlayer) <= 0))Then
  743.  
  744. ' match if playing with coins
  745. If bFreePlay = False Then
  746. Verification_Match
  747. End If
  748.  
  749. ' end of game
  750. EndOfGame()
  751. Else
  752. ' next player
  753. CurrentPlayer = NextPlayer
  754.  
  755. ' update score
  756. AddScore 0
  757.  
  758. ' reset table for new player
  759. ResetForNewPlayerBall()
  760. CreateNewBall()
  761. End If
  762. End Sub
  763.  
  764. ' Called at the end of the game
  765.  
  766. Sub EndOfGame()
  767. 'debug.print "EndOfGame"
  768. bGameInPLay = False
  769. bJustStarted = False
  770. GameOverR.SetValue 1
  771. If B2SOn then
  772. Controller.B2SSetGameOver 1
  773. Controller.B2SSetBallInPlay 0
  774. Controller.B2SSetPlayerUp 0
  775. Controller.B2SSetCanPlay 0
  776. end if
  777. ' turn off flippers
  778. SolLFlipper 0
  779. SolRFlipper 0
  780.  
  781. ' start the attract mode
  782. StartAttractMode
  783. End Sub
  784.  
  785. ' Fuction to calculate the balls left
  786. Function Balls
  787. Dim tmp
  788. tmp = BallsPerGame - BallsRemaining(CurrentPlayer) + 1
  789. If tmp> BallsPerGame Then
  790. Balls = BallsPerGame
  791. Else
  792. Balls = tmp
  793. End If
  794. End Function
  795.  
  796. '******************
  797. ' Match
  798. '******************
  799.  
  800. Sub Verification_Match()
  801. PlaySound "fx_match"
  802. Match = INT(RND(1) * 10) * 10 ' random between 0 and 90
  803. Display_Match
  804. If(Score(CurrentPlayer)MOD 100) = Match Then
  805. PlaySound SoundFXDOF("fx_knocker", 112, DOFPulse, DOFknocker)
  806. AddCredits 1
  807. End If
  808. End Sub
  809.  
  810. Sub Clear_Match()
  811. MatchReel.SetValue 0
  812. If B2SOn then
  813. Controller.B2SSetMatch 0
  814. end if
  815. End Sub
  816.  
  817. Sub Display_Match()
  818. MatchReel.SetValue(Match \ 10) + 1
  819. If B2SOn then
  820. If Match = 0 then
  821. Controller.B2SSetMatch 100
  822. else
  823. Controller.B2SSetMatch Match
  824. end if
  825. end if
  826. End Sub
  827.  
  828. ' *********************************************************************
  829. ' Drain / Plunger Functions
  830. ' *********************************************************************
  831.  
  832. Sub Drain_Hit()
  833. Drain.DestroyBall
  834. BallsOnPlayfield = BallsOnPlayfield - 1
  835. PlaySoundAt "fx_drain", Drain
  836.  
  837. 'tilted?
  838. If Tilted Then
  839. StopEndOfBallMode
  840. End If
  841.  
  842. ' if still playing and not tilted
  843. If(bGameInPLay = True)AND(Tilted = False)Then
  844.  
  845. ' ballsaver?
  846. If(bBallSaverActive = True)Then
  847. CreateNewBall()
  848. Else
  849. ' last ball?
  850. If(BallsOnPlayfield = 0)Then
  851. StopEndOfBallMode
  852. vpmtimer.addtimer 500, "EndOfBall '"
  853. Exit Sub
  854. End If
  855. End If
  856. End If
  857. End Sub
  858.  
  859. Sub swPlungerRest_Hit()
  860. bBallInPlungerLane = True
  861. End Sub
  862.  
  863. Sub swPlungerRest_UnHit()
  864. bBallInPlungerLane = False
  865. End Sub
  866.  
  867. ' ****************************************
  868. ' Score functions
  869. ' ****************************************
  870.  
  871. Sub AddScore(Points)
  872. If Tilted Then Exit Sub
  873. Select Case Points
  874. Case 10, 100, 1000, 10000
  875. Score(CurrentPlayer) = Score(CurrentPlayer) + points
  876. UpdateScore points
  877. ' sounds
  878. If Points = 1000 AND(Score(CurrentPlayer)MOD 10000) \ 1000 = 0 Then 'new reel 10000
  879. PlaySound SoundFXDOF("bell1000", 119, DOFPulse, DOFBell)
  880. ElseIf Points = 100 AND(Score(CurrentPlayer)MOD 1000) \ 100 = 0 Then 'new reel 1000
  881. PlaySound SoundFXDOF("bell1000", 118, DOFPulse, DOFChimes)
  882. ElseIf Points = 10 AND(Score(CurrentPlayer)MOD 100) \ 10 = 0 Then 'new reel 100
  883. PlaySound SoundFXDOF("bell100", 117, DOFPulse, DOFChimes)
  884. Else
  885. PlaySound SoundFXDOF("bell", 116, DOFPulse, DOFChimes) &Points
  886. End If
  887. Case 20, 30, 40, 50, 60, 70, 80, 90
  888. Add10 = Add10 + + Points \ 10
  889. AddScore10Timer.Enabled = TRUE
  890. Case 200, 300, 400, 500, 600, 700, 800, 900
  891. Add100 = Add100 + + Points \ 100
  892. AddScore100Timer.Enabled = TRUE
  893. Case 2000, 3000, 4000, 5000, 6000, 7000, 8000, 9000
  894. Add1000 = Add1000 + Points \ 1000
  895. AddScore1000Timer.Enabled = TRUE
  896. Case 20000, 30000, 40000, 50000, 60000, 70000, 80000, 90000
  897. Add10000 = Add10000 + Points \ 10000
  898. AddScore10000Timer.Enabled = TRUE
  899. End Select
  900.  
  901. ' check for higher score and specials
  902. If Score(CurrentPlayer) >= Special1 AND Special1Awarded(CurrentPlayer) = False Then
  903. AwardSpecial
  904. Special1Awarded(CurrentPlayer) = True
  905. End If
  906. If Score(CurrentPlayer) >= Special2 AND Special2Awarded(CurrentPlayer) = False Then
  907. AwardSpecial
  908. Special2Awarded(CurrentPlayer) = True
  909. End If
  910. ' If Score(CurrentPlayer) >= Special3 AND Special3Awarded(CurrentPlayer) = False Then
  911. ' AwardSpecial
  912. ' Special3Awarded(CurrentPlayer) = True
  913. ' End If
  914. End Sub
  915.  
  916. '************************************
  917. ' Score sound Timers
  918. '************************************
  919.  
  920. Sub AddScore10Timer_Timer()
  921. if Add10> 0 then
  922. AddScore 10
  923. Add10 = Add10 - 1
  924. Else
  925. Me.Enabled = FALSE
  926. End If
  927. End Sub
  928.  
  929. Sub AddScore100Timer_Timer()
  930. if Add100> 0 then
  931. AddScore 100
  932. Add100 = Add100 - 1
  933. Else
  934. Me.Enabled = FALSE
  935. End If
  936. End Sub
  937.  
  938. Sub AddScore1000Timer_Timer()
  939. if Add1000> 0 then
  940. AddScore 1000
  941. Add1000 = Add1000 - 1
  942. Else
  943. Me.Enabled = FALSE
  944. End If
  945. End Sub
  946.  
  947. Sub AddScore10000Timer_Timer()
  948. if Add10000> 0 then
  949. AddScore 10000
  950. Add10000 = Add10000 - 1
  951. Else
  952. Me.Enabled = FALSE
  953. End If
  954. End Sub
  955.  
  956. '*******************
  957. ' BONUS
  958. '*******************
  959.  
  960. Sub AddBonus(bonuspoints)
  961. If(Tilted = False)Then
  962. Bonus = Bonus + bonuspoints
  963. 'PlaySound "Bell2"
  964. If Bonus> 10 Then
  965. Bonus = 10
  966. End If
  967. UpdateBonusLights
  968. End if
  969. End Sub
  970.  
  971. Sub AddBonusMultiplier(multi)
  972. If(Tilted = False)Then
  973. BonusMultiplier = BonusMultiplier + multi
  974. If BonusMultiplier> MaxMultiplier Then
  975. BonusMultiplier = MaxMultiplier
  976. End If
  977. UpdateMultiplierLights
  978. End if
  979. End Sub
  980.  
  981. Sub UpdateMultiplierLights
  982. Select Case BonusMultiplier
  983. Case 1:bl002.State = 1:bl001.State = 0:bl003.State = 0
  984. Case 2:bl002.State = 0:bl001.State = 1:bl003.State = 0
  985. Case 3:bl002.State = 0:bl001.State = 0:bl003.State = 1
  986. End Select
  987. End Sub
  988.  
  989. Sub StartBonusCount
  990. Select Case BonusMultiplier
  991. Case 1:BonusCountTimer.Interval = 250
  992. Case 2:BonusCountTimer.Interval = 500
  993. Case 3:BonusCountTimer.Interval = 750
  994. End Select
  995. BonusCountTimer.Enabled = 1
  996. End Sub
  997.  
  998. Sub BonusCountTimer_Timer
  999. 'debug.print "BonusCount_Timer"
  1000. If Bonus> 0 Then
  1001. Bonus = Bonus -1
  1002. AddScore 1000 * BonusMultiplier
  1003. UpdateBonusLights
  1004. Else
  1005. BonusCountTimer.Enabled = 0
  1006. 'set bonus to 1
  1007. Addbonus 1
  1008. If BallinBonusKicker Then
  1009. vpmtimer.addtimer 1000, "BonusKickOut '"
  1010. End If
  1011. ' last ball?
  1012. If(BallsRemaining(CurrentPlayer) <= 0)Then
  1013. CheckHighScore()
  1014. EndOfBallComplete()
  1015. End If
  1016. End If
  1017. End Sub
  1018.  
  1019. Sub UpdateBonusLights
  1020. Select Case Bonus
  1021. Case 0:bl1.State = 0:bl2.State = 0:bl3.State = 0:bl4.State = 0:bl5.State = 0:bl6.State = 0:bl7.State = 0:bl8.State = 0:bl9.State = 0:bl10.State = 0
  1022. Case 1:bl1.State = 1:bl2.State = 0:bl3.State = 0:bl4.State = 0:bl5.State = 0:bl6.State = 0:bl7.State = 0:bl8.State = 0:bl9.State = 0:bl10.State = 0
  1023. Case 2:bl1.State = 0:bl2.State = 1:bl3.State = 0:bl4.State = 0:bl5.State = 0:bl6.State = 0:bl7.State = 0:bl8.State = 0:bl9.State = 0:bl10.State = 0
  1024. Case 3:bl1.State = 0:bl2.State = 0:bl3.State = 1:bl4.State = 0:bl5.State = 0:bl6.State = 0:bl7.State = 0:bl8.State = 0:bl9.State = 0:bl10.State = 0
  1025. Case 4:bl1.State = 0:bl2.State = 0:bl3.State = 0:bl4.State = 1:bl5.State = 0:bl6.State = 0:bl7.State = 0:bl8.State = 0:bl9.State = 0:bl10.State = 0
  1026. Case 5:bl1.State = 0:bl2.State = 0:bl3.State = 0:bl4.State = 0:bl5.State = 1:bl6.State = 0:bl7.State = 0:bl8.State = 0:bl9.State = 0:bl10.State = 0
  1027. Case 6:bl1.State = 0:bl2.State = 0:bl3.State = 0:bl4.State = 0:bl5.State = 0:bl6.State = 1:bl7.State = 0:bl8.State = 0:bl9.State = 0:bl10.State = 0
  1028. Case 7:bl1.State = 0:bl2.State = 0:bl3.State = 0:bl4.State = 0:bl5.State = 0:bl6.State = 0:bl7.State = 1:bl8.State = 0:bl9.State = 0:bl10.State = 0
  1029. Case 8:bl1.State = 0:bl2.State = 0:bl3.State = 0:bl4.State = 0:bl5.State = 0:bl6.State = 0:bl7.State = 0:bl8.State = 1:bl9.State = 0:bl10.State = 0
  1030. Case 9:bl1.State = 0:bl2.State = 0:bl3.State = 0:bl4.State = 0:bl5.State = 0:bl6.State = 0:bl7.State = 0:bl8.State = 0:bl9.State = 1:bl10.State = 0
  1031. Case 10:bl1.State = 0:bl2.State = 0:bl3.State = 0:bl4.State = 0:bl5.State = 0:bl6.State = 0:bl7.State = 0:bl8.State = 0:bl9.State = 0:bl10.State = 1
  1032. End Select
  1033. End Sub
  1034.  
  1035. '**********************************
  1036. ' Score EM reels
  1037. '**********************************
  1038.  
  1039. Sub UpdateScore(playerpoints)
  1040. Select Case CurrentPlayer
  1041. Case 1:ScoreReel1.Addvalue playerpoints
  1042. 'Case 2:ScoreReel2.Addvalue playerpoints
  1043. 'Case 3:ScoreReel3.Addvalue playerpoints
  1044. 'Case 4:ScoreReel4.Addvalue playerpoints
  1045.  
  1046. End Select
  1047. If B2SOn then
  1048. Controller.B2SSetScorePlayer CurrentPlayer, Score(CurrentPlayer)
  1049. end if
  1050. End Sub
  1051.  
  1052. Sub ResetScores
  1053. ScoreReel1.ResetToZero
  1054. 'ScoreReel2.ResetToZero
  1055. 'ScoreReel3.ResetToZero
  1056. 'ScoreReel4.ResetToZero
  1057. If B2SOn then
  1058. Controller.B2SSetScorePlayer1 0
  1059. Controller.B2SSetScoreRolloverPlayer1 0
  1060. Controller.B2SSetScorePlayer2 0
  1061. Controller.B2SSetScoreRolloverPlayer2 0
  1062. Controller.B2SSetScorePlayer3 0
  1063. Controller.B2SSetScoreRolloverPlayer3 0
  1064. Controller.B2SSetScorePlayer4 0
  1065. Controller.B2SSetScoreRolloverPlayer4 0
  1066. end if
  1067. End Sub
  1068.  
  1069. Sub AddCredits(value) 'limit to 15 credits
  1070. If Credits <15 Then
  1071. Credits = Credits + value
  1072. CreditsReel.SetValue Credits
  1073. UpdateCredits
  1074. end if
  1075. End Sub
  1076.  
  1077. Sub UpdateCredits
  1078. PlaySound "fx_relay"
  1079. CreditsReel.SetValue credits
  1080. If B2SOn then
  1081. Controller.B2SSetCredits Credits
  1082. end if
  1083. End Sub
  1084.  
  1085. Sub UpdateBallInPlay
  1086. Select Case Balls
  1087. Case 0:BallDisplay.ImageA = "Ballnr0"
  1088. Case 1:BallDisplay.ImageA = "Ballnr1"
  1089. Case 2:BallDisplay.ImageA = "Ballnr2"
  1090. Case 3:BallDisplay.ImageA = "Ballnr3"
  1091. Case 4:BallDisplay.ImageA = "Ballnr4"
  1092. Case 5:BallDisplay.ImageA = "Ballnr5"
  1093. End Select
  1094. If B2SOn then
  1095. Controller.B2SSetBallInPlay Balls
  1096. end if
  1097. End Sub
  1098.  
  1099. Sub UpdatePlayersPlaying
  1100. ' Select Case PlayersPlayingGame
  1101. ' Case 0:cp1.State = 0:cp2.State = 0:cp3.State = 0:cp4.State = 0
  1102. ' Case 1:cp1.State = 1:cp2.State = 0:cp3.State = 0:cp4.State = 0
  1103. ' Case 2:cp1.State = 1:cp2.State = 1:cp3.State = 0:cp4.State = 0
  1104. ' Case 3:cp1.State = 1:cp2.State = 1:cp3.State = 1:cp4.State = 0
  1105. ' Case 4:cp1.State = 1:cp2.State = 1:cp3.State = 1:cp4.State = 1
  1106. ' End Select
  1107. ' If B2SOn then
  1108. ' Controller.B2SSetPlayersPlaying PlayersPlayingGame
  1109. ' end if
  1110. End Sub
  1111.  
  1112. Sub UpdateCurrentPlayer
  1113. ' Select Case CurrentPlayer
  1114. ' Case 0:pl1.State = 0:pl2.State = 0:pl3.State = 0:pl4.State = 0
  1115. ' Case 1:pl1.State = 1:pl2.State = 0:pl3.State = 0:pl4.State = 0
  1116. ' Case 2:pl1.State = 0:pl2.State = 1:pl3.State = 0:pl4.State = 0
  1117. ' Case 3:pl1.State = 0:pl2.State = 0:pl3.State = 1:pl4.State = 0
  1118. ' Case 4:pl1.State = 0:pl2.State = 0:pl3.State = 0:pl4.State = 1
  1119. ' End Select
  1120. ' If B2SOn then
  1121. ' Controller.B2SSetCurrentPlayer CurrentPlayer
  1122. ' end if
  1123. End Sub
  1124.  
  1125. '*************************
  1126. ' Specials
  1127. '*************************
  1128.  
  1129. Sub AwardExtraBall()
  1130. If NOT bExtraBallWonThisBall Then
  1131. PlaySound SoundFXDOF("fx_knocker", 112, DOFPulse, DOFknocker)
  1132. ExtraBallsAwards(CurrentPlayer) = ExtraBallsAwards(CurrentPlayer) + 1
  1133. bExtraBallWonThisBall = True
  1134. XtraBall.SetValue 1
  1135. Else
  1136. Addscore 5000
  1137. END If
  1138. End Sub
  1139.  
  1140. Sub AwardSpecial()
  1141. PlaySound SoundFXDOF("fx_knocker", 112, DOFPulse, DOFknocker)
  1142. AddCredits 1
  1143. End Sub
  1144.  
  1145. Sub AwardAddaBall()
  1146. If BallsRemaining(CurrentPlayer) <11 Then
  1147. PlaySound SoundFXDOF("fx_knocker", 112, DOFPulse, DOFknocker)
  1148. BallsRemaining(CurrentPlayer) = BallsRemaining(CurrentPlayer) + 1
  1149. UpdateBallInPlay
  1150. End If
  1151. End Sub
  1152.  
  1153. ' ********************************
  1154. ' Attract Mode
  1155. ' ********************************
  1156. ' use the"Blink Pattern" of each light
  1157.  
  1158. Sub StartAttractMode()
  1159. Dim x
  1160. bAttractMode = True
  1161. For each x in aLights
  1162. x.State = 2
  1163. Next
  1164. For each x in aBonusLights
  1165. x.State = 2
  1166. Next
  1167. GameOverR.SetValue 1
  1168. 'update current player and balls
  1169. 'start the highscore timer
  1170. HighScoreTimer.Enabled = 1
  1171. End Sub
  1172.  
  1173. Sub StopAttractMode()
  1174. Dim x
  1175. bAttractMode = False
  1176. TurnOffPlayfieldLights
  1177. For each x in aBonusLights
  1178. x.State = 0
  1179. Next
  1180. ResetScores
  1181. GameOverR.SetValue 0
  1182. End Sub
  1183.  
  1184. '*************************************
  1185. ' Highscore Routines
  1186. ' Based og Black's and GNMOD's code
  1187. '*************************************
  1188.  
  1189. Dim EnteringInitials
  1190. EnteringInitials = False
  1191.  
  1192. Dim SelectedChar ' character under the "cursor" when entering initials
  1193. Dim HSTimerCount:HSTimerCount = 0
  1194. Dim InitialString ' the string holding the player's initials as they're entered
  1195. Dim AlphaString:AlphaString = "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_<"
  1196. Dim AlphaStringPos ' pointer to AlphaString, move Forward and backward with flipper keys
  1197. Dim HSNewHigh ' The new score to be recorded
  1198. Dim HSScore(5) ' High Scores read in from config file
  1199. Dim HSName(5) ' High Score Initials read in from config file
  1200.  
  1201. ' default high scores
  1202. HSScore(1) = 51250
  1203. HSScore(2) = 43000
  1204. HSScore(3) = 35000
  1205. HSScore(4) = 28500
  1206. HSScore(5) = 16000
  1207.  
  1208. HSName(1) = "AAA"
  1209. HSName(2) = "BBB"
  1210. HSName(3) = "CCC"
  1211. HSName(4) = "DDD"
  1212. HSName(5) = "EEE"
  1213.  
  1214. ' Load Highscores
  1215.  
  1216. Sub Loadhs
  1217. Dim FileObj
  1218. Dim ScoreFile, TextStr
  1219. Dim check0, x
  1220.  
  1221. Set FileObj = CreateObject("Scripting.FileSystemObject")
  1222. If Not FileObj.FolderExists(UserDirectory)then
  1223. Credits = 0
  1224. Exit Sub
  1225. End If
  1226. If Not FileObj.FileExists(UserDirectory & cGameName& ".txt")then
  1227. Credits = 0
  1228. Exit Sub
  1229. End If
  1230. Set ScoreFile = FileObj.GetFile(UserDirectory & cGameName& ".txt")
  1231. Set TextStr = ScoreFile.OpenAsTextStream(1, 0)
  1232. If(TextStr.AtEndOfStream = True)then
  1233. Exit Sub
  1234. End If
  1235. check0 = Int(textStr.readLine)
  1236. If check0 = 0 then
  1237. Credits = Int(textstr.readline)
  1238. For x = 1 to 5
  1239. HSScore(x) = Int(textstr.readline)
  1240. Next
  1241. For x = 1 to 5
  1242. HSName(x) = textstr.readline
  1243. Next
  1244. End If
  1245. TextStr.Close
  1246. Set ScoreFile = Nothing
  1247. Set FileObj = Nothing
  1248. SortHighscore 'added to fix a previous error
  1249. End Sub
  1250.  
  1251. ' Save Highscores
  1252.  
  1253. Sub Savehs
  1254. Dim FileObj
  1255. Dim ScoreFile
  1256. Dim x
  1257. Set FileObj = CreateObject("Scripting.FileSystemObject")
  1258. If Not FileObj.FolderExists(UserDirectory)then
  1259. Exit Sub
  1260. End If
  1261. Set ScoreFile = FileObj.CreateTextFile(UserDirectory & cGameName& ".txt", True)
  1262. ScoreFile.WriteLine 0
  1263. ScoreFile.WriteLine Credits
  1264. For x = 1 to 5
  1265. scorefile.writeline HSScore(x)
  1266. Next
  1267. For x = 1 to 5
  1268. scorefile.writeline HSName(x)
  1269. Next
  1270. ScoreFile.Close
  1271. Set ScoreFile = Nothing
  1272. Set FileObj = Nothing
  1273. End Sub
  1274.  
  1275. ' Sort Highscores
  1276.  
  1277. Sub SortHighscore
  1278. Dim tmp, tmp2, i, j
  1279. For i = 1 to 5
  1280. For j = 1 to 4
  1281. If HSScore(j) <HSScore(j + 1)Then
  1282. tmp = HSScore(j + 1)
  1283. tmp2 = HSName(j + 1)
  1284. HSScore(j + 1) = HSScore(j)
  1285. HSName(j + 1) = HSName(j)
  1286. HSScore(j) = tmp
  1287. HSName(j) = tmp2
  1288. End If
  1289. Next
  1290. Next
  1291. End Sub
  1292.  
  1293. ' check for new highscore
  1294.  
  1295. Sub CheckHighscore
  1296. If Score(CurrentPlayer)> HSSCore(1)Then
  1297. AwardSpecial
  1298. End If
  1299. If Score(CurrentPlayer)> HSSCore(5)Then
  1300. NewHighScore Score(CurrentPlayer), CurrentPlayer
  1301. Else
  1302. EndOfBallComplete()
  1303. End If
  1304. End Sub
  1305.  
  1306. ' Highscore Timer
  1307.  
  1308. Sub HighScoreTimer_Timer
  1309. If EnteringInitials then
  1310. SetHSLine 3, InitialString & MID(AlphaString, AlphaStringPos, 1)
  1311. ElseIf bGameInPlay then
  1312. SetHSLine 1, "HIGH SCORE"
  1313. SetHSLine 2, HSScore(1)
  1314. SetHSLine 3, HSName(1)
  1315. Me.Enabled = 0
  1316. Else
  1317. ' cycle through high scores
  1318. SetHSLine 1, "HIGH SCORE" & (HSTimerCount + 1)
  1319. SetHSLine 2, HSScore(HSTimerCount + 1)
  1320. SetHSLine 3, HSName(HSTimerCount + 1)
  1321. HSTimerCount = (HSTimerCount + 1)MOD 5
  1322. End If
  1323. End Sub
  1324.  
  1325. ' Enter Highscore initials
  1326.  
  1327. Function GetHSChar(String, Index)
  1328. Dim ThisChar
  1329. Dim FileName
  1330. ThisChar = Mid(String, Index, 1)
  1331. FileName = "PostIt"
  1332. If ThisChar = " " or ThisChar = "" then
  1333. FileName = FileName & "BL"
  1334. ElseIf ThisChar = "<" then
  1335. FileName = FileName & "LT"
  1336. ElseIf ThisChar = "_" then
  1337. FileName = FileName & "SP"
  1338. Else
  1339. FileName = FileName & ThisChar
  1340. End If
  1341. GetHSChar = FileName
  1342. End Function
  1343.  
  1344. Sub SetHsLine(LineNo, String)
  1345. Dim StrLen
  1346. Dim Index
  1347. Dim StartHSArray
  1348. Dim EndHSArray
  1349. Dim xFor
  1350. StartHSArray = array(0, 1, 12, 22)
  1351. EndHSArray = array(0, 11, 21, 31)
  1352. StrLen = len(string)
  1353. Index = 1
  1354. For xFor = StartHSArray(LineNo)to EndHSArray(LineNo)
  1355. Eval("HS" &xFor).imageA = GetHSChar(String, Index)
  1356. Index = Index + 1
  1357. Next
  1358. End Sub
  1359.  
  1360. Sub NewHighScore(NewScore, PlayNum)
  1361. If NewScore> HSScore(5)then
  1362. HighScoreTimer.interval = 500
  1363. HighScoreTimer.Enabled = 1
  1364. AlphaStringPos = 1 ' start with first character "A"
  1365. EnteringInitials = true ' intercept the control keys while entering initials
  1366. InitialString = "" ' initials entered so far, initialize to empty
  1367. SetHSLine 1, "PLAYER " + FormatNumber(PlayNum, 0)
  1368. SetHSLine 2, "ENTER NAME"
  1369. SetHSLine 3, MID(AlphaString, AlphaStringPos, 1)
  1370. HSNewHigh = NewScore
  1371. End If
  1372. End Sub
  1373.  
  1374. Sub CollectInitials(keycode)
  1375. Dim i
  1376. If keycode = LeftFlipperKey Then
  1377. ' back up to previous character
  1378. AlphaStringPos = AlphaStringPos - 1
  1379. If AlphaStringPos <1 then
  1380. AlphaStringPos = len(AlphaString) ' handle wrap from beginning to End
  1381. If InitialString = "" then
  1382. ' Skip the backspace If there are no characters to backspace over
  1383. AlphaStringPos = AlphaStringPos - 1
  1384. End If
  1385. End If
  1386. SetHSLine 3, InitialString & MID(AlphaString, AlphaStringPos, 1)
  1387. PlaySound "fx_Previous"
  1388. ElseIf keycode = RightFlipperKey Then
  1389. ' advance to Next character
  1390. AlphaStringPos = AlphaStringPos + 1
  1391. If AlphaStringPos> len(AlphaString)or(AlphaStringPos = len(AlphaString)and InitialString = "")then
  1392. ' Skip the backspace If there are no characters to backspace over
  1393. AlphaStringPos = 1
  1394. End If
  1395. SetHSLine 3, InitialString & MID(AlphaString, AlphaStringPos, 1)
  1396. PlaySound "fx_Next"
  1397. ElseIf keycode = StartGameKey or keycode = PlungerKey Then
  1398. SelectedChar = MID(AlphaString, AlphaStringPos, 1)
  1399. If SelectedChar = "_" then
  1400. InitialString = InitialString & " "
  1401. PlaySound("fx_Esc")
  1402. ElseIf SelectedChar = "<" then
  1403. InitialString = MID(InitialString, 1, len(InitialString)- 1)
  1404. If len(InitialString) = 0 then
  1405. ' If there are no more characters to back over, don't leave the < displayed
  1406. AlphaStringPos = 1
  1407. End If
  1408. PlaySound("fx_Esc")
  1409. Else
  1410. InitialString = InitialString & SelectedChar
  1411. PlaySound("fx_Enter")
  1412. End If
  1413. If len(InitialString) <3 then
  1414. SetHSLine 3, InitialString & SelectedChar
  1415. End If
  1416. End If
  1417. If len(InitialString) = 3 then
  1418. EnteringInitials = False
  1419. HSScore(5) = HSNewHigh
  1420. HSName(5) = InitialString
  1421. SortHighScore
  1422. HighScoreTimer.interval = 2000
  1423. End If
  1424. End Sub
  1425.  
  1426. '*******************
  1427. ' Realtime updates
  1428. '*******************
  1429.  
  1430. Sub RealTime_Timer
  1431. RollingUpdate
  1432. LeftFlipperTop.RotZ = LeftFlipper.CurrentAngle
  1433. RightFlipperTop.RotZ = RightFlipper.CurrentAngle
  1434. End Sub
  1435.  
  1436. '*********
  1437. ' LUT
  1438. '*********
  1439.  
  1440. Dim bLutActive, LUTImage
  1441. Sub LoadLUT
  1442. bLutActive = False
  1443. x = LoadValue(cGameName, "LUTImage")
  1444. If(x <> "")Then LUTImage = x Else LUTImage = 0
  1445. UpdateLUT
  1446. End Sub
  1447.  
  1448. Sub SaveLUT
  1449. SaveValue cGameName, "LUTImage", LUTImage
  1450. End Sub
  1451.  
  1452. Sub NextLUT:LUTImage = (LUTImage + 1)MOD 10:UpdateLUT:SaveLUT:End Sub
  1453.  
  1454. Sub UpdateLUT
  1455. Select Case LutImage
  1456. Case 0:table1.ColorGradeImage = "LUT0"
  1457. Case 1:table1.ColorGradeImage = "LUT1"
  1458. Case 2:table1.ColorGradeImage = "LUT2"
  1459. Case 3:table1.ColorGradeImage = "LUT3"
  1460. Case 4:table1.ColorGradeImage = "LUT4"
  1461. Case 5:table1.ColorGradeImage = "LUT5"
  1462. Case 6:table1.ColorGradeImage = "LUT6"
  1463. Case 7:table1.ColorGradeImage = "LUT7"
  1464. Case 8:table1.ColorGradeImage = "LUT8"
  1465. Case 9:table1.ColorGradeImage = "LUT9"
  1466. End Select
  1467. End Sub
  1468.  
  1469. '***********************************************************************
  1470. ' *********************************************************************
  1471. ' ********* G A M E C O D E S T A R T S H E R E *********
  1472. ' *********************************************************************
  1473. '***********************************************************************
  1474.  
  1475. Sub VPObjects_Init 'init objects
  1476. TurnOffPlayfieldLights()
  1477. Kicker001.CreateSizedBallWithMass BallSize / 2, BallMass:kicker001.kick 180, 0
  1478. Kicker002.CreateSizedBallWithMass BallSize / 2, BallMass:kicker002.kick 180, 0
  1479. End Sub
  1480.  
  1481. ' Dim all the variables
  1482. Dim SpecialActivated
  1483. Dim BallinBonusKicker
  1484. Dim LeftSpec
  1485. Dim RightSpec
  1486.  
  1487. Sub Game_Init() 'called at the start of a new game
  1488. 'Start music? Init variables? Start or init timers Init lights?
  1489. TurnOffPlayfieldLights()
  1490. bl020.State = 1
  1491. bl021.State = 1
  1492. bl013.State = 1
  1493. bl012.State = 1
  1494. bl008.State = 1
  1495. bl009.State = 1
  1496. Bonus = 0
  1497. AddBonus 1
  1498. BonusMultiplier = 1
  1499. UpdateMultiplierLights
  1500. SpecialActivated = False
  1501. BallinBonusKicker = False
  1502. CheckCenterSpecial
  1503. End Sub
  1504.  
  1505. Sub StopEndOfBallMode() 'called when the last ball is drained
  1506. End Sub
  1507.  
  1508. Sub ResetNewBallVariables() 'init variables new ball/player
  1509.  
  1510. End Sub
  1511.  
  1512. Sub ResetNewBallLights() 'init lights for new ball/player
  1513. 'TurnOffPlayfieldLights()
  1514. End Sub
  1515.  
  1516. Sub TurnOffPlayfieldLights()
  1517. Dim a
  1518. For each a in aLights
  1519. a.State = 0
  1520. Next
  1521. End Sub
  1522.  
  1523. ' *********************************************************************
  1524. ' Table Object Hit Events
  1525. ' *********************************************************************
  1526. ' Any target hit Sub will do this:
  1527. ' - play a sound
  1528. ' - do some physical movement
  1529. ' - add a score, bonus
  1530. ' - check some variables/modes this trigger is a member of
  1531. ' - set the "LastSwicthHit" variable in case it is needed later
  1532. ' *********************************************************************
  1533.  
  1534. ' Slingshots
  1535. Dim LStep, RStep
  1536.  
  1537. Sub LeftSlingShot_Slingshot
  1538. If Tilted Then Exit Sub
  1539. PlaySoundAt SoundFXDOF("fx_slingshot", 103, DOFPulse, DOFContactors), Lemk
  1540. LeftSling004.Visible = 1
  1541. Lemk.RotX = 26
  1542. LStep = 0
  1543. LeftSlingShot.TimerEnabled = True
  1544. ' add points
  1545. AddScore 10
  1546. ' some effect?
  1547. RotateSpecialLights
  1548. End Sub
  1549.  
  1550. Sub LeftSlingShot_Timer
  1551. Select Case LStep
  1552. Case 1:LeftSLing004.Visible = 0:LeftSLing003.Visible = 1:Lemk.RotX = 14
  1553. Case 2:LeftSLing003.Visible = 0:LeftSLing002.Visible = 1:Lemk.RotX = 2
  1554. Case 3:LeftSLing002.Visible = 0:Lemk.RotX = -20:LeftSlingShot.TimerEnabled = 0
  1555. End Select
  1556. LStep = LStep + 1
  1557. End Sub
  1558.  
  1559. Sub RightSlingShot_Slingshot
  1560. If Tilted Then Exit Sub
  1561. PlaySoundAt SoundFXDOF("fx_slingshot", 105, DOFPulse, DOFContactors), Remk
  1562. RightSling004.Visible = 1
  1563. Remk.RotX = 26
  1564. RStep = 0
  1565. RightSlingShot.TimerEnabled = True
  1566. ' add points
  1567. AddScore 10
  1568. ' add effect?
  1569. RotateSpecialLights
  1570. End Sub
  1571.  
  1572. Sub RightSlingShot_Timer
  1573. Select Case RStep
  1574. Case 1:RightSLing004.Visible = 0:RightSLing003.Visible = 1:Remk.RotX = 14
  1575. Case 2:RightSLing003.Visible = 0:RightSLing002.Visible = 1:Remk.RotX = 2
  1576. Case 3:RightSLing002.Visible = 0:Remk.RotX = -20:RightSlingShot.TimerEnabled = 0
  1577. End Select
  1578. RStep = RStep + 1
  1579. End Sub
  1580.  
  1581. Sub RotateSpecialLights
  1582. Dim tmp
  1583. tmp = bl022.State
  1584. bl022.State = bl023.State
  1585. bl023.State = tmp
  1586. tmp = bl007.State
  1587. bl007.State = bl006.State
  1588. bl006.State = tmp
  1589. End Sub
  1590.  
  1591. '**************
  1592. ' Rubbers
  1593. '**************
  1594. Dim Rub1, Rub2, Rub3
  1595.  
  1596. Sub sw63_Hit:vpmTimer.PulseSw 63:Rub1 = 1:sw63_Timer:End Sub
  1597.  
  1598. Sub sw63_Timer
  1599. Select Case Rub1
  1600. Case 1:r1.Visible = 0:r13.Visible = 1:sw63.TimerEnabled = 1
  1601. Case 2:r13.Visible = 0:r14.Visible = 1
  1602. Case 3:r14.Visible = 0:r1.Visible = 1:sw63.TimerEnabled = 0
  1603. End Select
  1604. Rub1 = Rub1 + 1
  1605. End Sub
  1606.  
  1607. Sub rsband010_Hit
  1608. If Tilted then Exit Sub
  1609. AddScore 10
  1610. Rub1 = 0
  1611. rsband010_Timer
  1612. End Sub
  1613.  
  1614. Sub rsband010_Timer
  1615. Select Case Rub1
  1616. Case 1:Rubber005.Visible = 0:Rubber025.Visible = 1:rsband010.TimerEnabled = 1
  1617. Case 2:Rubber025.Visible = 0:Rubber026.Visible = 1
  1618. Case 3:Rubber026.Visible = 0:Rubber005.Visible = 1:rsband010.TimerEnabled = 0
  1619. End Select
  1620. Rub1 = Rub1 + 1
  1621. End Sub
  1622.  
  1623. Sub rsband002_Hit
  1624. If Tilted then Exit Sub
  1625. AddScore 10
  1626. Rub2 = 0
  1627. rsband002_Timer
  1628. End Sub
  1629.  
  1630. Sub rsband002_Timer
  1631. Select Case Rub2
  1632. Case 1:Rubber014.Visible = 0:Rubber013.Visible = 1:rsband002.TimerEnabled = 1
  1633. Case 2:Rubber013.Visible = 0:Rubber024.Visible = 1
  1634. Case 3:Rubber024.Visible = 0:Rubber014.Visible = 1:rsband002.TimerEnabled = 0
  1635. End Select
  1636. Rub2 = Rub2 + 1
  1637. End Sub
  1638.  
  1639. Sub rsband008_Hit
  1640. Rub3 = 0
  1641. rsband008_Timer
  1642. End Sub
  1643.  
  1644. Sub rsband008_Timer
  1645. Select Case Rub3
  1646. Case 1:Rubber002.Visible = 0:Rubber027.Visible = 1:rsband008.TimerEnabled = 1
  1647. Case 2:Rubber027.Visible = 0:Rubber028.Visible = 1
  1648. Case 3:Rubber028.Visible = 0:Rubber002.Visible = 1:rsband008.TimerEnabled = 0
  1649. End Select
  1650. Rub3 = Rub3 + 1
  1651. End Sub
  1652.  
  1653. '*********
  1654. ' Bumpers
  1655. '*********
  1656.  
  1657. Sub Bumper001_Hit
  1658. If Tilted Then Exit Sub
  1659. PlaySoundAt SoundFXDOF("fx_Bumper", 107, DOFPulse, DOFContactors), bumper001
  1660. AddScore 10 + 90 * LBumper1a.State
  1661. End Sub
  1662.  
  1663. Sub Bumper002_Hit
  1664. If Tilted Then Exit Sub
  1665. PlaySoundAt SoundFXDOF("fx_Bumper", 109, DOFPulse, DOFContactors), bumper002
  1666. AddScore 10 + 90 * LBumper2a.State
  1667. End Sub
  1668.  
  1669. '*****************
  1670. ' Lanes
  1671. '*****************
  1672.  
  1673. ' inlanes & outlanes
  1674.  
  1675. Sub Trigger001_Hit
  1676. PlaySoundAt "fx_sensor", Trigger001
  1677. If Tilted Then Exit Sub
  1678. AddScore 500
  1679. bl020.State = 0
  1680. bl015.State = 1
  1681. If bl022.State Then AwardSpecial
  1682. CheckLights
  1683. End Sub
  1684.  
  1685. Sub Trigger002_Hit
  1686. PlaySoundAt "fx_sensor", Trigger002
  1687. If Tilted Then Exit Sub
  1688. AddScore 100
  1689. AddBonus 1
  1690. End Sub
  1691.  
  1692. Sub Trigger003_Hit
  1693. PlaySoundAt "fx_sensor", Trigger003
  1694. If Tilted Then Exit Sub
  1695. AddScore 100
  1696. AddBonus 1
  1697. End Sub
  1698.  
  1699. Sub Trigger004_Hit
  1700. PlaySoundAt "fx_sensor", Trigger004
  1701. If Tilted Then Exit Sub
  1702. AddScore 500
  1703. bl021.State = 0
  1704. bl014.State = 1
  1705. If bl023.State Then AwardSpecial
  1706. CheckLights
  1707. End Sub
  1708.  
  1709. ' top lanes
  1710.  
  1711. Sub Trigger005_Hit
  1712. PlaySoundAt "fx_sensor", Trigger005
  1713. If Tilted Then Exit Sub
  1714. AddScore 100
  1715. If bl010.State Then
  1716. BonusMultiplier = 2
  1717. UpdateMultiplierLights
  1718. bl010.State = 0
  1719. Else
  1720. Lbumper1a.State = 1
  1721. Lbumper1b.State = 1
  1722. bl010.State = 1
  1723. End If
  1724. End Sub
  1725.  
  1726. Sub Trigger006_Hit
  1727. PlaySoundAt "fx_sensor", Trigger006
  1728. If Tilted Then Exit Sub
  1729. AddScore 100
  1730. If bl011.State Then
  1731. BonusMultiplier = 3
  1732. UpdateMultiplierLights
  1733. bl011.State = 0
  1734. Else
  1735. Lbumper2a.State = 1
  1736. Lbumper2b.State = 1
  1737. bl011.State = 1
  1738. End If
  1739. End Sub
  1740.  
  1741. Sub Trigger007_Hit
  1742. PlaySoundAt "fx_sensor", Trigger007
  1743. If Tilted Then Exit Sub
  1744. AddScore 500
  1745. End Sub
  1746.  
  1747. ' sides lanes
  1748.  
  1749. Sub Trigger012_Hit
  1750. PlaySoundAt "fx_sensor", Trigger012
  1751. If Tilted Then Exit Sub
  1752. AddScore 30
  1753. AddBonus 3
  1754. End Sub
  1755.  
  1756. Sub Trigger011_Hit
  1757. PlaySoundAt "fx_sensor", Trigger011
  1758. If Tilted Then Exit Sub
  1759. AddScore 500
  1760. End Sub
  1761.  
  1762. ' center triggers
  1763.  
  1764. Sub Trigger008_Hit 'center
  1765. PlaySoundAt "fx_sensor", Trigger008
  1766. If Tilted Then Exit Sub
  1767. AddBonus 1
  1768. End Sub
  1769.  
  1770. Sub Trigger009_Hit 'right
  1771. PlaySoundAt "fx_sensor", Trigger009
  1772. If Tilted Then Exit Sub
  1773. RightSpec = 1
  1774. CheckCenterSpecial
  1775. End Sub
  1776.  
  1777. Sub Trigger009_UnHit 'right
  1778. RightSpec = 0
  1779. CheckCenterSpecial
  1780. End Sub
  1781.  
  1782. Sub Trigger010_Hit 'left
  1783. PlaySoundAt "fx_sensor", Trigger010
  1784. If Tilted Then Exit Sub
  1785. LeftSpec = 1
  1786. CheckCenterSpecial
  1787. End Sub
  1788.  
  1789. Sub Trigger010_UnHit 'left
  1790. LeftSpec = 0
  1791. CheckCenterSpecial
  1792. End Sub
  1793.  
  1794. Sub CheckCenterSpecial
  1795. If LeftSpec + RightSpec = 2 Then
  1796. bl005.State = 1
  1797. bl004.State = 0
  1798. Else
  1799. bl005.State = 0
  1800. bl004.State = 1
  1801. End If
  1802. End Sub
  1803.  
  1804. '************************
  1805. ' Targets
  1806. '************************
  1807.  
  1808. Sub Target001_hit
  1809. PlaySoundAtBall "fx_target"
  1810. If Tilted Then Exit Sub
  1811. AddScore 100 + 900 * bl008.State
  1812. bl008.State = 0
  1813. bl018.State = 1
  1814. CheckLights
  1815. End Sub
  1816.  
  1817. Sub Target002_hit
  1818. PlaySoundAtBall "fx_target"
  1819. If Tilted Then Exit Sub
  1820. AddScore 100 + 900 * bl009.State
  1821. bl009.State = 0
  1822. bl019.State = 1
  1823. CheckLights
  1824. End Sub
  1825.  
  1826. Sub Target003_hit
  1827. PlaySoundAtBall "fx_target"
  1828. If Tilted Then Exit Sub
  1829. AddScore 100 + 400 * bl012.State
  1830. bl012.State = 0
  1831. bl017.State = 1
  1832. If bl006.State Then AwardSpecial
  1833. CheckLights
  1834. End Sub
  1835.  
  1836. Sub Target005_hit
  1837. PlaySoundAtBall "fx_target"
  1838. If Tilted Then Exit Sub
  1839. AddScore 100 + 400 * bl013.State
  1840. bl013.State = 0
  1841. bl016.State = 1
  1842. If bl007.State Then AwardSpecial
  1843. CheckLights
  1844. End Sub
  1845.  
  1846. Sub Target004_hit 'center
  1847. PlaySoundAtBall "fx_target"
  1848. If Tilted Then Exit Sub
  1849. AddScore 500 + 4500 * bl004.State
  1850. If bl005.State Then AwardSpecial
  1851. End Sub
  1852.  
  1853. Sub seta001_hit 'at right outlane
  1854. PlaySoundAtBall "fx_target"
  1855. If Tilted Then Exit Sub
  1856. AddScore 500
  1857. setap1.TransY = -3: Me.TimerEnabled = 1
  1858. End Sub
  1859.  
  1860. Sub Seta001_Timer:setap1.TransY = 0: Me.TimerEnabled = 0: End Sub
  1861.  
  1862. Sub CheckLights
  1863. If bl014.State + bl015.State + bl016.State + bl017.State + bl018.State + bl019.State = 6 Then
  1864. If NOT SpecialActivated Then
  1865. AwardSpecial
  1866. bl023.State = 1
  1867. bl006.State = 1
  1868. SpecialActivated = true
  1869. End If
  1870. End If
  1871. End Sub
  1872.  
  1873. ' Bonus kicker hole
  1874.  
  1875. Sub BonusKicker_Hit
  1876. PlaySoundAt "fx_kicker_enter", BonusKicker
  1877. If NOT Tilted Then
  1878. BallinBonusKicker = True
  1879. StartBonusCount
  1880. Else
  1881. BonusKickOut
  1882. End If
  1883. End Sub
  1884.  
  1885. Sub BonusKickOut
  1886. PlaySoundAt SoundFXDOF("fx_kicker", 111, DOFPulse, DOFContactors), BonusKicker
  1887. BallinBonusKicker = False
  1888. BonusKicker.kick 190, 18
  1889. End Sub
Add Comment
Please, Sign In to add comment