train.qsrc 28 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751
  1. # train
  2. !2021/05/06
  3. !!============================================!!
  4. !! !!
  5. !! Train Stations !!
  6. !! !!
  7. !!============================================!!
  8. !!-----------------------!!
  9. !! !!
  10. !! communal !!
  11. !! !!
  12. !!-----------------------!!
  13. if $ARGS[0] = 'communal':
  14. gs 'shortgs', 'setloc', 'train', 'communal'
  15. $location_type = 'public_outdoors'
  16. menu_off = 0
  17. gs 'stat'
  18. '<center><img <<$set_imgh>> src="images/locations/shared/train/oldplat.jpg" ></center>'
  19. 'An old railway platform, it looks like it was abandoned. The sign is no longer legible, but there''s a hand painted sign from the communal cottages not too far away.'
  20. *nl
  21. gs 'transport_functions', 'set_train_wait_time', 'communal'
  22. 'The next train in the direction of St. Petersburg city center ' + iif(temp_transportVars['train_wait_center'] = 0, 'is leaving now!', 'leaves in <<temp_transportVars[''train_wait_center'']>> minutes.')
  23. 'The next train in the direction of Pavlovsk ' + iif(temp_transportVars['train_wait_pavlovsk'] = 0, 'is leaving now!', 'leaves in <<temp_transportVars[''train_wait_pavlovsk'']>> minutes.')
  24. act 'Return to the road': minut += 15 & nroad = 5 & gt 'road'
  25. if transportVars['trainpass_day'] > daystart:
  26. *nl
  27. func('transport_functions', 'display_trainpass_time')
  28. act 'Go to platforms': gt 'train', 'communal_trains'
  29. else
  30. act 'Buy a ticket': gt 'train', 'communal_tickets'
  31. end
  32. elseif $ARGS[0] = 'communal_tickets':
  33. gs 'shortgs', 'setloc', 'train', 'communal_tickets'
  34. menu_off = 0
  35. act 'Leave the ticket office': gt 'train', 'communal'
  36. act 'Look at the train schedule':
  37. *clr & cla
  38. gs 'transport_functions', 'display_train_schedule'
  39. *nl
  40. *nl
  41. gs 'transport_functions', 'display_train_schedule', 'pc'
  42. act 'Stop looking at the schedule': gt 'train', 'communal_tickets'
  43. end
  44. gs 'transport_functions', 'buy_train_ticket', 'communal'
  45. elseif $ARGS[0] = 'communal_trains':
  46. gs 'shortgs', 'setloc', 'train', 'communal_trains'
  47. menu_off = 0
  48. gs 'transport_functions', 'set_train_wait_time', 'pavlovsk'
  49. 'The next train in the direction of St. Petersburg city center ' + iif(temp_transportVars['train_wait_center'] = 0, 'is leaving now!', 'leaves in <<temp_transportVars[''train_wait_center'']>> minutes.')
  50. 'The next train in the direction of Pavlovsk ' + iif(temp_transportVars['train_wait_pavlovsk'] = 0, 'is leaving now!', 'leaves in <<temp_transportVars[''train_wait_pavlovsk'']>> minutes.')
  51. act 'Leave the platform': gt 'train', 'communal'
  52. act 'Look at the train schedule':
  53. *clr & cla
  54. gs 'transport_functions', 'display_train_schedule'
  55. *nl
  56. *nl
  57. gs 'transport_functions', 'display_train_schedule', 'pc'
  58. act 'Stop looking at the schedule': gt 'train', 'communal_trains'
  59. end
  60. act 'Take a train to St. Petersburg city center (<<func(''transport_functions'', ''display_train_timecost'', ''communal'', ''center'')>>)': gt 'train', 'communal_center'
  61. act 'Take a train to St. Petersburg city industrial area (<<func(''transport_functions'', ''display_train_timecost'', ''communal'', ''ind'')>>)': gt 'train', 'communal_ind'
  62. act 'Take a train to the village of Gadukino (<<func(''transport_functions'', ''display_train_timecost'', ''communal'', ''gadukino'')>>)': gt 'train', 'communal_gadukino'
  63. act 'Take a train to Pavlovsk (<<func(''transport_functions'', ''display_train_timecost'', ''communal'', ''pavlovsk'')>>)': gt 'train', 'communal_pavlovsk'
  64. end
  65. !!-----------------------!!
  66. !! !!
  67. !! gadukino !!
  68. !! !!
  69. !!-----------------------!!
  70. if $ARGS[0] = 'gadukino':
  71. gs 'shortgs', 'setloc', 'train', 'gadukino'
  72. $location_type = 'public_outdoors'
  73. display_bb = 0
  74. menu_off = 0
  75. *clr & cla
  76. gs 'stat'
  77. '<center><img <<$set_imgh>> src="images/locations/shared/train/gadplat.jpg" ></center>'
  78. 'A fairly nondescript railway platform. The small village of Gadukino where your grandparents reside is not far from here.'
  79. *nl
  80. gs 'transport_functions', 'set_train_wait_time', 'gadukino'
  81. 'The next train in the direction of Pavlovsk ' + iif(temp_transportVars['train_wait_pavlovsk'] = 0, 'is leaving now!', 'leaves in <<temp_transportVars[''train_wait_pavlovsk'']>> minutes.')
  82. 'The next train in the direction of St. Petersburg city center ' + iif(temp_transportVars['train_wait_center'] = 0, 'is leaving now!', 'leaves in <<temp_transportVars[''train_wait_center'']>> minutes.')
  83. act 'Walk to the road (0:15)': minut += 15 & nroad = 10 & gt 'road'
  84. if transportVars['trainpass_day'] > daystart:
  85. *nl
  86. func('transport_functions', 'display_trainpass_time')
  87. act 'Go to platforms': gt 'train', 'gadukino_trains'
  88. else
  89. act 'Buy a ticket': gt 'train', 'gadukino_tickets'
  90. end
  91. elseif $ARGS[0] = 'gadukino_tickets':
  92. gs 'shortgs', 'setloc', 'train', 'gadukino_tickets'
  93. menu_off = 0
  94. act 'Leave the ticket office': gt 'train', 'gadukino'
  95. act 'Look at the train schedule':
  96. *clr & cla
  97. gs 'transport_functions', 'display_train_schedule', 'pc'
  98. *nl
  99. *nl
  100. gs 'transport_functions', 'display_train_schedule'
  101. act 'Stop looking at the schedule': gt 'train', 'gadukino_tickets'
  102. end
  103. gs 'transport_functions', 'buy_train_ticket', 'gadukino', 'pc'
  104. elseif $ARGS[0] = 'gadukino_trains':
  105. gs 'shortgs', 'setloc', 'train', 'gadukino_trains'
  106. menu_off = 0
  107. gs 'transport_functions', 'set_train_wait_time', 'gadukino'
  108. 'The next train in the direction of Pavlovsk ' + iif(temp_transportVars['train_wait_pavlovsk'] = 0, 'is leaving now!', 'leaves in <<temp_transportVars[''train_wait_pavlovsk'']>> minutes.')
  109. 'The next train in the direction of St. Petersburg city center ' + iif(temp_transportVars['train_wait_center'] = 0, 'is leaving now!', 'leaves in <<temp_transportVars[''train_wait_center'']>> minutes.')
  110. act 'Leave the platform': gt 'train', 'gadukino'
  111. act 'Look at the train schedule':
  112. *clr & cla
  113. gs 'transport_functions', 'display_train_schedule', 'pc'
  114. *nl
  115. *nl
  116. gs 'transport_functions', 'display_train_schedule'
  117. act 'Stop looking at the schedule': gt 'train', 'gadukino_tickets'
  118. end
  119. act 'Take a train to Pavlovsk (<<func(''transport_functions'', ''display_train_timecost'', ''gadukino'', ''pavlovsk'')>>)': gt 'train', 'gadukino_pavlovsk'
  120. act 'Take a train to the communal village (<<func(''transport_functions'', ''display_train_timecost'', ''gadukino'', ''communal'')>>)': gt 'train', 'gadukino_communal'
  121. act 'Take a train to St. Petersburg city industrial area (<<func(''transport_functions'', ''display_train_timecost'', ''gadukino'', ''ind'')>>)': gt 'train', 'gadukino_ind'
  122. act 'Take a train to St. Petersburg city center (<<func(''transport_functions'', ''display_train_timecost'', ''gadukino'', ''center'')>>)': gt 'train', 'gadukino_center'
  123. end
  124. !!============================================!!
  125. !! !!
  126. !! Train Transport !!
  127. !! !!
  128. !!============================================!!
  129. !!-----------------------!!
  130. !! !!
  131. !! center !!
  132. !! !!
  133. !!-----------------------!!
  134. if $ARGS[0] = 'center_ind':
  135. $loc = 'city_industrial_train'
  136. $loc_arg = 'inside'
  137. $location_type = 'public_indoors'
  138. menu_off = 1
  139. gs 'transport_functions', 'set_train_wait_time'
  140. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'center', 'ind') + temp_transportVars['train_wait_pavlovsk']
  141. minut += temp_transportVars['timecost']
  142. gs 'stat'
  143. temp_transportVars['rand'] = rand(1, 100)
  144. if temp_transportVars['rand'] <= 9:
  145. gt 'train_incidental', 'events'
  146. elseif transportVars['train_event_day'] ! daystart:
  147. if temp_transportVars['rand'] <= 23:
  148. gt 'train_events', 'private'
  149. elseif temp_transportVars['rand'] <= 31:
  150. gt 'train_events', 'events'
  151. end
  152. end
  153. '<center><img <<$set_imgh>> src="images/locations/shared/train/indusplat.jpg" ></center>'
  154. 'After <<temp_transportVars[''timecost'']>> minutes, the train stops at the St. Petersburg city industrial area station.'
  155. act 'Get off the train':
  156. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  157. gt $loc, $loc_arg
  158. end
  159. elseif $ARGS[0] = 'center_communal':
  160. $loc = 'train'
  161. $loc_arg = 'communal'
  162. $location_type = 'public_indoors'
  163. menu_off = 1
  164. gs 'transport_functions', 'set_train_wait_time'
  165. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'center', 'communal') + temp_transportVars['train_wait_pavlovsk']
  166. minut += temp_transportVars['timecost']
  167. gs 'stat'
  168. temp_transportVars['rand'] = rand(1, 100)
  169. if temp_transportVars['rand'] <= 10:
  170. gt 'train_incidental', 'events'
  171. elseif transportVars['train_event_day'] ! daystart:
  172. if temp_transportVars['rand'] <= 19:
  173. gt 'train_events', 'events'
  174. end
  175. end
  176. '<center><img <<$set_imgh>> src="images/locations/shared/train/oldplat.jpg" ></center>'
  177. 'After <<temp_transportVars[''timecost'']>> minutes you arrive at an old railway platform near the communal village.'
  178. act 'Get off the train':
  179. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  180. gt $loc, $loc_arg
  181. end
  182. elseif $ARGS[0] = 'center_gadukino':
  183. $loc = 'train'
  184. $loc_arg = 'gadukino'
  185. $location_type = 'public_indoors'
  186. menu_off = 1
  187. gs 'transport_functions', 'set_train_wait_time'
  188. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'center', 'gadukino') + temp_transportVars['train_wait_pavlovsk']
  189. minut += temp_transportVars['timecost']
  190. gs 'stat'
  191. temp_transportVars['rand'] = rand(1, 100)
  192. if temp_transportVars['rand'] <= 10:
  193. gt 'train_incidental', 'events'
  194. elseif transportVars['train_event_day'] ! daystart:
  195. if temp_transportVars['rand'] <= 19:
  196. gt 'train_events', 'events'
  197. end
  198. end
  199. '<center><img <<$set_imgh>> src="images/locations/shared/train/gadplat.jpg" ></center>'
  200. 'After <<temp_transportVars[''timecost'']>> minutes, the train stops at the small station near the village of Gadukino.'
  201. act 'Get off the train':
  202. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  203. gt $loc, $loc_arg
  204. end
  205. elseif $ARGS[0] = 'center_pavlovsk':
  206. $loc = 'pav_train_hall'
  207. $loc_arg = ''
  208. $location_type = 'public_indoors'
  209. menu_off = 1
  210. gs 'transport_functions', 'set_train_wait_time'
  211. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'center', 'pavlovsk') + temp_transportVars['train_wait_pavlovsk']
  212. minut += temp_transportVars['timecost']
  213. gs 'stat'
  214. temp_transportVars['rand'] = rand(1, 100)
  215. if temp_transportVars['rand'] <= 6:
  216. gt 'train_incidental', 'events'
  217. elseif transportVars['train_event_day'] ! daystart:
  218. if temp_transportVars['rand'] <= 20:
  219. gt 'train_events', 'private'
  220. elseif temp_transportVars['rand'] <= 45:
  221. gt 'train_events', 'Gopnik'
  222. elseif temp_transportVars['rand'] <= 51:
  223. gt 'train_events', 'events'
  224. end
  225. end
  226. '<center><img <<$set_imgh>> src="images/locations/shared/train/pavplat.jpg" ></center>'
  227. 'After <<temp_transportVars[''timecost'']>> minutes, you see the town of Pavlovsk approaching. Pavlovsk Castle is an impressive sight, even from a long distance. The train stops at its final destination, a platform in Pavlovsk station.'
  228. act 'Get off the train':
  229. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  230. gt $loc, $loc_arg
  231. end
  232. end
  233. !!-----------------------!!
  234. !! !!
  235. !! industrial !!
  236. !! !!
  237. !!-----------------------!!
  238. if $ARGS[0] = 'ind_center':
  239. $loc = 'city_train'
  240. $loc_arg = 'start'
  241. $location_type = 'public_indoors'
  242. menu_off = 1
  243. gs 'transport_functions', 'set_train_wait_time'
  244. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'ind', 'center') + temp_transportVars['train_wait_center']
  245. minut += temp_transportVars['timecost']
  246. gs 'stat'
  247. temp_transportVars['rand'] = rand(1, 100)
  248. if temp_transportVars['rand'] <= 9:
  249. gt 'train_incidental', 'events'
  250. elseif transportVars['train_event_day'] ! daystart:
  251. if temp_transportVars['rand'] <= 23:
  252. gt 'train_events', 'private'
  253. elseif temp_transportVars['rand'] <= 31:
  254. gt 'train_events', 'events'
  255. end
  256. end
  257. '<center><img <<$set_imgh>> src="images/locations/shared/train/electri_' + rand(1,5) + '.jpg"></center>'
  258. 'You pay for the ticket and board the next train going to the city center.'
  259. 'After <<temp_transportVars[''timecost'']>> minutes, you see the office blocks and shops at the heart of the city. The train stops at its final destination, the busy station in the city center.'
  260. act 'Get off the train at this station':
  261. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  262. gt $loc, $loc_arg
  263. end
  264. elseif $ARGS[0] = 'ind_communal':
  265. $loc = 'train'
  266. $loc_arg = 'communal'
  267. $location_type = 'public_indoors'
  268. menu_off = 1
  269. gs 'transport_functions', 'set_train_wait_time'
  270. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'ind', 'communal') + temp_transportVars['train_wait_pavlovsk']
  271. minut += temp_transportVars['timecost']
  272. gs 'stat'
  273. temp_transportVars['rand'] = rand(1, 100)
  274. if temp_transportVars['rand'] <= 6:
  275. gt 'train_incidental', 'events'
  276. elseif transportVars['train_event_day'] ! daystart:
  277. if temp_transportVars['rand'] <= 17:
  278. gt 'train_events', 'events'
  279. end
  280. end
  281. '<center><img <<$set_imgh>> src="images/locations/shared/train/oldplat.jpg" ></center>'
  282. 'After <<temp_transportVars[''timecost'']>> minutes you arrive at an old railway platform near the communal village.'
  283. act 'Get off the train':
  284. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  285. gt $loc, $loc_arg
  286. end
  287. elseif $ARGS[0] = 'ind_gadukino':
  288. $loc = 'train'
  289. $loc_arg = 'gadukino'
  290. $location_type = 'public_indoors'
  291. menu_off = 1
  292. gs 'transport_functions', 'set_train_wait_time'
  293. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'ind', 'gadukino') + temp_transportVars['train_wait_pavlovsk']
  294. minut += temp_transportVars['timecost']
  295. gs 'stat'
  296. temp_transportVars['rand'] = rand(1, 100)
  297. if temp_transportVars['rand'] <= 10:
  298. gt 'train_incidental', 'events'
  299. elseif transportVars['train_event_day'] ! daystart:
  300. if temp_transportVars['rand'] <= 19:
  301. gt 'train_events', 'events'
  302. end
  303. end
  304. '<center><img <<$set_imgh>> src="images/locations/shared/train/gadplat.jpg" ></center>'
  305. 'After <<temp_transportVars[''timecost'']>> minutes, the train stops at the small station near the village of Gadukino.'
  306. act 'Get off the train':
  307. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  308. gt $loc, $loc_arg
  309. end
  310. elseif $ARGS[0] = 'ind_pavlovsk':
  311. $loc = 'pav_train_hall'
  312. $loc_arg = ''
  313. $location_type = 'public_indoors'
  314. menu_off = 1
  315. gs 'transport_functions', 'set_train_wait_time'
  316. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'ind', 'pavlovsk') + temp_transportVars['train_wait_pavlovsk']
  317. minut += temp_transportVars['timecost']
  318. gs 'stat'
  319. temp_transportVars['rand'] = rand(1, 100)
  320. if temp_transportVars['rand'] <= 6:
  321. gt 'train_incidental', 'events'
  322. elseif transportVars['train_event_day'] ! daystart:
  323. if temp_transportVars['rand'] <= 20:
  324. gt 'train_events', 'private'
  325. elseif temp_transportVars['rand'] <= 45:
  326. gt 'train_events', 'Gopnik'
  327. elseif temp_transportVars['rand'] <= 51:
  328. gt 'train_events', 'events'
  329. end
  330. end
  331. '<center><img <<$set_imgh>> src="images/locations/shared/train/pavplat.jpg" ></center>'
  332. 'After <<temp_transportVars[''timecost'']>> minutes, you see the town of Pavlovsk approaching. Pavlovsk Castle is an impressive sight, even from a long distance. The train stops at its final destination, a platform in Pavlovsk station.'
  333. act 'Get off the train':
  334. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  335. gt $loc, $loc_arg
  336. end
  337. end
  338. !!-----------------------!!
  339. !! !!
  340. !! communal !!
  341. !! !!
  342. !!-----------------------!!
  343. if $ARGS[0] = 'communal_center':
  344. $loc = 'city_train'
  345. $loc_arg = 'start'
  346. $location_type = 'public_indoors'
  347. menu_off = 1
  348. gs 'transport_functions', 'set_train_wait_time'
  349. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'communal', 'center') + temp_transportVars['train_wait_center']
  350. minut += temp_transportVars['timecost']
  351. gs 'stat'
  352. temp_transportVars['rand'] = rand(1, 100)
  353. if temp_transportVars['rand'] <= 10:
  354. gt 'train_incidental', 'events'
  355. elseif transportVars['train_event_day'] ! daystart:
  356. if temp_transportVars['rand'] <= 19:
  357. gt 'train_events', 'events'
  358. end
  359. end
  360. '<center><img <<$set_imgh>> src="images/locations/shared/train/cityplat.jpg" ></center>'
  361. 'After <<temp_transportVars[''timecost'']>> minutes, the train stops at the St. Petersburg city center station. The large office blocks and shopping centers fill your view.'
  362. act 'Get off the train':
  363. if transportVars['train_event_day'] ! daystart and rand(1, 100) <= 5: gt 'train_incidental', 'end'
  364. gt $loc, $loc_arg
  365. end
  366. elseif $ARGS[0] = 'communal_ind':
  367. $loc = 'city_industrial_train'
  368. $loc_arg = 'inside'
  369. $location_type = 'public_indoors'
  370. menu_off = 1
  371. gs 'transport_functions', 'set_train_wait_time'
  372. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'communal', 'ind') + temp_transportVars['train_wait_center']
  373. minut += temp_transportVars['timecost']
  374. gs 'stat'
  375. temp_transportVars['rand'] = rand(1, 100)
  376. if temp_transportVars['rand'] <= 6:
  377. gt 'train_incidental', 'events'
  378. elseif transportVars['train_event_day'] ! daystart:
  379. if temp_transportVars['rand'] <= 16:
  380. gt 'train_events', 'events'
  381. end
  382. end
  383. '<center><img <<$set_imgh>> src="images/locations/shared/train/indusplat.jpg" ></center>'
  384. 'After <<temp_transportVars[''timecost'']>> minutes, the train stops at the St. Petersburg city industrial area station.'
  385. act 'Get off the train':
  386. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  387. gt $loc, $loc_arg
  388. end
  389. elseif $ARGS[0] = 'communal_gadukino':
  390. $loc = 'train'
  391. $loc_arg = 'gadukino'
  392. $location_type = 'public_indoors'
  393. menu_off = 1
  394. gs 'transport_functions', 'set_train_wait_time'
  395. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'communal', 'gadukino') + temp_transportVars['train_wait_pavlovsk']
  396. minut += temp_transportVars['timecost']
  397. gs 'stat'
  398. temp_transportVars['rand'] = rand(1, 100)
  399. if temp_transportVars['rand'] <= 6:
  400. gt 'train_incidental', 'events'
  401. elseif transportVars['train_event_day'] ! daystart:
  402. if temp_transportVars['rand'] <= 16:
  403. gt 'train_events', 'events'
  404. end
  405. end
  406. '<center><img <<$set_imgh>> src="images/locations/shared/train/gadplat.jpg" ></center>'
  407. 'After <<temp_transportVars[''timecost'']>> minutes, the train stops at the small station near the village of Gadukino.'
  408. act 'Get off the train':
  409. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  410. gt $loc, $loc_arg
  411. end
  412. elseif $ARGS[0] = 'communal_pavlovsk':
  413. $loc = 'pav_train_hall'
  414. $loc_arg = ''
  415. $location_type = 'public_indoors'
  416. menu_off = 1
  417. gs 'transport_functions', 'set_train_wait_time'
  418. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'communal', 'pavlovsk') + temp_transportVars['train_wait_pavlovsk']
  419. minut += temp_transportVars['timecost']
  420. gs 'stat'
  421. temp_transportVars['rand'] = rand(1, 100)
  422. if temp_transportVars['rand'] <= 20:
  423. gt 'train_incidental', 'events'
  424. elseif transportVars['train_event_day'] ! daystart:
  425. if temp_transportVars['rand'] <= 28:
  426. gt 'train_events', 'events'
  427. end
  428. end
  429. '<center><img <<$set_imgh>> src="images/locations/shared/train/pavplat.jpg" ></center>'
  430. 'After <<temp_transportVars[''timecost'']>> minutes, you see the town of Pavlovsk approaching. Pavlovsk Castle is an impressive sight, even from a long distance. The train stops at its final destination, a platform in Pavlovsk station.'
  431. act 'Get off the train': gt $loc, $loc_arg
  432. end
  433. !!-----------------------!!
  434. !! !!
  435. !! gadukino !!
  436. !! !!
  437. !!-----------------------!!
  438. if $ARGS[0] = 'gadukino_center':
  439. $loc = 'city_train'
  440. $loc_arg = 'start'
  441. $location_type = 'public_indoors'
  442. menu_off = 1
  443. gs 'transport_functions', 'set_train_wait_time'
  444. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'gadukino', 'center') + temp_transportVars['train_wait_center']
  445. minut += temp_transportVars['timecost']
  446. gs 'stat'
  447. temp_transportVars['rand'] = rand(1, 100)
  448. if temp_transportVars['rand'] <= 10:
  449. gt 'train_incidental', 'events'
  450. elseif transportVars['train_event_day'] ! daystart:
  451. if temp_transportVars['rand'] <= 24:
  452. gt 'train_events', 'events'
  453. end
  454. end
  455. '<center><img <<$set_imgh>> src="images/locations/shared/train/cityplat.jpg" ></center>'
  456. 'After <<temp_transportVars[''timecost'']>> minutes, the train stops at the St. Petersburg city center station. The large office blocks and shopping centers fill your view.'
  457. act 'Get off the train':
  458. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  459. gt $loc, $loc_arg
  460. end
  461. elseif $ARGS[0] = 'gadukino_ind':
  462. $loc = 'city_industrial_train'
  463. $loc_arg = 'inside'
  464. $location_type = 'public_indoors'
  465. menu_off = 1
  466. gs 'transport_functions', 'set_train_wait_time'
  467. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'gadukino', 'ind') + temp_transportVars['train_wait_center']
  468. minut += temp_transportVars['timecost']
  469. gs 'stat'
  470. temp_transportVars['rand'] = rand(1, 100)
  471. if temp_transportVars['rand'] <= 10:
  472. gt 'train_incidental', 'events'
  473. elseif transportVars['train_event_day'] ! daystart:
  474. if temp_transportVars['rand'] <= 24:
  475. gt 'train_events', 'events'
  476. end
  477. end
  478. '<center><img <<$set_imgh>> src="images/locations/shared/train/indusplat.jpg" ></center>'
  479. 'After <<temp_transportVars[''timecost'']>> minutes, the train stops at the St. Petersburg city industrial area station.'
  480. act 'Get off the train':
  481. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  482. gt $loc, $loc_arg
  483. end
  484. elseif $ARGS[0] = 'gadukino_communal':
  485. $loc = 'train'
  486. $loc_arg = 'communal'
  487. $location_type = 'public_indoors'
  488. menu_off = 1
  489. gs 'transport_functions', 'set_train_wait_time'
  490. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'gadukino', 'communal') + temp_transportVars['train_wait_center']
  491. minut += temp_transportVars['timecost']
  492. gs 'stat'
  493. temp_transportVars['rand'] = rand(1, 100)
  494. if temp_transportVars['rand'] <= 6:
  495. gt 'train_incidental', 'events'
  496. elseif transportVars['train_event_day'] ! daystart:
  497. if temp_transportVars['rand'] <= 16:
  498. gt 'train_events', 'events'
  499. end
  500. end
  501. '<center><img <<$set_imgh>> src="images/locations/shared/train/oldplat.jpg" ></center>'
  502. 'After <<temp_transportVars[''timecost'']>> minutes, you arrive at an old railway platform near the communal village.'
  503. act 'Get off the train':
  504. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  505. gt $loc, $loc_arg
  506. end
  507. elseif $ARGS[0] = 'gadukino_pavlovsk':
  508. $loc = 'pav_train_hall'
  509. $loc_arg = ''
  510. $location_type = 'public_indoors'
  511. menu_off = 1
  512. gs 'transport_functions', 'set_train_wait_time'
  513. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'gadukino', 'pavlovsk') + temp_transportVars['train_wait_pavlovsk']
  514. minut += temp_transportVars['timecost']
  515. gs 'stat'
  516. temp_transportVars['rand'] = rand(1, 100)
  517. if temp_transportVars['rand'] <= 20:
  518. gt 'train_incidental', 'events'
  519. elseif transportVars['train_event_day'] ! daystart:
  520. if temp_transportVars['rand'] <= 28:
  521. gt 'train_events', 'events'
  522. end
  523. end
  524. '<center><img <<$set_imgh>> src="images/locations/shared/train/pavplat.jpg" ></center>'
  525. 'After <<temp_transportVars[''timecost'']>> minutes, you see the town of Pavlovsk approaching. Pavlovsk Castle is an impressive sight, even from a long distance. The train stops at its final destination, a platform in Pavlovsk station.'
  526. act 'Get off the train':
  527. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  528. gt $loc, $loc_arg
  529. end
  530. end
  531. !!-----------------------!!
  532. !! !!
  533. !! pavlovsk !!
  534. !! !!
  535. !!-----------------------!!
  536. if $ARGS[0] = 'pavlovsk_center':
  537. $loc = 'city_train'
  538. $loc_arg = 'start'
  539. $location_type = 'public_indoors'
  540. menu_off = 1
  541. gs 'transport_functions', 'set_train_wait_time'
  542. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'pavlovsk', 'center') + temp_transportVars['train_wait_center']
  543. minut += temp_transportVars['timecost']
  544. gs 'stat'
  545. temp_transportVars['rand'] = rand(1, 100)
  546. if temp_transportVars['rand'] <= 6:
  547. gt 'train_incidental', 'events'
  548. elseif transportVars['train_event_day'] ! daystart:
  549. if temp_transportVars['rand'] <= 20:
  550. gt 'train_events', 'private'
  551. elseif temp_transportVars['rand'] <= 45:
  552. gt 'train_events', 'Gopnik'
  553. elseif temp_transportVars['rand'] <= 55:
  554. gt 'train_events', 'weed'
  555. elseif temp_transportVars['rand'] <= 61:
  556. gt 'train_events', 'events'
  557. end
  558. end
  559. '<center><img <<$set_imgh>> src="images/locations/shared/train/cityplat.jpg" ></center>'
  560. 'After <<temp_transportVars[''timecost'']>> minutes, the train stops at the St. Petersburg city center station. The large office blocks and shopping centers fill your view.'
  561. act 'Get off the train':
  562. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  563. gt $loc, $loc_arg
  564. end
  565. elseif $ARGS[0] = 'pavlovsk_ind':
  566. $loc = 'city_industrial_train'
  567. $loc_arg = 'inside'
  568. $location_type = 'public_indoors'
  569. menu_off = 1
  570. gs 'transport_functions', 'set_train_wait_time'
  571. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'pavlovsk', 'ind') + temp_transportVars['train_wait_center']
  572. minut += temp_transportVars['timecost']
  573. gs 'stat'
  574. temp_transportVars['rand'] = rand(1, 100)
  575. if temp_transportVars['rand'] <= 6:
  576. gt 'train_incidental', 'events'
  577. elseif transportVars['train_event_day'] ! daystart:
  578. if temp_transportVars['rand'] <= 20:
  579. gt 'train_events', 'private'
  580. elseif temp_transportVars['rand'] <= 45:
  581. gt 'train_events', 'Gopnik'
  582. elseif temp_transportVars['rand'] <= 51:
  583. gt 'train_events', 'events'
  584. end
  585. end
  586. '<center><img <<$set_imgh>> src="images/locations/shared/train/indusplat.jpg" ></center>'
  587. 'After <<temp_transportVars[''timecost'']>> minutes, the train stops at the St. Petersburg city industrial area station.'
  588. act 'Get off the train':
  589. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  590. gt $loc, $loc_arg
  591. end
  592. elseif $ARGS[0] = 'pavlovsk_communal':
  593. $loc = 'train'
  594. $loc_arg = 'communal'
  595. $location_type = 'public_indoors'
  596. menu_off = 1
  597. gs 'transport_functions', 'set_train_wait_time'
  598. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'pavlovsk', 'communal') + temp_transportVars['train_wait_center']
  599. minut += temp_transportVars['timecost']
  600. gs 'stat'
  601. temp_transportVars['rand'] = rand(1, 100)
  602. if temp_transportVars['rand'] <= 10:
  603. gt 'train_incidental', 'events'
  604. elseif transportVars['train_event_day'] ! daystart:
  605. if temp_transportVars['rand'] <= 38:
  606. gt 'train_events', 'events'
  607. end
  608. end
  609. '<center><img <<$set_imgh>> src="images/locations/shared/train/oldplat.jpg" ></center>'
  610. 'After <<temp_transportVars[''timecost'']>> minutes you arrive at an old railway platform near the communal village.'
  611. act 'Get off the train':
  612. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  613. gt $loc, $loc_arg
  614. end
  615. elseif $ARGS[0] = 'pavlovsk_gadukino':
  616. $loc = 'train'
  617. $loc_arg = 'gadukino'
  618. $location_type = 'public_indoors'
  619. menu_off = 1
  620. gs 'transport_functions', 'set_train_wait_time'
  621. temp_transportVars['timecost'] = func('transport_functions', 'get_train_timecost', 'pavlovsk', 'gadukino') + temp_transportVars['train_wait_center']
  622. minut += temp_transportVars['timecost']
  623. gs 'stat'
  624. temp_transportVars['rand'] = rand(1, 100)
  625. if temp_transportVars['rand'] <= 10:
  626. gt 'train_incidental', 'events'
  627. elseif transportVars['train_event_day'] ! daystart:
  628. if temp_transportVars['rand'] <= 19:
  629. gt 'train_events', 'events'
  630. end
  631. end
  632. '<center><img <<$set_imgh>> src="images/locations/shared/train/gadplat.jpg" ></center>'
  633. 'After <<temp_transportVars[''timecost'']>> minutes, the train stops at the small station near the village of Gadukino.'
  634. act 'Get off the train':
  635. if rand(1, 100) <= 5: gt 'train_incidental', 'end'
  636. gt $loc, $loc_arg
  637. end
  638. end
  639. killvar 'temp_transportVars'
  640. --- train ---------------------------------