"Welcome to Crest of a Star; these maps and other graphics are only for playing D&D type games. They are copyright and not to be used for other purposes. If you have them on your site, please remove them. Thank you."

"My maps are free. If you purchased them, you got scammed."
"Not for redistribution or resale. Hyperlinking from Pinterest or other such share sites is prohibited."





basic: game timer/clock/dice program

Posted

This is my AmigaBASIC adventure timer program on my campaign World, Crestar.


‘
‘ This program needs to be: clear ,76800, 10000
‘                    Setup
‘
LM = 366
DIM Mnhr1%(LM),Mnhr2%(LM),Mnmn1%(LM),Mnmn2%(LM),Sunrise$(LM),Sunset$(LM)
DIM CHINGRP$(150)
DIM CRG$(18)
W$ = “ Rise “ : X$ = “ SET “ : ACK$ = “ A.M. “ : PCK$ =” P.M.”
ABONUS% = 0 : BBONUS% = 0
‘
‘ country inputs
 FOR CRTS = 1 TO 16
    READ CRG$(CRTS)
 NEXT CRTS
‘
‘
DATA “Dank Forest”,“Gahstra”,“Grand Isle of Karenth”,“Groz”,“Isle of Fools”,“Land of Strife”
‘
DATA “Land of the Giants”,“Mountains of Fire”,Nalo Island”,“Nomads”,“Noral”,“Plains of Dareth”
‘
DATA “Tanoria”,“Teslarc”,“The Great Open”,“Trillolara”
‘
‘
CLS:PRINT
FOR cvg = 1 TO 16
  IF cvg < 10 THEN
    PRINT “ “;cvg;” ) “;CRG$(cvg)
  ELSE
    PRINT cvg;” ) “;CRG$(cvg)
  END IF
  NEXT cvg
‘
INPUT “Country number ? “,brill
CNTRY$ = CRG$(brill)
INPUT “Town where adventure starts  ? “,TWN$
‘
INPUT “Name of the adventure area (dungeon/castle/forest/etc.) ? “,DNGN$
AGE%=11
‘INPUT “Age (epoch)  ? “,AGE%
‘INPUT “Year (maximum depends on epoch) ? “,YEAR%
INPUT “Year ? “,YEAR%
YR1% = YEAR% : YR2% = YEAR%
‘
INPUT “Month (1 thru 12)  ? “,MNTH%
INPUT “Year Day (1 thru 366) ? “,YRD%
INPUT “Month day (1 thru 30)  ? “,MND%
INPUT “Hour (24 hour clock)  ? “,HR%
INPUT “Minutes (0 thru 59)  ? “,MIN%
INPUT “Seconds (0 thru 59)  ? “,SCND%
CLS : PRINT , “Loading sun rise and set times. ( Please wait !)”
‘
SUN:
   FOR LL = 1 TO 366 STEP 3
     READ Sunrise$(LL),Sunset$(LL),Sunrise$(LL+1),Sunset$(LL+1),Sunrise$(LL+2),Sunset$(LL+2)
   NEXT LL
‘
‘ Sun data for my game planet
‘
‘    day 1-6   #1 Month 1
DATA “7:30::23”,“4:21::47”,“7:30::27”,“4:22::40”,“7:30::32”,“4:23::34”,“7:30::36”,“4:24::27”,“7:30::40”,“4:25::21”,
“7:30::44”,“4:26::15”
‘
‘    day 7-12  #2
DATA “7:30::49”,“4:27::08”,“7:30::53”,“4:28::02”,“7:30::57”,“4:28::55”,“7:31::02”,“4:29::49”,“7:31::06”,“4:30::42”,
“7:31::10”,“4:31::36”
‘
‘    day 13-18  #3
DATA “7:31::14”,“4:32::30”,“7:31::19”,“4:33::23”,“7:31::23”,“4:34::17”,“7:30::17”,“4:35::10”,“7:29::10”,“4:36::04”,
“7:28::04”,“4:36::57”
‘
‘    day 19-24  #4
DATA “7:26::57”,“4:37::51”,“7:25::45”,“4:38::45”,“7:24::44”,“4:39::38”,“7:23::38”,“4:40::32”,“7:22::32”,“4:41::25”,
“7:21::25”,“4:42::19”
‘
‘    day 25-30  #5
DATA “7:20::19”,“4:43::12”,“7:19::12”,“4:44::06”,“7:18::06”,“4:45::00”,“7:16::59”,“4:45::53”,“7:15::53”,“4:47::08”,
“7:14::47”,“4:48::23”
‘
‘    day 31-36  #6 Month 2
DATA “7:13::40”,“4:49::38”,“7:12::34”,“4:50::53”,“7:11::27”,“4:52::08”,“7:10::21”,“4:53::23”,“7:09::14”,“4:54::38”,
“7:08::08”,“4:55::53”
‘
‘    day 37-42  #7
DATA “7:07::02”,“4:57::08”,“7:05::55”,“4:58::23”,“7:04::49”,“4:59::38”,“7:03::42”,“5:00::53”,“7:02::36”,“5:02::08”,
“7:01::29”,“5:03::23”
‘
‘    day 43-48  #8
DATA “7:00::23”,“5:04::38”,“6:59::17”,“5:05::53”,“6:58::10”,“5:07::08”,“6:57::04”,“5:08::23”,“6:55::57”,“5:09::38”,
“6:54::51”,“5:10::53”
‘
‘    day 49-54  #9
DATA “6:53::44”,“5:12::09”,“6:52::12”,“5:13::23”,“6:50::40”,“5:14::38”,“6:49::08”,“5:15::53”,“6:47::36”,“5:17::08”,
“6:46::04”,“5:18::23”
‘
‘    day 55-60  #10
DATA “6:44::32”,“5:19::38”,“6:42::59”,“5:20::53”,“6:41::27”,“5:22::09”,“6:39::55”,“5:23::24”,“6:38::23”,“5:24::31”,
“6:36::51”,“5:25::39”
‘
‘    day 61-66  #11 Month 3
DATA “6:35::19”,“5:26::49”,“6:33::47”,“5:27::54”,“6:32::15”,“5:29::02”,“6:30::42”,“5:30::09”,“6:29::10”,“5:31::18”,
“6:27::38”,“5:32::25”
‘
‘    day 67-72  #12
DATA “6:26::06”,“5:33::33”,“6:24::34”,“5:34::41”,“6:23::02”,“5:35::48”,“6:21::30”,“5:36::56”,“6:19::57”,“5:38::03”,
“6:18::25”,“5:39::12”
‘
‘    day 73-78  #13
DATA “6:16::53”,“5:40::19”,“6:15::21”,“5:41::27”,“6:13::49”,“5:42::34”,“6:12::17”,“5:43::42”,“6:10::45”,“5:44::50”,
“6:09::12”,“5:45::57”
‘
‘    day 79-84  #14
DATA “6:07::40”,“5:47::06”,“6:06::08”,“5:48::13”,“6:04::36”,“5:49::21”,“6:03::04”,“5:50::29”,“6:01::32”,“5:51::36”,
“5:59::49”,“5:52::44”
‘
‘    day 85-90  #15
DATA “5:58::06”,“5:53::52”,“5:56::23”,“5:54::59”,“5:54::40”,“5:56::02”,“5:52::57”,“5:57::04”,“5:51::15”,“5:58::06”,
“5:49::32”,“5:59::09”
‘
‘    day 91-96  #16 Month 4
DATA “5:47::49”,“6:00::11”,“5:46::06”,“6:01::13”,“5:44::23”,“6:02::16”,“5:42::40”,“6:03::18”,“5:39::15”,“6:04::20”,
“5:37::32”,“6:05::22”
‘
‘    day 97-102  #17
DATA “5:35::49”,“6:06::24”,“5:34::06”,“6:07::27”,“5:32::23”,“6:08::29”,“5:30::40”,“6:09::32”,“5:28::57”,“6:10::33”,
“5:27::15”,“6:11::36”
‘
‘    day 103-108  #18
DATA “5:25::32”,“6:12::38”,“5:23::49”,“6:13::40”,“5:22::06”,“6:14::43”,“5:20::23”,“6:15::45”,“5:18::40”,“6:16::48”,
“5:16::57”,“6:17::50”
‘
‘    day 109-114  #19
DATA “5:15::15”,“6:18::52”,“5:13::32”,“6:19::54”,“5:11:49”,“6:20::56”,“5:10::06”,“6:21::59”,“5:08::23”,“6:23::01”,
“5:06::40”,“6:24::03”
‘
‘    day 115-120  #20
DATA “5:04::57”,“6:25::06”,“5:03::15”,“6:26::08”,“5:01::32”,“6:27::10”,“5:00::47”,“6:28::15”,“5:00::03”,“6:29::19”,
“4:59::19”,“6:30::23”
‘
‘    day 121-126  #21   Month 5
DATA “4:58::34”,“6:31::27”,“4:57::50”,“6:32::31”,“4:57::06”,“6:33::36”,“4:56::21”,“6:34::40”,“4:55::37”,“6:35::44”,
“4:54::53”,“6:36::49”
‘
‘    day 127-132  #22
DATA “4:54::08”,“6:37::53”,“4:53::24”,“6:38::57”,“4:52::40”,“6:40::02”,“4:51::55”,“6:41::06”,“4:51::11”,“6:42::10”,
“4:50::27”,“6:43::14”
‘
‘    day 133-138  #23
DATA “4:49::42”,“6:44::19”,“4:48::58”,“6:45::23”,“4:48::14”,“6:46::28”,“4:47::29”,“6:47::32”,“4:46::45”,“6:48::36”,
“4:46::01”,“6:49::40”
‘
‘    day 139-144  #24
DATA “4:45::16”,“6:50::45”,“4:44::32”,“6:51::48”,“4:43::48”,“6:52::53”,“4:43::03”,“6:53::57”,“4:42::19”,“6:55::02”,
“4:41::35”,“6:56::06”
‘
‘    day 145-150  #25
DATA “4:40::51”,“6:57::10”,“4:40::06”,“6:58::15”,“4:39::22”,“6:59::19”,“4:38::38”,“7:00::23”,“4:37::53”,“7:01::27”,
“4:37::38”,“7:02::21”
‘
‘    day 151-156  #26   Month 6
DATA “4:37::23”,“7:03::15”,“4:37::08”,“7:04::08”,“4:36::54”,“7:05::02”,“4:36::39”,“7:05::55”,“4:36::24”,“7:06::48”,
“4:36::09”,“7:07::42”
‘
‘    day 157-162  #27
DATA “4:35::55”,“7:08::36”,“4:35::40”,“7:09::29”,“4:35::25”,“7:10::23”,“4:35::10”,“7:11:16”,“4:34::56”,“7:12::10”,
“4:34::41”,“7:13::03”
‘
‘    day 163-168  #28
DATA “4:34::26”,“7:13::56”,“4:34::11”,“7:14::50”,“4:33::56”,“715::43”,“4:33::42”,“7:16::37”,“4:33::27”,“7:17::30”,
“4:33::12”,“7:18::24”
‘
‘    day 169-174  #29
DATA “4:32::57”,“7:19::18”,“4:32::43”,“7:20::11”,“4:32::28”,“7:21::05”,“4:32::13”,“7:21::58”,“4:31::59”,“7:22::52”,
“4:31::44”,“7:23::45”
‘
‘    day 175-180  #30
DATA “4:31::29”,“7:24::38”,“4:31::14”,“7:25::32”,“4:31::00”,“7:26::25”,“4:30::45”,“7:27::19”,“4:30::30”,“7:28::12”,
“4:30::15”,“7:29::06”
‘
‘    day 181-186  #31   Lithe 1-3 and Month 7
999 DATA “4:30::06”,“7:29::59”,“4:30::00”,“7:30::00”,“4:30::27”,“7:29::54”,“4:30::55”,“7:29::47”,“4:31::23”,“7:29::41”,
“4:31::51”,“7:29::34”
‘
‘    day 187-192  #32
DATA “4:32::19”,“7:29::28”,“4:32::47”,“7:29::21”,“4:33::15”,“7:29::15”,“4:33::42”,“7:29::09”,“4:34::10”,“7:29::02”,
“4:34::38”,“7:28::56”
‘
‘    day 193-198  #33
DATA “4:35::06”,“7:28::49”,“4:35::34”,“7:28::43”,“4:36::02”,“7:28::36”,“4:36::30”,“7:28::30”,“4:36::57”,“7:28::24”,
“4:37::25”,“7:28::17”
‘
‘    day 199-204  #34
DATA “4:37::53”,“7:28::11”,“4:38::21”,“7:28::04”,“4:38::49”,“7:27::58”,“4:39::17”,“7:28::51”,“4:39::45”,“7:28::45”,
“4:40::45”,“7:28::39”
‘
‘    day 205-210  #35
DATA “4:41::45”,“7:27::38”,“4:42::45”,“7:26::30”,“4:43::45”,“7:25::58”,“4:44::45”,“7:24::05”,“4:45::45”,“7:22::56”,
“4:46::45”,“7:21::48”
‘
‘    day 211-216  #36 Month 8
DATA “4:47::45”,“7:20::39”,“4:48::45”,“7:19::30”,“4:49::45”,“7:18::21”,“4:50::45”,“7:17::13”,“4:51::45”,“7:16::05”,
“4:52::45”,“7:14::56”
‘
‘    day 217-222  #37
DATA “4:53::45”,“7:13::48”,“4:54::45”,“7:12::39”,“4:55::45”,“7:11::30”,“4:56::45”,“7:10::21”,“4:57::45”,“7:09::13”,
“4:58::45”,“7:08::05”
‘
‘    day 223-228  #38
DATA “4:59::45”,“7:06::56”,“5:00::45”,“7:05::48”,“5:01::45”,“7:04::39”,“5:02::45”,“7:03::30”,“5:03::45”,“7:02::21”,
“5:04::45”,“7:01::13”
‘
‘    day 229-234  #39
DATA “5:05::45”,“7:00::05”,“5:06::45”,“6:58::56”,“5:07::45”,“6:57::48”,“5:08::45”,“6:56::38”,“5:09::45”,“6:55::30”,
“5:10::45”,“6:54::21”
‘
‘    day 235-240  #40
DATA “5:11::45”,“6:53::13”,“5:12::45”,“6:52::05”,“5:13::53”,“6:50::24”,“5:15::02”,“6:48::43”,“5:16::10”,“6:47::03”,
“5:17::19”,“6:45::22”
‘
‘    day 241-246  #41 Month 9
DATA “5:18::27”,“6:43::41”,“5:19::36”,“6:42::01”,“5:20::45”,“6:40::19”,“5:21::53”,“6:38::39”,“5:23::2”,“6:36::59”,
“5:24::10”,“6:35::18”
‘
‘    day 247-252  #42
DATA “5:25::19”,“6:33::37”,“5:26::27”,“6:31::56”,“5:27::36”,“6:30::16”,“5:28::45”,“6:28::34”,“5:29::53”,“6:26::54”,
“5:31::02”,“6:25::14”
‘
‘    day 253-258  #43
DATA “5:32::10”,“6:23::33”,“5:33::19”,“6:21::52”,“5:34::27”,“6:20::11”,“5:35::36”,“6:18::30”,“5:36::45”,“6:16::50”,
“5:37::53”,“6:15::09”
‘
‘    day 259-264  #44
DATA “5:39::02”,“6:13::29”,“5:40::10”,“6:11::48”,“5:41::19”,“6:10::07”,“5:42::27”,“6:08::26”,“5:43::36”,“6:06::45”,
“5:44::45”,“6:05::05”
‘
‘    day 265-270  #45
DATA “5:45::53”,“6:03::24”,“5:47::02”,“6:01::43”,“5:48::10”,“6:00::03”,“5:49::15”,“5:58::22”,“5:50::19”,“5:56::37”,
“5:51::23”,“5:54::52”
‘
‘    day 271-276  #46 Month 10
DATA “5:52::27”,“5:53::07”,“5:53::32”,“5:51::22”,“5:54::36”,“5:49::37”,“5:55::40”,“5:47::52”,“5:56::45”,“5:46::07”,
“5:57::49”,“5:44::22”
‘
‘    day 277-282  #47
DATA “5:58::53”,“5:42::37”,“5:59::57”,“5:40::52”,“6:01::02”,“5:39::07”,“6:02::06”,“5:37::22”,“6:03::10”,“5:35::37”,
“6:04::14”,“5:33::52”
‘
‘    day 283-288  #48
DATA “6:05::19”,“5:32::07”,“6:06::23”,“5:30::22”,“6:07::27”,“5:28::37”,“6:08::32”,“5:26::52”,“6:09::36”,“5:25::07”,
“6:10::40”,“5:23::22”
‘
‘    day 289-294  #49
DATA “6:11::44”,“5:21::37”,“6:12::49”,“5:19::52”,“6:13::53”,“5:18::07”,“6:14::57”,“5:16::22”,“6:16::02”,“5:14::37”,
“6:17::06”,“5:12::52”
‘
‘    day 295-300  #50
DATA “6:18::10”,“5:11::07”,“6:19::15”,“5:09::22”,“6:20::19”,“5:07::37”,“6:21::23”,“5:05::52”,“6:22::36”,“5:04::07”,
“6:23::49”,“5:02::22”
‘
‘    day 301-306  #51 Month 11
DATA “6:25::02”,“5:01::14”,“6:26::15”,“5:00::05”,“6:27::27”,“4:58::56”,“6:28::40”,“4:57::48”,“6:29::53”,“4:56::39”,
“6:31::06”,“4:55::30”
‘
‘    day 307-312  #52
DATA “6:32::19”,“4:54::22”,“6:33::32”,“4:53::14”,“6:34::45”,“4:52::05”,“6:35::57”,“4:50::57”,“6:37::10”,“4:49::48”,
“6:38::23”,“4:48::39”
‘
‘    day 313-318  #53
DATA “6:39::36”,“4:47::31”,“6:40::49”,“4:46::22”,“6:42::02”,“4:45::14”,“6:43::15”,“4:44::06”,“6:44::27”,“4:42::57”,
“6:45::40”,“4:41::48”
‘
‘    day 319-324  #54
DATA “6:46::53”,“4:40::39”,“6:48::06”,“4:39::31”,“6:49::19”,“4:38::23”,“6:50::32”,“4:37::14”,“6:51::45”,“4:36::06”,
“6:52::57”,“4:34::57”
‘
‘    day 325-330  #55
DATA “6:54::10”,“4:33::48”,“6:55::23”,“4:32::40”,“6:56::36”,“4:31::32”,“6:57::47”,“4:30::23”,“6:58::57”,“4:29::14”,
“7:00::08”,“4:28::06”
‘
‘    day 331-336  #56
DATA “7:01::19”,“4:26::57”,“7:02::29”,“4:25::48”,“7:03::40”,“4:24::40”,“7:04::51”,“4:24::31”,“7:06::02”,“4:24::21”,
“7:07::12”,“4:24::12”
‘
‘    day 337-342  #57
DATA “7:08::23”,“4:24::03”,“7:09::34”,“4:23::53”,“7:10::44”,“4:23::45”,“7:11::55”,“4:23::35”,“7:13::06”,“4:23::25”,
“7:14::17”,“4:23::16”
‘
‘    day 343-348  #58
DATA “7:15::27”,“4:23::07”,“7:16::38”,“4:22::57”,“7:17::19”,“4:22::48”,“7:18::59”,“4:22::39”,“7:20::10”,“4:22::30”,
“7:21::21”,“4:22::21”
‘
‘    day 349-354  #59
DATA “7:22::32”,“4:22::11”,“7:23::42”,“4:22::02”,“7:24::53”,“4:21::52”,“7:26::04”,“4:21::43”,“7:27::14”,“4:21::34”,
“7:28::25”,“4:21::25”
‘
‘    day 355-360  #60
DATA “7:29::36”,“4:21::15”,“7:29::40”,“4:21::06”,“7:29::44”,“4:20::57”,“7:29::49”,“4:20::47”,“7:29::53”,“4:20::38”,
“7:29::57”,“4:20::29”
‘
‘    day 361-366  #61 Month 12 and Yule 1-3
DATA “7:30::02”,“4:20::19”,“7:30::06”,“4:20::10”,“7:30::10”,“4:20::05”,“7:30::14”,“4:20::00”,“7:30::19”,“4:20::53”,
“7:30::21”,“4:21::28”
‘
‘           moon rise and set generation subroutine
Moon:
‘
‘ Lunar data for my game planet
‘
  IF AGE% = 11 THEN
    PRINT “Loading and generating moon rise and set times (This will take awhile !)” : PRINT
‘
    IF (YEAR% = 69 OR YEAR% = 140 OR YEAR% = 211 OR YEAR% = 282 OR YEAR% = 353 OR YEAR% = 424 OR YEAR% = 495 OR YEAR% = 566) THEN
       MM = 27 : HH = 10
    ELSEIF (YEAR% = 70 OR YEAR% = 141 OR YEAR% = 212 OR YEAR% = 283 OR YEAR% = 354 OR YEAR% = 425 OR YEAR% = 496 OR YEAR% = 567) THEN
       MM = 15 : HH = 9
    ELSEIF (YEAR% = 71 OR YEAR% = 142 OR YEAR% = 213 OR YEAR% = 284 OR YEAR% = 355 OR YEAR% = 426 OR YEAR% = 497 OR YEAR% = 568) THEN
       MM = 9 : HH = 8
    ELSEIF (YEAR% = 1 OR YEAR% = 72 OR YEAR% = 143 OR YEAR% = 214 OR YEAR% = 285 OR YEAR% = 356 OR YEAR% = 427 OR YEAR% = 498 OR YEAR% = 569) THEN
       MM = 3 : HH = 7
    ELSEIF (YEAR% = 2 OR YEAR% = 73 OR YEAR% = 144 OR YEAR% = 215 OR YEAR% = 286 OR YEAR% = 357 OR YEAR% = 428 OR YEAR% = 499 OR YEAR% = 570)THEN
       MM = 57 : HH = 6
    ELSEIF (YEAR% = 3 OR YEAR% = 74 OR YEAR% = 145 OR YEAR% = 216 OR YEAR% = 287 OR YEAR% = 358 OR YEAR% = 429 OR YEAR% = 500 OR YEAR% = 571) THEN
       MM = 51 : HH = 5
    ELSEIF (YEAR% = 4 OR YEAR% = 75 OR YEAR% = 146 OR YEAR% = 217 OR YEAR% = 288 OR YEAR% = 359 OR YEAR% = 430 OR YEAR% = 501 OR YEAR% = 572) THEN
       MM = 45 : HH = 4
    ELSEIF (YEAR% = 5 OR YEAR% = 76 OR YEAR% = 147 OR YEAR% = 218 OR YEAR% = 289 OR YEAR% = 360 OR YEAR% = 431 OR YEAR% = 502 OR YEAR% = 573) THEN
       MM = 39 : HH = 3
    ELSEIF (YEAR% = 6 OR YEAR% = 77 OR YEAR% = 148 OR YEAR% = 219 OR YEAR% = 290 OR YEAR% = 361 OR YEAR% = 432 OR YEAR% = 503 OR YEAR% = 574) THEN
       MM = 33 : HH = 2
    ELSEIF (YEAR% = 7 OR YEAR% = 78 OR YEAR% = 149 OR YEAR% = 220 OR YEAR% = 291 OR YEAR% = 362 OR YEAR% = 433 OR YEAR% = 504 OR YEAR% = 575) THEN
       MM = 27 : HH = 1
    ELSEIF (YEAR% = 8 OR YEAR% = 79 OR YEAR% = 150 OR YEAR% = 221 OR YEAR% = 292 OR YEAR% = 363 OR YEAR% = 434 OR YEAR% = 505 OR YEAR% = 576) THEN
       MM = 21 : HH = 0
    ELSEIF (YEAR% = 9 OR YEAR% = 80 OR YEAR% = 151 OR YEAR% = 222 OR YEAR% = 293 OR YEAR% = 364 OR YEAR% = 435 OR YEAR% = 506 OR YEAR% = 577) THEN
       MM = 15 : HH = 23
    ELSEIF (YEAR% = 10 OR YEAR% = 81 OR YEAR% = 152 OR YEAR% = 223 OR YEAR% = 294 OR YEAR% = 365 OR YEAR% = 436 OR YEAR% = 507 OR YEAR% = 578)THEN
       MM = 9 : HH = 22
    ELSEIF (YEAR% = 11 OR YEAR% = 82 OR YEAR% = 153 OR YEAR% = 224 OR YEAR% = 295 OR YEAR% = 366 OR YEAR% = 437 OR YEAR% = 508 OR YEAR% = 579)THEN
       MM = 3 : HH = 21
    ELSEIF (YEAR% = 12 OR YEAR% = 83 OR YEAR% = 154 OR YEAR% = 225 OR YEAR% = 296 OR YEAR% = 367 OR YEAR% = 438 OR YEAR% = 509 OR YEAR% = 580) THEN
       MM = 57 : HH = 20
    ELSEIF (YEAR% = 13 OR YEAR% = 84 OR YEAR% = 155 OR YEAR% = 226 OR YEAR% = 297 OR YEAR% = 368 OR YEAR% = 439 OR YEAR% = 510 OR YEAR% = 581) THEN
       MM = 51 : HH = 19
    ELSEIF (YEAR% = 14 OR YEAR% = 85 OR YEAR% = 156 OR YEAR% = 227 OR YEAR% = 298 OR YEAR% = 369 OR YEAR% = 440 OR YEAR% = 511 OR YEAR% = 582) THEN
       MM = 45 : HH = 18
    ELSEIF (YEAR% = 15 OR YEAR% = 86 OR YEAR% = 157 OR YEAR% = 228 OR YEAR% = 299 OR YEAR% = 370 OR YEAR% = 441 OR YEAR% = 512 OR YEAR% = 583) THEN
       MM = 39 : HH = 17
    ELSEIF (YEAR% = 16 OR YEAR% = 87 OR YEAR% = 158 OR YEAR% = 229 OR YEAR% = 300 OR YEAR% = 371 OR YEAR% = 442 OR YEAR% = 513 OR YEAR% = 584) THEN
       MM = 33 : HH = 16
    ELSEIF (YEAR% = 17 OR YEAR% = 88 OR YEAR% = 159 OR YEAR% = 230 OR YEAR% = 301 OR YEAR% = 372 OR YEAR% = 443 OR YEAR% = 514 OR YEAR% = 585) THEN
       MM = 27 : HH = 15
    ELSEIF (YEAR% = 18 OR YEAR% = 89 OR YEAR% = 160 OR YEAR% = 231 OR YEAR% = 302 OR YEAR% = 373 OR YEAR% = 444 OR YEAR% = 515 OR YEAR% = 586) THEN
       MM = 21 : HH = 14
    ELSEIF (YEAR% = 19 OR YEAR% = 90 OR YEAR% = 161 OR YEAR% = 232 OR YEAR% = 303 OR YEAR% = 374 OR YEAR% = 445 OR YEAR% = 516 OR YEAR% = 587) THEN
       MM = 15 : HH = 13
    ELSEIF (YEAR% = 20 OR YEAR% = 91 OR YEAR% = 162 OR YEAR% = 233 OR YEAR% = 304 OR YEAR% = 375 OR YEAR% = 446 OR YEAR% = 517 OR YEAR% = 588) THEN
       MM = 9 : HH = 12
    ELSEIF (YEAR% = 21 OR YEAR% = 92 OR YEAR% = 163 OR YEAR% = 234 OR YEAR% = 305 OR YEAR% = 376 OR YEAR% = 447 OR YEAR% = 518 OR YEAR% = 589) THEN
       MM = 3 : HH = 11
    ELSEIF (YEAR% = 22 OR YEAR% = 93 OR YEAR% = 164 OR YEAR% = 235 OR YEAR% = 306 OR YEAR% = 377 OR YEAR% = 448 OR YEAR% = 519 OR YEAR% = 590) THEN
       MM = 57 : HH = 10
    ELSEIF (YEAR% = 23 OR YEAR% = 94 OR YEAR% = 165 OR YEAR% = 236 OR YEAR% = 307 OR YEAR% = 378 OR YEAR% = 449 OR YEAR% = 520 OR YEAR% = 591) THEN
       MM = 51 : HH = 9
    ELSEIF (YEAR% = 24 OR YEAR% = 95 OR YEAR% = 166 OR YEAR% = 237 OR YEAR% = 308 OR YEAR% = 379 OR YEAR% = 450 OR YEAR% = 521 OR YEAR% = 592) THEN
       MM = 45 : HH = 8
    ELSEIF (YEAR% = 25 OR YEAR% = 96 OR YEAR% = 167 OR YEAR% = 238 OR YEAR% = 309 OR YEAR% = 380 OR YEAR% = 451 OR YEAR% = 522 OR YEAR% = 593) THEN
       MM = 39 : HH = 7
    ELSEIF (YEAR% = 26 OR YEAR% = 97 OR YEAR% = 168 OR YEAR% = 239 OR YEAR% = 310 OR YEAR% = 381 OR YEAR% = 452 OR YEAR% = 523 OR YEAR% = 594) THEN
       MM = 33 : HH = 6
    ELSEIF (YEAR% = 27 OR YEAR% = 98 OR YEAR% = 169 OR YEAR% = 240 OR YEAR% = 311 OR YEAR% = 382 OR YEAR% = 453 OR YEAR% = 524 OR YEAR% = 595) THEN
       MM = 27 : HH = 5
    ELSEIF (YEAR% = 28 OR YEAR% = 99 OR YEAR% = 170 OR YEAR% = 241 OR YEAR% = 312 OR YEAR% = 383 OR YEAR% = 454 OR YEAR% = 525 OR YEAR% = 596) THEN
       MM = 21 : HH = 4
    ELSEIF (YEAR% = 29 OR YEAR% = 100 OR YEAR% = 171 OR YEAR% = 242 OR YEAR% = 313 OR YEAR% = 384 OR YEAR% = 455 OR YEAR% = 526 OR YEAR% = 597) THEN
       MM = 15 : HH = 3
    ELSEIF (YEAR% = 30 OR YEAR% = 101 OR YEAR% = 173 OR YEAR% = 243 OR YEAR% = 314 OR YEAR% = 385 OR YEAR% = 456 OR YEAR% = 527 OR YEAR% = 598) THEN
       MM = 9 : HH = 2
    ELSEIF (YEAR% = 31 OR YEAR% = 102 OR YEAR% = 174 OR YEAR% = 244 OR YEAR% = 315 OR YEAR% = 386 OR YEAR% = 457 OR YEAR% = 528 OR YEAR% = 599) THEN
       MM = 3 : HH = 1
    ELSEIF (YEAR% = 32 OR YEAR% = 103 OR YEAR% = 175 OR YEAR% = 245 OR YEAR% = 316 OR YEAR% = 387 OR YEAR% = 458 OR YEAR% = 529 OR YEAR% = 600) THEN
       MM = 57 : HH = 0
    ELSEIF (YEAR% = 33 OR YEAR% = 104 OR YEAR% = 176 OR YEAR% = 246 OR YEAR% = 317 OR YEAR% = 388 OR YEAR% = 459 OR YEAR% = 530) THEN
       MM = 51 : HH = 23
    ELSEIF (YEAR% = 34 OR YEAR% = 105 OR YEAR% = 177 OR YEAR% = 247 OR YEAR% = 318 OR YEAR% = 389 OR YEAR% = 460 OR YEAR% = 531) THEN
       MM = 45 : HH = 22
    ELSEIF (YEAR% = 35 OR YEAR% = 106 OR YEAR% = 178 OR YEAR% = 248 OR YEAR% = 319 OR YEAR% = 390 OR YEAR% = 461 OR YEAR% = 531) THEN
       MM = 39 : HH = 21
    ELSEIF (YEAR% = 36 OR YEAR% = 107 OR YEAR% = 179 OR YEAR% = 249 OR YEAR% = 320 OR YEAR% = 391 OR YEAR% = 462 OR YEAR% = 532) THEN
       MM = 33 : HH = 20
    ELSEIF (YEAR% = 37 OR YEAR% = 108 OR YEAR% = 180 OR YEAR% = 250 OR YEAR% = 321 OR YEAR% = 392 OR YEAR% = 463 OR YEAR% = 533) THEN
       MM = 27 : HH = 19
    ELSEIF (YEAR% = 38 OR YEAR% = 109 OR YEAR% = 181 OR YEAR% = 251 OR YEAR% = 322 OR YEAR% = 393 OR YEAR% = 464 OR YEAR% = 534) THEN
       MM = 21 : HH = 18
    ELSEIF (YEAR% = 39 OR YEAR% = 110 OR YEAR% = 182 OR YEAR% = 252 OR YEAR% = 323 OR YEAR% = 394 OR YEAR% = 465 OR YEAR% = 535) THEN
       MM = 15 : HH = 17
    ELSEIF (YEAR% = 40 OR YEAR% = 111 OR YEAR% = 183 OR YEAR% = 253 OR YEAR% = 324 OR YEAR% = 395 OR YEAR% = 466 OR YEAR% = 536) THEN
       MM = 9 : HH = 16
    ELSEIF (YEAR% = 41 OR YEAR% = 112 OR YEAR% = 184 OR YEAR% = 254 OR YEAR% = 325 OR YEAR% = 396 OR YEAR% = 467 OR YEAR% = 537) THEN
       MM = 3 : HH = 15
    ELSEIF (YEAR% = 42 OR YEAR% = 113 OR YEAR% = 185 OR YEAR% = 255 OR YEAR% = 326 OR YEAR% = 397 OR YEAR% = 468 OR YEAR% = 538) THEN
       MM = 57 : HH = 14
    ELSEIF (YEAR% = 43 OR YEAR% = 114 OR YEAR% = 186 OR YEAR% = 256 OR YEAR% = 327 OR YEAR% = 398 OR YEAR% = 469 OR YEAR% = 539) THEN
       MM = 51 : HH = 13
    ELSEIF (YEAR% = 44 OR YEAR% = 115 OR YEAR% = 187 OR YEAR% = 257 OR YEAR% = 328 OR YEAR% = 399 OR YEAR% = 470 OR YEAR% = 540) THEN
       MM = 45 : HH = 12
    ELSEIF (YEAR% = 45 OR YEAR% = 116 OR YEAR% = 188 OR YEAR% = 258 OR YEAR% = 329 OR YEAR% = 400 OR YEAR% = 471 OR YEAR% = 541) THEN
       MM = 39 : HH = 11
    ELSEIF (YEAR% = 46 OR YEAR% = 117 OR YEAR% = 189 OR YEAR% = 259 OR YEAR% = 330 OR YEAR% = 401 OR YEAR% = 472 OR YEAR% = 542) THEN
       MM = 33 : HH = 10
    ELSEIF (YEAR% = 47 OR YEAR% = 118 OR YEAR% = 190 OR YEAR% = 260 OR YEAR% = 331 OR YEAR% = 402 OR YEAR% = 473 OR YEAR% = 543) THEN
       MM = 27 : HH = 9
    ELSEIF (YEAR% = 48 OR YEAR% = 119 OR YEAR% = 191 OR YEAR% = 261 OR YEAR% = 332 OR YEAR% = 403 OR YEAR% = 474 OR YEAR% = 544) THEN
       MM = 21 : HH = 8
    ELSEIF (YEAR% = 49 OR YEAR% = 120 OR YEAR% = 192 OR YEAR% = 262 OR YEAR% = 333 OR YEAR% = 404 OR YEAR% = 475 OR YEAR% = 545) THEN
       MM = 15 : HH = 7
    ELSEIF (YEAR% = 50 OR YEAR% = 121 OR YEAR% = 193 OR YEAR% = 263 OR YEAR% = 334 OR YEAR% = 405 OR YEAR% = 476 OR YEAR% = 546) THEN
       MM = 9 : HH = 6
    ELSEIF (YEAR% = 51 OR YEAR% = 122 OR YEAR% = 194 OR YEAR% = 264 OR YEAR% = 335 OR YEAR% = 406 OR YEAR% = 477 OR YEAR% = 547) THEN
       MM = 3 : HH = 5
    ELSEIF (YEAR% = 52 OR YEAR% = 123 OR YEAR% = 195 OR YEAR% = 265 OR YEAR% = 336 OR YEAR% = 407 OR YEAR% = 478 OR YEAR% = 548) THEN
       MM = 57 : HH = 4
    ELSEIF (YEAR% = 53 OR YEAR% = 124 OR YEAR% = 196 OR YEAR% = 266 OR YEAR% = 337 OR YEAR% = 408 OR YEAR% = 479 OR YEAR% = 549) THEN
       MM = 51 : HH = 3
    ELSEIF (YEAR% = 54 OR YEAR% = 125 OR YEAR% = 197 OR YEAR% = 267 OR YEAR% = 338 OR YEAR% = 409 OR YEAR% = 480 OR YEAR% = 550) THEN
       MM = 45 : HH = 2
    ELSEIF (YEAR% = 55 OR YEAR% = 126 OR YEAR% = 198 OR YEAR% = 268 OR YEAR% = 339 OR YEAR% = 410 OR YEAR% = 481 OR YEAR% = 551) THEN
       MM = 39 : HH = 1
    ELSEIF (YEAR% = 56 OR YEAR% = 127 OR YEAR% = 199 OR YEAR% = 269 OR YEAR% = 340 OR YEAR% = 411 OR YEAR% = 482 OR YEAR% = 552) THEN
       MM = 33 : HH = 0
    ELSEIF (YEAR% = 57 OR YEAR% = 128 OR YEAR% = 200 OR YEAR% = 270 OR YEAR% = 341 OR YEAR% = 412 OR YEAR% = 483 OR YEAR% = 553) THEN
       MM = 27 : HH = 23
    ELSEIF (YEAR% = 58 OR YEAR% = 129 OR YEAR% = 201 OR YEAR% = 271 OR YEAR% = 342 OR YEAR% = 413 OR YEAR% = 484 OR YEAR% = 554) THEN
       MM = 21 : HH = 22
    ELSEIF (YEAR% = 59 OR YEAR% = 130 OR YEAR% = 202 OR YEAR% = 272 OR YEAR% = 343 OR YEAR% = 414 OR YEAR% = 485 OR YEAR% = 555) THEN
       MM = 15 : HH = 21
    ELSEIF (YEAR% = 60 OR YEAR% = 131 OR YEAR% = 203 OR YEAR% = 273 OR YEAR% = 344 OR YEAR% = 415 OR YEAR% = 486 OR YEAR% = 556) THEN
       MM = 9 : HH = 20
    ELSEIF (YEAR% = 61 OR YEAR% = 132 OR YEAR% = 204 OR YEAR% = 274 OR YEAR% = 345 OR YEAR% = 416 OR YEAR% = 487 OR YEAR% = 557) THEN
       MM = 3 : HH = 19
    ELSEIF (YEAR% = 62 OR YEAR% = 133 OR YEAR% = 205 OR YEAR% = 275 OR YEAR% = 346 OR YEAR% = 417 OR YEAR% = 488 OR YEAR% = 558) THEN
       MM = 57 : HH = 18
    ELSEIF (YEAR% = 63 OR YEAR% = 134 OR YEAR% = 206 OR YEAR% = 276 OR YEAR% = 347 OR YEAR% = 418 OR YEAR% = 489 OR YEAR% = 559) THEN
       MM = 51 : HH = 17
    ELSEIF (YEAR% = 64 OR YEAR% = 135 OR YEAR% = 207 OR YEAR% = 277 OR YEAR% = 348 OR YEAR% = 419 OR YEAR% = 490 OR YEAR% = 560) THEN
       MM = 45 : HH = 16
    ELSEIF (YEAR% = 65 OR YEAR% = 136 OR YEAR% = 208 OR YEAR% = 278 OR YEAR% = 349 OR YEAR% = 420 OR YEAR% = 491 OR YEAR% = 561) THEN
       MM = 39 : HH = 15
    ELSEIF (YEAR% = 66 OR YEAR% = 137 OR YEAR% = 209 OR YEAR% = 279 OR YEAR% = 350 OR YEAR% = 421 OR YEAR% = 492 OR YEAR% = 562) THEN
       MM = 33 : HH = 14
    ELSEIF (YEAR% = 67 OR YEAR% = 138 OR YEAR% = 210 OR YEAR% = 280 OR YEAR% = 351 OR YEAR% = 422 OR YEAR% = 493 OR YEAR% = 563) THEN
       MM = 27 : HH = 13
    ELSEIF (YEAR% = 68 OR YEAR% = 139 OR YEAR% = 211 OR YEAR% = 281 OR YEAR% = 352 OR YEAR% = 423 OR YEAR% = 494 OR YEAR% = 564) THEN
       MM = 21 : HH = 12
    END IF
‘
111   FOR AZS = 1 TO 366
 GOSUB Moonriseset
   Mnhr1%(AZS) = HH : Mnmn1%(AZS) = MM
 HH = HH + 10 : MM = MM + 5 : GOSUB Moonriseset
   Mnhr2%(AZS) = HH : Mnmn2%(AZS) = MM
 MM = MM + 6 : HH = HH + 15
      NEXT AZS
   END IF
   YR1% = YEAR%

GOTO METRIC

Moonriseset:
‘ IF MM >= 60 THEN HH = HH + 1 : MM = MM – 60 END IF IF HH >= 24 THEN HH = HH – 24 RETURN

TIMECLOCK: PRINT : PRINT TAB;TWN$;” , “;CNTRY$;” / “;DNGN$;” in the year “;YEAR%’;” Age “;AGE% PRINT : PRINT TAB;“Clock time =”;MNTH%;”/”;MND%;”(“;YRD%;”) time =”;HR%;”:”;MIN%;”::”;SCND% PRINT : PRINT “Elapsed time =”;ZF%;” years “;ZE%;” months “;ZD%;” days” PRINT : PRINT ZC%;” hours “;ZB%;” minutes “;ZA%;” seconds” : PRINT
RETURN

‘ Game clock
100 CLS PRINT : PRINT “ Game time” : PRINT PRINT “ 1. Seconds 2. Minutes 3. Hours” PRINT PRINT “ 4. Days 5. Months 6. Years” PRINT PRINT “ 7. No time after all” : PRINT
INPUT ZZ% IF ZZ% < 1 OR ZZ% > 7 GOTO 100 ON ZZ% GOTO 150,200,250,300,350,400,METRIC

150 CLS : INPUT “ Seconds input (0 thru 120) ? “,ZG% ZA% = ZA% + ZG% : SCND% = SCND% + ZG% : GOTO 500
200 CLS : INPUT “ Minutes input (0 thru 120) ? “,ZH% ZB% = ZB% + ZH% : MIN% = MIN% + ZH% : GOTO 500
250 CLS : INPUT “ Hours input (0 thru 48) ? “,ZI% ZC% = ZC% + ZI% : HR% = HR% + ZI% : GOTO 500
300 CLS : INPUT “ Days input (0 thru 60) ? “,ZJ% ZD% = ZD% + ZJ% : MND% = MND% + ZJ% : YRD% = YRD% + ZJ% : GOTO 500
350 CLS : INPUT “ Months input (0 thru 24) ? “,ZK% ZE% = ZE% + ZK% : MNTH% = MNTH% + ZK% : YRD% = YRD% + ZK% * 30 : GOTO 500
400 CLS : INPUT “ Years input (0 thru 50) ? “,ZL% ZF% = ZF% + ZL% : YEAR% = YEAR% + ZL%

500
‘ elapsed seconds

FOR GGG = 1 TO ZA%/60 IF ZA% >= 60 THEN ZB% = ZB% + 1 ZA% = ZA% – 60 END IF
NEXT GGG

‘ clock seconds

FOR GGG = 1 TO SCND%/60 IF SCND% >= 60 THEN MIN% = MIN% + 1 SCND% = SCND% – 60 END IF
NEXT GGG

‘ elapsed minutes

FOR GGG = 1 TO ZB%/60 IF ZB% >= 60 THEN ZC% = ZC% + 1 ZB% = ZB%- 60 END IF
NEXT GGG

‘ clock minutes

FOR GGG = 1 TO MIN%/60 IF MIN% >= 60 THEN HR% = HR% + 1 MIN% = MIN% – 60 END IF
NEXT GGG

‘ elapsed hours

FOR GGG = 1 TO ZC%/24 IF ZC% >= 24 THEN ZD% = ZD% + 1 ZC% = ZC% – 24 END IF
NEXT GGG

‘ clock hours

FOR GGG = 1 TO HR%/24 IF HR% >= 24 THEN MND% = MND% + 1 YRD% = YRD% + 1 HR% = HR% – 24 END IF
NEXT GGG

550
‘ elapsed days

FOR GGG = 1 TO ZD%/30 IF HR% > 30 THEN ZE% = ZE% + 1 ZD% = ZD% – 30 END IF
NEXT GGG

‘ clock days
FOR GGG = 1 TO MND%/30 IF MND% > 30 THEN MNTH% = MNTH% + 1 MND% = MND% – 30 END IF
NEXT GGG

‘ elapsed months
FOR GGG = 1 TO ZE%/12 IF ZE% > 12 THEN ZF% = ZF% + 1 ZE% = ZE% – 12 END IF
NEXT GGG

‘ clock months
FOR GGG = 1 TO MNTH%/12 IF MNTH% > 12 THEN YEAR% = YEAR% + 1 MNTH% = MNTH% – 12 END IF
NEXT GGG

IF YRD% >= 184 AND YRD% <= 363 AND ABONUS% = 0 THEN ABONUS% = 1 : MND% = MND% + 3
ELSEIF YRD% >= 364 AND YRD% <= 366 AND BBONUS% = 0 THEN BBONUS% = 1 : MND% = MND% + 3
END IF

IF YRD% >= 1 AND YRD% <= 30 THEN MNTH% = 1
IF YRD% >= 31 AND YRD% <= 60 THEN MNTH% = 2
IF YRD% >= 61 AND YRD% <= 90 THEN MNTH% = 3
IF YRD% >= 91 AND YRD% <= 120 THEN MNTH% = 4
IF YRD% >= 121 AND YRD% <= 150 THEN MNTH% = 5
IF YRD% >= 151 AND YRD% <= 180 THEN MNTH% = 6
IF YRD% >= 184 AND YRD% <= 213 THEN MNTH% = 7
IF YRD% >= 214 AND YRD% <= 243 THEN MNTH% = 8
IF YRD% >= 244 AND YRD% <= 270 THEN MNTH% = 9
IF YRD% >= 274 AND YRD% <= 303 THEN MNTH% = 10
IF YRD% >= 304 AND YRD% <= 333 THEN MNTH% = 11
IF YRD% >= 334 AND YRD% <= 363 THEN MNTH% = 12

IF YRD% > 366 THEN YRD% = YRD% – 366 : YEAR% = YEAR% + 1
END IF

IF YEAR% > YR2% THEN YRD% = YRD% – 366
RETURN

‘ Main menu
METRIC:

IF YR1% <> YEAR% THEN Moon

CLS :PRINT ,,” It’s game time folks !” : PRINT : PRINT TWN$;” ; “;CNTRY$ ,DNGN$;”(dungeon) Year “;YEAR%;” Age”;AGE% : PRINT
‘ IF HR% <= 12 THEN IF (YRD% > 0 AND YRD% < 181 OR YRD% > 183 AND YRD% < 364) THEN PRINT “CLOCK Date=”,MNTH%;”/”;MND%;”(“;YRD%;”) time=”;HR%”:“MIN%”::“SCND%; ELSEIF YRD% >= 181 AND YRD% <= 183 THEN PRINT “CLOCK Date= Lithe /(“;YRD%;”) time=”;HR%;”:”;MIN%;”::”;SCND%; ELSEIF YRD% >= 364 AND YRD% <= 366 THEN PRINT “CLOCK Date= Yule /(“;YRD%;”) time=”;HR%;”:”;MIN%;”::”;SCND%; END IF END IF
‘ IF HR% > 12 THEN IF (YRD% > 0 AND YRD% < 181 OR YRD% > 183 AND YRD% < 364) THEN PRINT “CLOCK Date= “,MNTH%”/“MND%;”(“;YRD%;”) time=”;HR%-12”:“MIN%”::“SCND%; ELSEIF YRD% >= 181 AND YRD% <= 183 THEN PRINT “CLOCK Date= Lithe /(“;YRD%;”) time= “;HR%-12;”:”;MIN%;”::”;SCND%; ELSEIF YRD% >= 364 AND YRD% <= 366 THEN PRINT “CLOCK Date= Yule /(“;YRD%;”) time= “;HR%-12;”:”;MIN%;”::”;SCND%; END IF END IF

IF HR% < 12 THEN PRINT ACK$
ELSE PRINT PCK$
END IF
LINE (0,43)-(639,45),2,BF

PRINT : PRINT “ELAPSED time”,ZF%;“year[s]”,ZE%;“month[s]”,ZD%;“day[s]”
PRINT : PRINT ZC%;“hour[s]”,ZB%;“minute[s]”,ZA%;“second[s]”
LINE (0,73)-(639,75),3,BF
PRINT : PRINT “Moon “;Mnhr1%(YRD%);”:”;Mnmn1%(YRD%); IF Mnhr1%(YRD%) < 12 THEN PRINT ACK$; IF Mnhr1%(YRD%) >= 12 THEN PRINT PCK$;
PRINT W$;Mnhr2%(YRD%);”:“Mnmn2%(YRD%); IF Mnhr2%(YRD%) < 12 THEN PRINT ACK$; IF Mnhr2%(YRD%) >= 12 THEN PRINT PCK$;
PRINT X$ : PRINT
PRINT “SUN “;Sunrise$(YRD%);ACK$;W$;Sunset$(YRD%);PCK$;X$ : PRINT
PRINT , “ Select a number, type it, and press

PRINT : PRINT “1. Dice Generator 2. To hit tables”

PRINT : PRINT “3. Missile fire to hit table 4. Timer input ? “

PRINT : INPUT “5. Quit “,B%
‘ IF (B% < 1 OR B% > 5) GOTO METRIC
‘ IF B% = 5 THEN END
‘ ON B% GOSUB 50,HITTABLES,MISSILE,100
GOTO METRIC

‘ Dice Program
50 RANDOMIZE TIMER CLS : C# = 0 : CB# = 0 : GG& = 0 PRINTDICE GENERTOR [Maximum number of sides is 1 million]” PRINT ,,” [ (1 × 10+6) minimum is 0 ].” PRINT : PRINTHOW MANY SIDES?” INPUT AR#
‘ IF AR# > 1000000# THEN PRINT “ Too many sides. 1 million maximum.” FOR k = 1 TO 32765 : NEXT k END IF
‘ IF AR# > 1000000# GOTO 50 PRINT : INPUT “ Number of Dice ? “,BE# PRINT : INPUT “ Adds per die ? “,APD# PRINT : INPUT “ Adds for all dice ? “,AFAD# CLS : PRINT
WHILE (C# <> BE# OR C# < BE#) H# = INT + 1 + APD# PRINT H#;”+”; GG& = GG& + 1

‘ what follows are print statements to determine the
‘ quantity of numbers printed per screen line
‘ IF (GG& >= 19 AND AR# >= 1 AND AR# < 10) THEN PRINT : PRINT : GG& = 0 END IF
‘ IF (GG& >= 15 AND AR# >= 10 AND AR# < 100) THEN PRINT : PRINT : GG& = 0 END IF
‘ IF (GG& >= 12 AND AR# >= 100 AND AR# < 1000) THEN PRINT : PRINT : GG& = 0 END IF
‘ IF (GG& >= 10 AND AR# >= 1000 AND AR# < 10000) THEN PRINT : PRINT : GG& = 0 END IF
‘ IF (GG& >= 9 AND AR# >= 10000 AND AR# < 100000#) THEN PRINT : PRINT : GG& = 0 END IF
‘ IF (GG& >= 9 AND AR# >= 100000# AND AR# < 1000000# ) THEN PRINT : PRINT : GG& = 0 END IF

‘ IF (GG& >= 7 AND AR# = 1000000#) THEN IF (GG& >= 8 AND AR# = 1000000#) THEN PRINT : PRINT : GG& = 0 END IF
‘ C# = C# +1# : CB# = CB# + H# WEND
‘ CB# = CB# + AFAD# : PRINT
PRINT “ Total Roll =”;CB#;” ON “;BE#;“d”;AR# : PRINT PRINT “+”;APD#;” adds per die +”;AFAD#;” add for all dice” : PRINT

PRINT “ half of total = “;CB#/2;” 1/4 of total = “;CB#/4; “ 1/8 of total = “;CB#/8 INPUT “ Finished with the dice generator (y/n)? “,A$ IF UCASE$(A$) = “YES” OR UCASE$(A$) = “Y” THEN RETURN GOTO 50 ‘ MISSILETOHIT: PRINT : INPUT “Attacking what armor class (10 thru -15)? “,D% PRINT : INPUT “What table number (1 thru 16)? “,F% ‘ IF (F% < 1 OR F% > 16) THEN CLS : PRINT “There are only 16 combat tables ! Please try again !” : FOR ZZZ = 1 TO 32765 : NEXT ZZZ END IF ‘ IF (F% < 1 OR F% > 16) GOTO HITTABLES ‘ ON F% GOSUB TABLEA,TABLEB,TABLEC,TABLED,TABLEE,TABLEF,TABLEG,TABLEH,TABLEI,TABLEJ,TABLEK,TABLEL,TABLEM,TABLEN,TABLEP,TABLEQ RETURN ‘ ‘ Missile fire adds MISSILE: CLS : PRINT : PRINT “Missile fire adds (with automatic GOTO -> the hit tables)” : PRINT PRINT “ENTER NUMBERS ONLY ! Positive numbers should NOT use the plus sign !” : PRINT INPUT “ d20 roll (no adds; 1 thru 20) ? “,E% : PRINT INPUT “ Strength adds (-3 thru +6) ? “,ST% : PRINT INPUT “ Dexterity adds (-3 thru +3) ? “,DX% : PRINT INPUT “ Magic weapon adds (-3 thru +6) ? “,MW% : PRINT INPUT “ Magic arrows/bolts adds (-3 thru +6) ? “,MA% : PRINT INPUT “ Range adds (0 = short, -2 = medium, -5 = long) ? “,RG% : PRINT INPUT “ Wind adds (-6 thru 0) ? “,WND% : PRINT INPUT “ Firer movement adds (-5 thru +1) ? “,FMV% : PRINT INPUT “ Target movement adds (-5 thru 0) ? “,TMV% : PRINT INPUT “ Specialization add (0,+1,+3) ? “,SP% : PRINT INPUT “ Miscellaneous magic item add (Bracers of Archery,etc.) ? “,MMI% : PRINT INPUT “ Temperature add (-4 thru 0) ? “,TEMP% : PRINT E% = E% + ST% + DX% + MW% + RG% + WND% + FMV% + TMV% + MA% + SP% + MMI% + TEMP% GOSUB MISSILETOHIT RETURN ‘ ‘ Hit tables HITTABLES: CLSPRINT : PRINT ,,“Combat To hit tables.” PRINT : INPUT “What d20 roll was made ? “,E% PRINT : INPUT “Strength adds to the d20 ? (-3 thru +6) “, STRADDS% ‘ PRINT : INPUT “Dexterity Adds ? (-3 thru +6) “, DEXADDS% PRINT : INPUT “ Magic Weapon Adds ? (-3 thru +6) “, WEPADDS% PRINT : INPUT “ Specialization add ? “,SP% : PRINT PRINT : INPUT “ Special adds [ gnome vs. kobold, etc. ] “, SPECADDS% ‘ ‘ E% = E% + STRADDS% + DEXADDS% + WEPADDS% + SP% + SPECADDS% E% = E% + STRADDS% + WEPADDS% + SP% + SPECADDS% ‘ GOSUB MISSILETOHITHITORMISS: CLS : PRINT ‘ IF E% >= Z% THEN BEEP : BEEP : BEEP : PRINT, “hit !” ELSE PRINT ,“no hit .” END IF ‘ PRINT : PRINT “ to hit needed = “;Z%;” / actual d20 with adds = “;E%;” /.” PRINT : PRINT “ AC attacked = “;D%;” / TABLE used = “;F%;” / adds = “;ADDS%;” /” PRINT : PRINT need: PRINT “If you need more to hit, input Y; if you need the Menu, input N.” PRINT : INPUT A$ ‘ IF UCASE$(A$) = “Y” GOTO HITTABLES ‘ IF UCASE$(A$) = “N” THEN RETURN GOTO need ‘

‘ hit table data removed

GOTO HITORMISSEND

Author
Categories Game Aids


Privacy policy: I track IP addresses and pages looked at out of a vague curiosity to learn what pages are looked at on my site. After a set period, this information is deleted. No personal information is permanently kept.


[ Copyright © by Jim, 1980-2050. All Rights Reserved. ]

[ Except where noted, and where copyrights are held by others. ]