home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Commodore Disk User Volume 1 #1
/
Commodore_Disk_User_Vol.1_1_1987_-.d64
/
mobster
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-10-26
|
9KB
|
321 lines
900 if a=0 then a=1:load "mobster.mc",8,1
1000 dimjo(3,4):gosub1280
1010 a$(1)="protection racket":a$(2)="drugs ring":a$(3)="operation"
1020 a$(4)="head quarters":sys16656:print"[159]<fire>":b$="[159]<fire>"
1030 gosub2960:da=0:ho=3:ca=1:mo=500:sh=3:sg=0:mm=5
1040 hh=0:cc=0:ss=0:gg=0:he=15:wa=20
1050 ifx>24andx<36thengoto1600
1060 sys16835:goto1600
1070 print"[154][146][192][193][193][193][193][193][193][193][193][193][193][193][194][192][193][193][193][193][193][193][193][193][193][194][192][193][193][193][193][193][193][193][193][193][193][193][194]"
1080 print"[195]view orders[196][195]view jobs[196][195]information[196]"
1090 print"[197][198][198][198][198][198][198][198][198][198][198][198][199][197][198][198][198][198][198][198][198][198][198][199][197][198][198][198][198][198][198][198][198][198][198][198][199]":return
1100 sys16835:gosub1070
1110 print"[159]information:-"
1120 print"@@@@@@@@@@@@@[154]"
1130 print"current wealth","$";mo
1140 print"wage per hood","$";wa
1150 print"gangs morale"," ";int(mm)
1160 print"drug supply"," ";he
1170 print"gang members"," ";ho+hh
1180 print"limousines"," ";ca+cc
1190 print"submachine guns"," ";sg+gg
1200 print"shotguns "," ";sh+ss
1210 print"[159][146]"
1220 print"item ","at h.q.","on job"
1230 print"@@@@ ","@@@@@@@","@@@@@@[154]"
1240 print"submachine guns",sg,gg
1250 print"shotguns ",sh,ss
1260 print"gang members",ho,hh
1270 print"limousines",ca,cc:return
1280 forx=0to3
1290 jo(x,2)=int(rnd(1)*30)+5
1300 z=int(rnd(1)*3)+1:jo(x,3)=z
1310 z=int(rnd(1)*4)+1:jo(x,4)=z
1320 jo(x,1)=int(rnd(1)*6)+44
1330 p=((jo(x,3)*3)*jo(x,2)*18)
1340 jo(x,0)=int(p):next:return
1350 sys16835:print"[159]view jobs:":print"@@@@@@@@@@[154]":fort=0to3
1360 print"[159]job #";t+1;":-[154]":z=int(rnd(1)*3)+1
1370 ifz=1thenprint"take out a";
1380 ifz=2thenprint"take control of a";
1390 ifz=3thenprint"finish off a";
1400 ifjo(t,2)<12thenprint" small";:goto1440
1410 ifjo(t,2)<20thenprint" minor";:goto1440
1420 ifjo(t,2)<30thenprint" large";:goto1440
1430 print" major";
1440 ifjo(t,3)=3thenprint" mafia"
1450 ifjo(t,3)=2thenprint" police"
1460 ifjo(t,3)=1thenprint" civilian"
1470 printa$(jo(t,4));" on";jo(t,1);"th street"
1480 print"for $";jo(t,0)
1490 nextt:print:printb$:gosub2960:return
1500 sys16835:print"[159]view orders :-[154]"
1510 print"take job #1":print"take job #2":print"take job #3"
1520 print"take job #4"
1530 print"wait a turn"
1540 print"buy an item"
1550 print"push drugs"
1560 print"use drugs"
1570 print"adjust wage"
1580 print" quit game "
1590 print"main menu":return
1600 gosub1100
1610 mm=mm*10:mm=int(mm):mm=mm/10
1620 sys 16865
1630 sys 16925
1640 x=peek(679):y=peek(680)
1650 ify<>1then1630
1660 ifx>0andx<12thengoto1690
1670 ifx>13andx<23thengosub1350:goto1600
1680 ifx>24andx<36thengoto1600
1690 gosub1500
1700 sys16865
1710 sys16925:x=peek(679):y=peek(680)
1720 ifx>10thengoto1710
1730 ify=22thengoto1600
1740 ify=20thenclr:goto1000
1750 ify=18thengoto1860
1760 ify=16thengoto2220
1770 ify=14thengoto2280
1780 ify=12thengoto2360
1790 ify=10thengoto1850
1800 ify=08thenv=3:goto2580
1810 ify=06thenv=2:goto2580
1820 ify=04thenv=1:goto2580
1830 ify=02thenv=0:goto2580
1840 goto1710
1850 ho=ho+hh:hh=0:ca=ca+cc:cc=0:sh=sh+ss:ss=0:sg=sg+gg:gg=0:goto1910
1860 sys16835:print"[159][147]you have";ho+hh;"gang members."
1870 print"you have $";mo;"."
1880 print"input the wage per gang member":print"$ ";
1890 x1=0:x2=9999:gosub2820:aa=va
1900 mx=(wa-aa):wa=aa:goto1600
1910 h1=ho:mm=mm-mx:ifmm<3thenho=ho-1
1920 ifmm<2thenho=ho-1
1930 ifmm<1thenho=ho-2
1940 ifho<0thenho=0
1950 da=da+1:gosub1280:sys16835
1960 print"[159]day";da:print"@@@@@@@[154]"
1970 print"previous wealth",mo
1980 print"total wages",wa*(ho+hh)
1990 mo=mo-(wa*(ho+hh))
2000 if(ho+hh)>0thengoto2020
2010 print"no men left !":goto2070
2020 ifmo<0thengoto2050
2030 ifmm>10thenmm=10
2040 print"current wealth",mo:goto2080
2050 print"current wealth",0
2060 print"the gang got no wages this turn, so theyfilled you with lead."
2070 goto2170
2080 xy=0.1*da:ifxy>0.4thenxy=0.4
2090 mm=mm-xy:a$="morale is high.":ifmm<7thena$=""
2100 ifmm<4thena$="morale is low."
2110 ifmm<3thena$="the gang is angry."
2120 ifmm<2thena$="the gang is very angry."
2130 ifmm<1thena$=""
2140 print"";a$
2150 ifmm>=1thengoto2180
2160 print"morale was so low, the gang shot you."
2170 printtab(15)"[159]game over.":goto2200
2180 printb$
2190 mx=0:gosub2960:goto1600
2200 printb$
2210 gosub2960:clr:goto1000
2220 sys 16835:print"[159]use drugs :-[154]":print"@@@@@@@@@@@@@@"
2230 print"you have";he;" drugs."
2240 print"you have";ho+hh;" members."
2250 print"how much will you use.":x1=0:x2=he:print"";:gosub2820
2260 h1=va:he=he-h1:m2=(h1/(ho+hh)):ifm2<1thenm2=1
2270 mx=mx-m2:goto1850
2280 sys16835:print"[159]push drugs :":print"@@@@@@@@@@@@@[154]"
2290 print"you have";he;" drugs."
2300 print"how much will you push.":x1=0:x2=he:print"";:gosub2820
2310 h2=va:he=he-h2
2320 h3=40+int(rnd(1)*20)+1:print
2330 print"you gained $";h3;" per go.":pr=(h2*h3)
2340 print"so you made $";pr;"cash.":mo=mo+pr
2350 print"you now have $";mo:printb$:gosub2960:goto1850
2360 print"[147][159]buy item :-":print"@@@@@@@@@@@[154]":sys16865
2370 print"you have $";mo:print"select item"
2380 print"drugs (approx. $ 60)"
2390 print"shotgun (approx. $1000)"
2400 print"submachine gun (approx. $4000)"
2410 print"limousine (approx. $9000)"
2420 print" *** return to main menu. ***":sys16925:x=peek(679):y=peek(680)
2430 ifx>29thengoto2360
2440 ify=15thengoto1600
2450 ify<>7andy<>9andy<>11andy<>13then2360
2460 print"[159]how many >[154] ";:x1=0:x2=9999:gosub2820:h1=va
2470 ify=7thenpr=60
2480 ify=9thenpr=1000
2490 ify=11thenpr=4000
2500 ify=13thenpr=9000
2510 pp=(pr/10):pr=pr-pp:pp=pp*2:pr=pr+int(rnd(1)*pp)+1:pr=int(pr):pr=pr*h1
2520 ifpr>mothenprint"[159]can't afford it.":printb$:gosub2960:goto2360
2530 mo=mo-pr:ify=7thenhe=he+h1
2540 ify=9thensh=sh+h1
2550 ify=11thensg=sg+h1
2560 ify=13thenca=ca+h1
2570 goto1850
2580 sys16835:nn=0:n3=0:n4=0
2590 print"[159]you have opted to undertake job";v+1
2600 print"for the fee of $";jo(v,0)
2610 print"[154]shotguns ";sh
2620 print"submachine guns ";sg
2630 print"gang members ";ho
2640 print"limousines ";ca
2650 print"[159]how many limos ";
2660 x1=0:x2=ca:gosub2820:y1=va
2670 print"[159]how many members ";
2680 x1=0:x2=ca*6:ifho<x2thenx2=ho
2690 gosub2820:y2=va
2700 print"[159]how many shotguns ";
2710 x1=0:x2=sh:ify2<shthenx2=y2
2720 gosub2820:y3=va
2730 print"[159]how many machine guns ";
2740 x1=0:x2=(y2-y3):ifsg<x2thenx2=sg
2750 gosub2820:y4=va
2760 r1=y1:r2=y2:r3=y3:r4=y4:r5=mm
2770 ca=ca-y1:ho=ho-y2:sh=sh-y3:sg=sg-y4:sp=jo(v,3):no=jo(v,2)
2780 ifsp=3thensp=14
2790 ifsp=2thensp=20
2800 ifsp=1thensp=30
2810 poke722,no:goto2990
2820 va=0
2830 va$=str$(va):va$=right$(va$,len(va$)-1):ifva$=""thenva$="0"
2840 iflen(va$)<4thenva$=" "+va$:goto2840
2850 print"[157][157][157][157]";va$;
2860 in=peek(56320):di=(inand15):fi=(inand16):iffi=0then2930
2870 ifdi=11thenva=va-1:goto2900
2880 ifdi=7thenva=va+1:goto2900
2890 goto2860
2900 ifva<x1thenva=x1
2910 ifva>x2thenva=x2
2920 goto2830
2930 print
2940 if(peek(56320)and16)=0then2940
2950 return
2960 if(peek(56320)and16)=16then2960
2970 if(peek(56320)and16)=0then2970
2980 return
2990 sys16835:print"[147][159][146]"
3000 print"shoot out :":print"@@@@@@@@@@@":print"[154]you sent in :[154]"
3010 printy1;"limousines,"
3020 printy2;"gang members,"
3030 printy3;"shotguns, and"
3040 printy4;"submachine guns."
3050 print"[159]you now have :[154]"
3060 printr2;"gang members,"
3070 printr3;"shotguns, and"
3080 printr4;"submachine guns."
3090 print"snipers shot :";nn
3100 print"[154][192][193][193][193][193][193][193][193][193][194][192][193][193][193][193][193][193][193][193][193][194]"
3110 print"[195] [196][195] [196]"
3120 print"[195] [159]attack[154] [196][195] [159]retreat[154] [196]"
3130 print"[195] [196][195] [196]"
3140 print"[197][198][198][198][198][198][198][198][198][199][197][198][198][198][198][198][198][198][198][198][199]":sys16865
3150 sys16925:x=peek(679):y=peek(680)
3160 ify=0ory>3then3150
3170 ifx>0andx<9thengoto3200
3180 ifx>10andx<20thengoto4140
3190 goto3150
3200 ifr4=0andr3=0then4160
3210 ifr2=0then4170
3220 ifr4=0thenn1=0:r3=r3-1:goto3380
3230 ifr3=0thenn1=255:r4=r4-1:goto3380
3240 print"[147][154][192][193][193][193][193][193][193][193][193][193][193][193][193][193][193][193][193][194]"
3250 print"[195] [196]"
3260 print"[195] [159] shotgun or [154] [196]"
3270 print"[195] [196]"
3280 print"[195] [159]submachine gun[154] [196]"
3290 print"[195] [196]"
3300 print"[197][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][199]"
3310 sys16865
3320 sys16925:x=peek(679):y=peek(680)
3330 ify=2andx>3andx<11thengoto3360
3340 ify=4andx>1andx<16thengoto3370
3350 goto3320
3360 n1=0:r3=r3-1:goto3380
3370 n1=255:r4=r4-1
3380 print"[147]":poke717,n1:r2=r2-1
3390 poke707,0:poke688,255:poke687,3:poke709,sp
3400 poke702,1:poke703,0:poke708,255:poke716,0
3410 ifn1=0thenpoke723,30
3420 ifn1=255thenpoke723,250
3430 poke725,sp:poke728,50:poke689,200+(mm*4)
3440 sys16656:sys17165:sys17390:sys18420:sys19600:sys18890
3450 n2=peek(716):nn=no-peek(722)
3460 ifnn<0thennn=0
3470 ifn2<>01thengoto3600
3480 print"aaaargh !!!"
3490 poke53281,0:poke53282,11:poke53283,12:poke53269,0:fort=1to100:nextt
3500 gosub2960:sys16835:print"[147][154]"
3510 print"your hood was shot by an enemy sniper."
3520 print"he was carrying a ";
3530 ifn1=0thenprint"shotgun";
3540 ifn1=255thenprint"submachine gun";
3550 print",":print"which is beyond recovery."
3560 print"this reduced morale."
3570 ifn1=0theny6=y6+.75:n4=n4+1
3580 ifn1=255theny6=y6+1.25:n3=n3+1
3590 printb$:gosub2960:goto2990
3600 ifn2<>02thengoto3700
3610 sys16835:print"[147][154][146]"
3620 print"your man ran out of ammo, and was shot"
3630 print"by an enemy sniper."
3640 print"his weapon is in the open, so you can't recover it."
3650 print"this isn't gonna improve morale !"
3660 print:printb$
3670 ifn1=0theny6=y6+.75:n4=n4+1
3680 ifn1=255theny6=y6+1.25:n3=n3+1
3690 fort=1to200:nextt:gosub2960:goto2990
3700 sys16835:print"[147][154][146]"
3710 print"well done, the defending snipers have high-tailed it out of ";
3720 print"there !"
3730 print"you collect your pay of $";jo(v,0);"and":print"split."
3740 mo=mo+jo(v,0):y5=y5+(nn*0.2):n5=int(no/10)
3750 ifn1=0thenr3=r3+1
3760 ifn1=255thenr4=r4+1
3770 r2=r2+1
3780 x=int(rnd(1)*10)+1
3790 ifx<4thengoto4030
3800 onjo(v,4)goto3820,3850,3890,3980
3810 goto4030
3820 x=(int(rnd(1)*70)+1)*jo(v,3):x=x*6
3830 print"we also managed to bust the safe, and found $";x;"!"
3840 mo=mo+x:y5=y5+int(x/550):goto4030
3850 x=jo(v,2):x=int(y*0.5)
3870 print"on the way out, we spotted their stash of";x;"drugs,which we took."
3880 he=he+x:y5=y5+int(x/7):goto4030
3890 rb=(jo(v,3)*jo(v,2)):rb=int(rb/11)
3895 x=int(rnd(1)*rb):r3=r3+x:y5=y5+x*0.5
3900 y=int(rnd(1)*rb/2):r4=r4+y:y5=y5+y*1
3910 ifx=0andy=0thengoto4030
3920 print"we also recovered";
3930 ifx=0thengotoprinty;:goto3970
3940 printx;"shotguns";
3950 ify=0thenprint".":goto4030
3960 print" and":printy;
3970 print"submachine guns.":goto4030
3980 x=int(rnd(1)*(jo(v,2)/7))+2
3990 print"we also found";x;"hoods, who decided"
4000 print"they would rather join our gang than"
4010 print"have their heads blown off.":print"a wise decision !"
4020 r2=r2+x:y5=y5+(x*0.25)
4030 printb$:gosub2960
4040 ifr2=>r1thenpq=1:goto4100
4050 ifr2=>r1thenn5=r1:pq=0:goto4100
4060 print"there weren't enough men to drive all":print"the limos.":n5=r1
4070 ifn5=<r2thengoto4090
4080 n5=n5-1:goto4070
4090 print"we returned with only";n5;", leaving":printr1-n5;"behind.":r1=n5
4100 y6=y6+(r1*2):mm=mm+y5-y6:hh=hh+r2:cc=cc+r1:ss=ss+r3:gg=gg+r4
4110 ifpq=1then1910
4120 printb$:gosub2960:print"[147]"
4130 goto1910
4140 y6=y6+1:print"[147][154]your gang beats a hasty retreat back to"
4150 print"their own turf.":goto4050
4160 print"[147]you don't have enough weapons to fight.":y6=y6+1:goto4050
4170 print"all the gang members you sent have been shot !":y6=y6+1
4180 y6=y6+r1*2:y6=y6+r3=.5:y6=y6+r4:printb$:gosub2960:print"[147]":goto4050