1 REM TACKER: tob (Tob) 2 REM DATE: 11-Aug-16 21:02:28 3 REM CHECKED: www.quitebasic.com 10 CLS : rem Work, goddamit! 20 print "Three Dice Shwarma Thief" : print 30 let x = 8 : rem input "How many players?"; x 33 let b4 = .25 : rem input "How much is the ante?"; b4 35 let b3 = x : rem all ante b3=pot 40 let u = 1 : rem total round counter 45 let t2 = 0: rem Thief change counter 50 let t = 0 : let n = 3 60 for m = 1 to x : rem turn counter 80 let k = 0 : let d = 0 90 for q = 1 to 3 110 let a = int (rnd(6))+1 130 if a > 3 then let k = k + 1 150 if a < 3 then let d = d + 1 170 next q 200 print "Player ";m;" rolls ";k;" Shwarma and ";d;" Swami and ";3 - k - d;" Djinn" 210 if 3-k-d=3 then 600 230 if 3-k-d >0 then gosub 400 240 if k = 3 then 270 250 if d = 3 then 340 else 390 270 let t2 = t2 + 1 : rem Thief assign t = thief flag 280 let t = m 290 print "Player ";m;" has stolen the shwarma!" 300 let b3 = b3 + x 330 goto 390 340 rem Swami win resolve check thief 345 print 350 if t = 0 then 600 360 let m = t 370 print "Shwarma Thief "; 380 goto 600 390 next m : rem Next player! 393 pause 3000 : next z : cls 394 if t > 0 then print "Player ";t;" has the Shwarma" else print "No one has the Shwarma yet!" 395 let u = u + 1 : print : print "Round ";u;" Pot ";b3 : goto 60 400 rem reroll subroutine 402 if k = d then let b3 = b3 + 2 : if k = d then return 405 print "Re-rolling ";3-k-d; " Djinn..." 410 for r = 1 to 3-k-d 420 let b = int (rnd(6))+1 430 if b > 3 then let k = k + 1 450 if b < 3 then let d = d + 1 470 next r 480 print "Player ";m;" new results: ";k;" Shwarma and ";d;" Swami and ";3-k-d; " Djinn" 490 if k = d then let b3 = b3 + 2 500 return 520 end 600 rem Winning 605 if k + d <> 0 then 610 else print : print "3 Djinn! "; 610 print "Player ";m;" Wins!" 620 print : print u;" Total Rounds Played. Winner's Purse: $";b3*b4 621 print : print "The Shwarma changed hands ";t2;" times (";t2/u;" times per round)" 690 end