carF.qsrc 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513
  1. # carF
  2. menu_off = 1
  3. $enddrive = {
  4. if cardrive = 1:gt 'street'
  5. if cardrive = 2:gt 'down'
  6. if cardrive = 3:gt 'Nord'
  7. if cardrive = 4:gt 'lake', 'start'
  8. if cardrive = 5:gt 'park', 'start'
  9. if cardrive = 6:gt 'zaprF', 'start'
  10. if cardrive = 7:gt 'autoservisF', 'start'
  11. if cardrive = 8:gt 'autosalonF', 'start'
  12. if cardrive = 9:gt 'autotraidF', 'start'
  13. if cardrive = 10:gt 'park', 'whore'
  14. if cardrive = 11:gt 'sauna'
  15. if cardrive = 12:gt 'obekt'
  16. if cardrive = 13:gt 'dachi'
  17. if cardrive = 14:gt 'liam'
  18. if cardrive = 18:gt 'youplace'
  19. if cardrive = 19:gt 'nordtrain', 'outside'
  20. if cardrive = 20:gt 'pavResidential'
  21. if cardrive = 21:gt 'zaprF','start'
  22. if cardrive = 22:gt 'road'
  23. if cardrive = 23:gt 'gadukino'
  24. if cardrive = 24:gt 'pavCommercial'
  25. if cardrive = 25:gt 'island'
  26. if cardrive = 26:gt 'pavIndustrial'
  27. }
  28. if $ARGS[0] = 'start':
  29. $metka = $ARGS[0]
  30. $loc = $CURLOC
  31. CLOSE ALL
  32. *clr & cla
  33. minut += 1
  34. gs 'stat'
  35. gs 'themes', 'indoors'
  36. '<center><b><<$car>></b></center>'
  37. '<center><img <<$set_imgh>> src="images/shared/accessories/car/car<<car>>.jpg"></center>'
  38. act 'Move away from the car':dynamic $enddrive
  39. if kanistra > 0:
  40. 'In the trunk there is a <<kanistra>>. It contains 5 liters of gasoline.'
  41. if benz <= 35:
  42. act 'Pour gasoline into the tank':
  43. cla
  44. benz += 5
  45. kanistra -= 1
  46. 'You emptied the canister of gasoline in the tank.'
  47. act 'Move away':gt 'carF', 'start'
  48. end
  49. end
  50. end
  51. act 'Get in the car':gt 'carF', 'salon'
  52. end
  53. if $ARGS[0] = 'salon':
  54. $metka = $ARGS[0]
  55. $loc = $CURLOC
  56. *clr & cla
  57. minut += 1
  58. gs 'stat'
  59. '<center><b><<$car>></b></center>'
  60. '<center><img <<$set_imgh>> src="images/shared/accessories/car/salon<<car>>.jpg"></center>'
  61. 'Gasoline - <<benz>> liters, the fuel tank has a capacity of 40 liters.'
  62. if teh <= 0:teh = 0 & wrek = 1
  63. if teh <= 0 or wrek = 1:$teh = 'The car is in need of repairs and won''t start.'
  64. if teh >= tehcar * 75 / 100 and wrek = 0:$teh = 'The car is in excellent condition.'
  65. if teh < tehcar * 75 / 100 and teh >= tehcar * 50 / 100 and wrek = 0:$teh = 'While driving, you occasionally hear some troubling noises'
  66. if teh < tehcar * 50 / 100 and teh >= tehcar * 25 / 100 and wrek = 0:$teh = 'The car seems broken and barely drives.'
  67. if teh < tehcar * 25 / 100 and wrek = 0:$teh = 'How this car still runs is a mystery, even to its designers.'
  68. '<<$teh>>'
  69. if cardrive = 1:'Through the windshield, you see the residential area.'
  70. if cardrive = 2:'Through the windshield, you see downtown.'
  71. if cardrive = 3:'Through the windshield, you see the city industrial region.'
  72. if cardrive = 4:'Through the windshield, you see the lake.'
  73. if cardrive = 12:'Through the windshield, you see a construction site.'
  74. if cardrive = 14:'Through the windshield, you see the old town.'
  75. if cardrive = 5:'Through the windshield, you can see the park.'
  76. if cardrive = 19:'Through the windshield, you see the Station.'
  77. if cardrive = 23:'Through the windshield, you see the huts of the village of Gadukino.'
  78. if cardrive = 24:'Through the windshield, you can see the Old Town.'
  79. if cardrive = 25:'You cross one of the bridges that leads to the island.'
  80. if cardrive = 26:'Through the windshield, you can see the Old Town.'
  81. if prava = 0:'You don''t have a driver''s license.'
  82. act 'Get out of the car':dynamic $enddrive
  83. if benz > 0 and wrek = 0 and prava > 0:
  84. if teh >= tehcar * 75 / 100 and wrek = 0:
  85. wrekrand = rand(0, 1000)
  86. if wrekrand = 1000:wrek = 1
  87. elseif teh < tehcar * 75 / 100 and teh >= tehcar * 50/100 and wrek = 0:
  88. wrekrand = rand(0, 100)
  89. if wrekrand = 100:wrek = 1
  90. elseif teh < tehcar * 50 / 100 and teh >= tehcar * 25 / 100 and wrek = 0:
  91. wrekrand = rand(0, 100)
  92. if wrekrand >= 80:wrek = 1
  93. elseif teh < tehcar * 25 / 100 and wrek = 0:
  94. wrekrand = rand(0, 100)
  95. if wrekrand >= 40:wrek = 1
  96. elseif wrek = 1:
  97. 'Something clatters loudly, and the engine stalls.'
  98. act 'Fuck':gt 'carF', 'salon'
  99. end
  100. if alko > 0:
  101. dpsrand = rand(0, 100)
  102. if dpsrand <= alko:
  103. 'A policeman stops you, he looks at your condition and requests you breathe into a tube. You breathe and a red light brightens up on the instrument panel.'
  104. 'The officer snorts, and writes something down. He hands you a slip of paper with the number 50,000 on it'
  105. '"Or I can write a report. But you will get a permanent record for driving drunk."'
  106. if money >= 50000:
  107. act 'Bribe him (50,000 <b>₽</b>)':
  108. cla
  109. money = money - 50000
  110. 'You pay and the policeman warns you that you can not keep driving in your drunken state.'
  111. act 'In the salon':gt 'carF', 'salon'
  112. end
  113. end
  114. act 'Come on, this is within the law':
  115. cla
  116. prava = 0
  117. '"I can take your license, for not driving sober."'
  118. act 'In the salon':gt 'carF', 'salon'
  119. end
  120. exit
  121. end
  122. elseif alko >= 10:
  123. avarand = rand(0, 100)
  124. if avarand >= 50:
  125. teh = teh/2
  126. wrek = 1
  127. 'Driving drunkn, you crash into a tree and wreck your car.'
  128. act 'In the salon':gt 'carF', 'salon'
  129. exit
  130. end
  131. end
  132. if wrek = 0:
  133. if cardrive >= 20:
  134. if cardrive ! 3:
  135. act 'Go to town':
  136. cla
  137. minut += 75
  138. benz -= 1
  139. teh -= rand(3, 6)
  140. cardrive = 3
  141. 'You drive for more than an hour on the highway before you get to the city.'
  142. dynamic $enddrive
  143. end
  144. end
  145. if cardrive ! 21:
  146. act 'Go to the gas station':
  147. cla
  148. minut += 15
  149. benz -= 1
  150. teh -= rand(1, 3)
  151. cardrive = 21
  152. '15 minutes later, you arrive at your destination.'
  153. dynamic $enddrive
  154. end
  155. end
  156. end
  157. if home_owned[5] > 0 and cardrive ! 18:
  158. act 'Go to your mansion':
  159. cla
  160. if cardrive >= 20:
  161. minut += 60
  162. benz -= 1
  163. teh -= rand(1, 3)
  164. cardrive = 18
  165. else
  166. minut += 15
  167. benz -= 1
  168. teh -= rand(1, 3)
  169. cardrive = 18
  170. end
  171. 'You drive to your mansion.'
  172. dynamic $enddrive
  173. end
  174. end
  175. if cardrive ! 1 and cardrive < 20:
  176. act 'Go to the residential area':
  177. cla
  178. minut += 15
  179. benz -= 1
  180. teh -= rand(1, 3)
  181. cardrive = 1
  182. '15 minutes later, you arrive at your destination.'
  183. dynamic $enddrive
  184. end
  185. end
  186. if cardrive ! 2 and cardrive < 20:
  187. act 'Go to the city center':
  188. cla
  189. minut += 15
  190. benz -= 1
  191. teh -= rand(1, 3)
  192. cardrive = 2
  193. '15 minutes later, you arrive at your destination.'
  194. dynamic $enddrive
  195. end
  196. end
  197. if cardrive ! 3 and cardrive < 20:
  198. act 'Go to the city industrial area':
  199. cla
  200. minut += 15
  201. benz -= 1
  202. teh -= rand(1, 3)
  203. cardrive = 3
  204. '15 minutes later, you arrive at your destination.'
  205. dynamic $enddrive
  206. end
  207. end
  208. if cardrive ! 19 and cardrive < 20:
  209. act 'Go to the city train station':
  210. cla
  211. minut = minut + 15
  212. benz = benz - 1
  213. teh = teh - RAND(1,3)
  214. cardrive = 19
  215. '15 minutes later, you arrive at your destination.'
  216. dynamic $enddrive
  217. end
  218. end
  219. if cardrive ! 4 and cardrive < 20:
  220. act 'Go to the city lake':
  221. cla
  222. minut += 15
  223. benz -= 1
  224. teh -= rand(1, 3)
  225. cardrive = 4
  226. '15 minutes later, you arrive at your destination.'
  227. dynamic $enddrive
  228. end
  229. end
  230. if cardrive ! 5 and cardrive < 20:
  231. act 'Go to the city park':
  232. cla
  233. minut += 15
  234. benz -= 1
  235. teh -= rand(1, 3)
  236. cardrive = 5
  237. '15 minutes later, you arrive at your destination.'
  238. dynamic $enddrive
  239. end
  240. end
  241. if cardrive ! 6 and cardrive < 20:
  242. act 'Go to the gas station':
  243. cla
  244. minut += 15
  245. benz -= 1
  246. teh -= rand(1, 3)
  247. cardrive = 6
  248. '15 minutes later, you arrive at your destination.'
  249. dynamic $enddrive
  250. end
  251. end
  252. if cardrive ! 7 and cardrive < 20:
  253. act 'Go to the car wash':
  254. cla
  255. minut += 15
  256. benz -= 1
  257. teh -= rand(1, 3)
  258. cardrive = 7
  259. '15 minutes later, you arrive at your destination.'
  260. dynamic $enddrive
  261. end
  262. end
  263. if cardrive ! 8 and cardrive < 20:
  264. act 'Go to a car dealership':
  265. cla
  266. minut += 15
  267. benz -= 1
  268. teh -= rand(1, 3)
  269. cardrive = 8
  270. '15 minutes later, you arrive at your destination.'
  271. dynamic $enddrive
  272. end
  273. end
  274. if cardrive ! 9 and cardrive < 20:
  275. act 'Go to the used car dealership':
  276. cla
  277. minut += 15
  278. benz -= 1
  279. teh -= rand(1, 3)
  280. cardrive = 9
  281. '15 minutes later, you arrive at your destination.'
  282. dynamic $enddrive
  283. end
  284. end
  285. if cardrive ! 25 and cardrive < 20:
  286. act 'Go to the island':
  287. cla
  288. minut += 15
  289. benz -= 1
  290. teh -= rand(1, 3)
  291. cardrive = 25
  292. '15 minutes later, you arrive at your destination.'
  293. dynamic $enddrive
  294. end
  295. end
  296. if cardrive ! 12:
  297. act 'Go to the construction site':
  298. cla
  299. if cardrive < 20:
  300. minut += 60
  301. 'It takes an hour to get to your destination.'
  302. else
  303. minut += 15
  304. '15 minutes later, you arrive at your destination.'
  305. end
  306. benz -= 1
  307. teh -= rand(2, 5)
  308. cardrive = 12
  309. dynamic $enddrive
  310. end
  311. end
  312. if cardrive ! 13:
  313. act 'Go to the Suburban Cooperative':
  314. cla
  315. if cardrive >= 20:
  316. minut += 60
  317. 'It takes an hour to get to your destination.'
  318. else
  319. minut += 15
  320. '15 minutes later, you arrive at your destination.'
  321. end
  322. benz -= 1
  323. teh -= rand(2, 5)
  324. cardrive = 13
  325. dynamic $enddrive
  326. end
  327. end
  328. if cardrive ! 14:
  329. act 'Go to the Old Town':
  330. cla
  331. if cardrive < 20:
  332. minut += 75
  333. 'It takes you more than an hour to get to the Old Town.'
  334. else
  335. minut += 15
  336. '15 minutes later, you reach the Old Town.'
  337. end
  338. benz -= 1
  339. teh -= rand(2, 5)
  340. cardrive = 14
  341. dynamic $enddrive
  342. end
  343. end
  344. if cardrive ! 20:
  345. act 'Go to Pavlovsk residential area':
  346. cla
  347. benz -= 1
  348. teh -= rand(3, 6)
  349. cardrive = 20
  350. if cardrive < 20:
  351. minut += 75
  352. 'You spend more than an hour on the highway going to Pavlovsk.'
  353. else
  354. minut += 15
  355. '15 minutes later, you reach your destination.'
  356. end
  357. dynamic $enddrive
  358. end
  359. end
  360. if cardrive ! 23:
  361. act 'To go to the village of Gadukino':
  362. cla
  363. benz = benz - 1
  364. teh = teh - RAND(3,6)
  365. cardrive = 23
  366. if cardrive < 20:
  367. minut += 75
  368. 'You spend more than an hour on the highway going to Gadukino.'
  369. else
  370. minut += 15
  371. '15 minutes later, you reach your destination.'
  372. end
  373. dynamic $enddrive
  374. end
  375. end
  376. if cardrive ! 24:
  377. act 'Go to Pavlovsk high street':
  378. cla
  379. benz -= 1
  380. teh -= rand(3, 6)
  381. cardrive = 24
  382. if cardrive < 20:
  383. minut += 75
  384. 'You spend more than an hour on the highway going to Pavlovsk.'
  385. else
  386. minut += 15
  387. '15 minutes later, you reach your destination.'
  388. end
  389. dynamic $enddrive
  390. end
  391. end
  392. if cardrive ! 26:
  393. act 'Go to Pavlovsk Industrial Region':
  394. cla
  395. benz -= 1
  396. teh -= rand(3, 6)
  397. cardrive = 26
  398. if cardrive < 20:
  399. minut += 75
  400. 'You spend more than an hour on the highway going to Pavlovsk.'
  401. else
  402. minut += 15
  403. '15 minutes later, you reach your destination.'
  404. end
  405. dynamic $enddrive
  406. end
  407. end
  408. act 'Drive the St. Petersburg - Pavlovsk Highway':
  409. 'You drive out onto the highway.'
  410. :oops
  411. cla
  412. if cardrive < 20:
  413. numberRoad = input("How many km toward Pavlovsk do you go (from 0 to 20)")
  414. else
  415. numroadtemp = input("How many km toward St Petersburg do you go (from 0 to 20)")
  416. numberroad = 20 - numroadtemp & killvar 'numroadtemp'
  417. end
  418. if numberRoad >= 0 and numberRoad <= 20:
  419. cardrive = 22
  420. nroad = numberRoad
  421. ncarroad = numberRoad
  422. else
  423. 'Invalid Entry'
  424. jump 'oops'
  425. end
  426. xgt 'carF', 'salon'
  427. end
  428. act 'Drive on the track (1:00)':
  429. cla
  430. minut += 60
  431. benz -= 4
  432. teh -= rand(2, 6)
  433. pcs_mood += 20
  434. wipo += 10
  435. 'You go to the track and have fun driving around before leaving.'
  436. act 'Finish':xgt 'carF', 'salon'
  437. end
  438. end
  439. end
  440. end
  441. --- carF ---------------------------------