shop.qsrc 34 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855
  1. # shop
  2. !! This is the supermarket, located in several places
  3. !! Main entrance
  4. if $ARGS[0] = 'start':
  5. $menu_loc = 'shop'
  6. $menu_arg = 'start'
  7. menu_off = 0
  8. CLOSE ALL
  9. $location_type = 'public_indoors'
  10. gs 'themes', 'indoors'
  11. if sound = 0:PLAY 'sound/shop.mp3',30
  12. $shoplocation = 'main'
  13. end
  14. if $ARGS[0] = 'start' or $ARGS[0] = 'move': minut += 1
  15. !! Main area
  16. if $shoplocation = 'main':
  17. if $loc = 'shop': $loc = $loc_bak
  18. *clr & cla
  19. '<center><b><font color="maroon">Supermarket</font></b></center>'
  20. '<center><img <<$set_imgh>> src="images/locations/shared/store/shop.jpg"></center>'
  21. if hour < 8 or hour > 20:
  22. 'The supermarket is currently closed.'
  23. if $loc = 'shop':
  24. if $loc_bak = 'shop':
  25. $loc = 'city_trademission'
  26. else
  27. $loc = $loc_bak
  28. end
  29. end
  30. act 'Leave the store': minut += 3 & gt $loc
  31. exit
  32. end
  33. 'An <a href="exec:$shoplocation = ''ATM'' & gt ''shop'', ''move''">ATM</a>, from which you can withdraw money from your bank account, stands against a wall.'
  34. 'There is a branch of the communications giant <a href="exec:$shoplocation = ''megafon'' & gt ''shop'', ''move''">MegaFon</a>.'
  35. 'A <a href="exec: gs ''noticeboard'',''start''">Public notice board</a>, where you can check various private and official advertisements, is sitting on a nearby wall.'
  36. '<br>Most of the space in the supermarket is taken up by the <a href="exec:$shoplocation = ''grocery'' & gt ''shop'', ''move''">grocery department</a>, but the store has many smaller departments as well.'
  37. 'These include <a href="exec:$shoplocation=''cosmetics'' & gt ''shop'', ''move''">cosmetics</a>, <a href="exec:$shoplocation = ''hardware'' & gt ''shop'', ''move''">hardware</a>, <a href="exec:$shoplocation = ''clothing'' & gt ''shop'', ''move''">clothing</a> and <a href="exec:$shoplocation = ''tech'' & gt ''shop'', ''move''">household appliances</a>. Not far from the entrance is a <a href="exec:$shoplocation = ''icecream'' & gt ''shop'', ''move''">counter selling ice cream</a>.'
  38. gs 'stat'
  39. gs 'themes', 'indoors'
  40. gs 'family_schedule'
  41. !! The store in the town and in the altstart only
  42. if $loc = 'pav_commercial':
  43. if locat['Anya'] = 7:
  44. *nl
  45. 'Your sister <a href="exec:$shoplocation = ''Anya'' & gt ''shop'', ''move''">Anya</a> is sitting at the cash register.'
  46. end
  47. end
  48. !! Store in the residential district
  49. if $loc = 'city_residential':
  50. if rand(1, 20) = 20:
  51. if dimaQW = 0:
  52. 'A man is standing by the entrance, looking at you appreciatively.'
  53. act 'Return the look':gt 'event', 'dima'
  54. elseif dimaQW = 1:
  55. 'You notice Dima nearby and are frozen with fear. You want to run, but your legs won''t respond.'
  56. 'Your heart thumps in your chest, your vision narrows and you feel faint.'
  57. act 'Pass out':gt 'event', 'scoreslut1'
  58. else
  59. 'You meet the same Dima whose friend fucked and abused you. Dima grins confidently. "Hello there..."'
  60. act 'Hello':
  61. cla
  62. '"Come with me. My wife''s away..." he says with a grin.'
  63. gs 'willpower', 'sex', 'resist'
  64. if pcs_willpwr < will_cost:
  65. act 'No (<font color="red"><<will_cost>> Willpower</font>)': '<br><font color="red">You don''t have enough willpower to use this action.</font>'
  66. else
  67. act 'No (<<will_cost>> Willpower)':
  68. gs 'willpower', 'pay', 'resist'
  69. gt 'shop', 'start'
  70. end
  71. end
  72. act 'I deserve this':
  73. *clr & cla
  74. if rand(1, 2) = 1:
  75. cla
  76. 'Dima takes you to his house and orders you to lie across the sofa. You get into position and he calls you a bitch before he starts fucking you in the mouth.'
  77. '<center><img <<$set_imgh>> src="images/locations/city/residential/street/sex/gostdt2.jpg"></center>'
  78. 'Dima finally finishes in your mouth. You obediently swallow and lick the remnants of sperm off his cock.'
  79. gs 'arousal', 'bj', 10, 'sub', 'deepthroat', 'humiliation'
  80. gs 'arousal', 'end'
  81. gs 'cum_call', 'mouth_swallow', 'A169', 1
  82. gs 'stat'
  83. act 'Leave': minut += 3 & gt 'city_residential'
  84. else
  85. cla
  86. gs 'pain', 6, 'asscheeks', 'slap'
  87. spank += 1
  88. 'Dima brings you to his house and begins to kiss and undress you in the hall. Once you''re naked, he takes you to the bathroom.'
  89. 'He unscrews the shower head and shoves the hose in your ass. You feel the rush of water quickly filling you before Dima sits you on the toilet. After the rough enema, he bends you over and inserts his dick into your ass.'
  90. '<center><img <<$set_imgh>> src="images/locations/city/residential/street/sex/gostanal2.jpg"></center>'
  91. 'He fucks and slaps your ass for a few minutes before he moans and you feel a warmth filling your ass.'
  92. gs 'arousal', 'anal', 30, 'sub', 'rough', 'humiliation'
  93. gs 'arousal', 'end'
  94. gs 'cum_call', 'anus', 'A169', 1
  95. gs 'stat'
  96. act 'Leave': minut += 3 & gt 'city_residential'
  97. end
  98. end
  99. end
  100. end
  101. end
  102. end
  103. '<br>The store is crowded with shoppers.'
  104. !! This is connected to the trade mission
  105. if TorgPredZ > 0:
  106. !! the location of the shop hasn''t been done today
  107. if ($loc = 'city_residential' and StreetShopTPday ! daystart) or ($loc = 'city_industrial' and nordShopTPday ! daystart) or ($loc = 'torgcentr' and downShopTPday ! daystart):
  108. act 'Promote products':
  109. *clr & cla
  110. if $loc = 'city_residential': StreetShopTPday = daystart
  111. if $loc = 'city_industrial': nordShopTPday = daystart
  112. if $loc = 'torgcentr': downShopTPday = daystart
  113. mtprand = rand(40, 130)
  114. minut += mtprand
  115. TorgPredZ -= 1
  116. TorgPredZV += 1
  117. gs 'stat'
  118. '<center><img <<$set_imgh>> src="images/locations/shared/store/shop.jpg"></center>'
  119. 'You promote the products for quite a while, and when you finally finish, you go to the cashier and tell them that they sold.'
  120. act 'Leave': gt 'shop', 'start'
  121. end
  122. end
  123. end
  124. act 'Leave the store': minut += 3 & gt $loc
  125. exit
  126. end
  127. if $shoplocation = 'ATM':
  128. '<center><b><font color="maroon">ATM</font></b></center>'
  129. '<center><img <<$set_imgh>> src="images/locations/shared/store/atm.jpg"></center>'
  130. if bankAccount = 0:
  131. 'You don''t have a bank account yet!'
  132. else
  133. if karta >= 0:
  134. 'You have <<karta>> <b>₽</b> in your account.'
  135. 'You have an overdraft limit of <font color="blue"><<bankDebtLimit>></font>!'
  136. else
  137. 'You are overdrawn by <font color="red"><<-1 * karta>> <b>₽</b></font>.'
  138. 'You have a remaining credit limit of <font color="blue"><<bankDebtLimit + karta>></font>!'
  139. end
  140. '<br>ATM Deposit Fee: 100 <b>₽</b>'
  141. if atmDeposit ! 0:
  142. '<br>★ Processing deposit of <<atmDeposit>> <b>₽</b> in <<atmDepositDate - daystart>> days.'
  143. else
  144. act 'Deposit money':
  145. cla
  146. minut += 5
  147. kartaINATM = input ('How much money do you want to deposit into the account? Note: A service charge of 100 <b>₽</b> will be deducted from the amount deposited.')
  148. if kartaINATM < 100 or kartaINATM > money:
  149. 'This is not a valid input.'
  150. else
  151. karta += kartaINATM - 100
  152. atmDepositDate = daystart + 2
  153. money -= kartaINATM
  154. '<br>You deposit <<kartaINATM>> <b>₽</b> into your account.'
  155. 'It will take 2 days for funds to be available. Your new balance will be <<karta+atmDeposit>> <b>₽</b>.'
  156. end
  157. gs 'stat'
  158. act 'Move away': gt 'shop', 'start'
  159. end
  160. end
  161. if karta + bankDebtLimit < 0:
  162. 'You have maxed out your overdraft.'
  163. else
  164. act 'Withdraw money from the ATM':
  165. cla
  166. minut += 5
  167. kartaOUT = input ("How much money do you want to withdraw?")
  168. if kartaOUT <= 0 or kartaOUT > karta + bankDebtLimit:
  169. '<br>Invalid operation.'
  170. else
  171. karta -= kartaOUT
  172. money += kartaOUT
  173. if karta > 0:
  174. '<br>You withdraw <<kartaOUT>> <b>₽</b>. You have <<karta>> <b>₽</b> left in your bank account.'
  175. elseif karta = 0:
  176. '<br>You withdraw <<kartaOUT>> <b>₽</b>. You have no money left in your bank account.'
  177. else
  178. '<br>You withdraw <<kartaOUT>> <b>₽</b>. <font color="red">Your bank account is overdrawn by <b><<karta>> ₽</b>.</font>'
  179. end
  180. end
  181. gs 'stat'
  182. act 'Move away': gt 'shop', 'start'
  183. end
  184. end
  185. end
  186. act 'Move away':gt 'shop', 'start'
  187. end
  188. if $shoplocation = 'grocery':
  189. $loc_s = 'shop'
  190. $args_s = 'grocery'
  191. *clr & cla
  192. if hour < 8 or hour > 20:
  193. 'The grocery department is currently closed.'
  194. act 'Leave': gt 'shop', 'start'
  195. exit
  196. end
  197. gs 'item_cart', 'shoppping_aisle', 'food'
  198. gs 'stat'
  199. gs 'themes', 'indoors'
  200. $backimage= 'images/locations/shared/store/shop1.jpg'
  201. act 'Leave the grocery department': gt 'shop', 'start'
  202. act 'Go to the pet aisle': gt 'shop', 'dog_items'
  203. if $loc = 'torgcentr':gs 'shoplifting', 'city'
  204. end
  205. if $ARGS[0] = 'dog_items':
  206. *clr & cla
  207. minut += 1
  208. menu_off = 1
  209. $location_type = 'public_indoors'
  210. gs 'stat'
  211. '<center><img <<$set_imgh>> src="images/characters/shared/rex/pet_isle.jpg"></center>'
  212. 'You''re currently in the pet aisle, where you can buy food, treats and other things for your dog.'
  213. act 'Leave': gt 'shop', 'start'
  214. if $home['current'] ! 'parents_home':
  215. act 'Buy dog food':
  216. *clr & cla
  217. minut += 1
  218. gs 'stat'
  219. '<center><img <<$set_imgh>> src="images/characters/shared/rex/dog_food.jpg"></center>'
  220. 'The store sells dog food for 600 <b>₽</b>. Inside each pack is enough food for 20 meals. You have <<objects[''dog_food'']>>.'
  221. if money < 600:
  222. '<br>You don''t have enough money to buy food.'
  223. else
  224. act 'Buy enough for 20 meals (600 <b>₽</b>, pay cash)':
  225. money -= 600
  226. objects['dog_food'] += 20
  227. gt 'shop', 'dog_items'
  228. end
  229. end
  230. if money >= 1200:
  231. act 'Buy enough for 40 meals (1200 <b>₽</b>, pay cash)':
  232. money -= 1200
  233. objects['dog_food'] += 40
  234. gt 'shop', 'dog_items'
  235. end
  236. end
  237. if money >= 2400:
  238. act 'Buy enough for 80 meals (2400 <b>₽</b>, pay cash)':
  239. money -= 2400
  240. objects['dog_food'] += 80
  241. gt 'shop', 'dog_items'
  242. end
  243. end
  244. end
  245. else
  246. '<br>You don''t need to buy dog food. Your parents pay for it.'
  247. end
  248. act 'Buy some dog treats':
  249. *clr & cla
  250. minut += 1
  251. gs 'stat'
  252. '<center><img <<$set_imgh>> src="images/characters/shared/rex/treat_'+rand(0,2)+'.jpg"></center>'
  253. 'The store sells dog treats for 300 <b>₽</b>. Inside each pack are 20 treats. You have <<objects[''treats'']>>.'
  254. act 'Go back': gt 'shop', 'dog_items'
  255. if money < 300:
  256. 'You don''t have enough money to buy a pack.'
  257. else
  258. act 'Buy a pack (300 <b>₽</b>, pay cash)':
  259. money -= 300
  260. objects['treats'] += 20
  261. gt 'shop', 'dog_items'
  262. end
  263. end
  264. end
  265. act 'Buy a chew toy for your dog':
  266. *clr & cla
  267. minut += 1
  268. gs 'stat'
  269. '<center><img <<$set_imgh>> src="images/characters/shared/rex/chew.jpg"></center>'
  270. 'The store sells a chew toy for 800 <b>₽</b>.'
  271. act 'Go back': gt 'shop', 'dog_items'
  272. if money < 800:
  273. 'You don''t have enough money to buy it.'
  274. else
  275. act 'Buy one (800 <b>₽</b>, pay cash)':
  276. money -= 800
  277. objects['chew'] += 10
  278. gt 'shop', 'dog_items'
  279. end
  280. end
  281. end
  282. if objects['toys'] = 0:
  283. act 'Buy fetch balls':
  284. *clr & cla
  285. minut += 1
  286. gs 'stat'
  287. '<center><img <<$set_imgh>> src="images/characters/shared/rex/balls.jpg"></center>'
  288. 'The store sells rubber balls for 900 <b>₽</b> that you can use to play fetch with your dog.'
  289. act 'Go back': gt 'shop', 'dog_items'
  290. if money < 900:
  291. 'You don''t have enough money to buy them.'
  292. else
  293. act 'Buy them (900 <b>₽</b>, pay cash)':
  294. money -= 900
  295. objects['toys'] = 1
  296. gt 'shop', 'dog_items'
  297. end
  298. end
  299. end
  300. end
  301. end
  302. if $shoplocation= 'cosmetics':
  303. $loc_s = 'shop'
  304. $args_s = 'cosmetics'
  305. *clr & cla
  306. if hour < 8 or hour > 20:
  307. 'The cosmetics department is currently closed.'
  308. act 'Leave': gt 'shop', 'start'
  309. exit
  310. end
  311. gs 'item_cart', 'shoppping_aisle', 'beauty'
  312. gs 'stat'
  313. gs 'themes', 'indoors'
  314. $backimage= 'images/locations/shared/store/shop2.jpg'
  315. act 'Leave the cosmetics department': gt 'shop', 'start'
  316. if $loc = 'torgcentr':gs 'shoplifting', 'city'
  317. if $loc = 'pav_commercial':gs 'shoplifting', 'pav'
  318. end
  319. if $shoplocation = 'hardware':
  320. $loc_s = 'shop'
  321. $args_s = 'hardware'
  322. *clr & cla
  323. if hour < 8 or hour > 20:
  324. 'The hardware department is currently closed.'
  325. act 'Leave':gt 'shop', 'start'
  326. exit
  327. end
  328. gs 'item_cart', 'shoppping_aisle', 'hardware'
  329. gs 'stat'
  330. gs 'themes', 'indoors'
  331. $backimage= 'images/locations/shared/store/shop3.jpg'
  332. act 'Leave the hardware department': gt 'shop', 'start'
  333. if pod_whore_countQW > 15 and paint_blue = 0 and money >= 200:
  334. act 'Buy paint to cover graffiti (200 <b>₽</b>)':
  335. money -= 200
  336. paint_blue = 1
  337. gt 'shop', '<font color="green">You bought a tin of paint.</font>'
  338. end
  339. end
  340. end
  341. if $shoplocation = 'clothing':
  342. *clr & cla
  343. '<center><b><font color="maroon">Department of Women''s Clothing</font></b></center>'
  344. '<center><img <<$set_imgh>> src="images/locations/shared/store/shop4.jpg"></center>'
  345. 'This department only sells cheap underwear and ice skates.'
  346. if hour < 8 or hour > 20:
  347. 'The women''s clothing department is currently closed.'
  348. act 'Leave':gt 'shop', 'start'
  349. exit
  350. else
  351. 'Women''s panties and bras 300<b>₽</b> each'
  352. gs 'stat'
  353. gs 'themes', 'indoors'
  354. act 'Leave the women''s clothing department': gt 'shop', 'start'
  355. act 'View underwear': $shoplocation = 'underwear' & gt 'shop'
  356. if mc_inventory['ice_skates'] ! 1:
  357. 'A pair of ice-skates are available for 3000 <b>₽</b>.'
  358. if money >= 3000:
  359. act 'Buy ice skates (3000 <b>₽</b>)':
  360. *clr & cla
  361. money -= 3000
  362. mc_inventory['ice_skates'] = 1
  363. '<center><img <<$set_imgh>> src="images/locations/pavlovsk/lake/konki_shop.jpg"></center>'
  364. 'You buy a pair of ice skates.'
  365. act 'Move away from the counter': gt'shop'
  366. end
  367. end
  368. end
  369. if mc_inventory['ski'] ! 1:
  370. 'A pair of skis and poles are available for 4000 <b>₽</b>.'
  371. if money >= 4000:
  372. act 'Buy skis (4000 <b>₽</b>)':
  373. *clr & cla
  374. money -= 4000
  375. mc_inventory['ski'] = 1
  376. '<center><img <<$set_imgh>> src="images/pc/activities/ski_buy.jpg"></center>'
  377. 'You buy a pair of skis and poles.'
  378. act 'Move away from the counter': gt'shop'
  379. end
  380. end
  381. end
  382. end
  383. end
  384. !! Women''s clothing underwear viewer
  385. if $shoplocation = 'underwear':
  386. *clr & cla
  387. if $loc ! 'shop': $loc_bak = $loc
  388. $loc = 'shop'
  389. '<center><B>Click on an item to view details</B></center>'
  390. if gm_panties[7] = 0: *p '<a href="exec:gt ''panties'', ''view_panty_item'', ''shop'', ''gm'', 7, 300"><img src="images/pc/items/gm/panties/7.jpg" height="150" /></a>'
  391. if gm_panties[9] = 0: *p '<a href="exec:gt ''panties'', ''view_panty_item'', ''shop'', ''gm'', 9, 300"><img src="images/pc/items/gm/panties/9.jpg" height="150" /></a>'
  392. if gm_panties[12] = 0: *p '<a href="exec:gt ''panties'', ''view_panty_item'', ''shop'', ''gm'', 12, 300"><img src="images/pc/items/gm/panties/12.jpg" height="150" /></a>'
  393. if gm_panties[21] = 0: *p '<a href="exec:gt ''panties'', ''view_panty_item'', ''shop'', ''gm'', 21, 300"><img src="images/pc/items/gm/panties/21.jpg" height="150" /></a>'
  394. if gm_panties[37] = 0: *p '<a href="exec:gt ''panties'', ''view_panty_item'', ''shop'', ''gm'', 37, 300"><img src="images/pc/items/gm/panties/37.jpg" height="150" /></a>'
  395. *nl
  396. if gm_bras[11] = 0: *p '<a href="exec:gt ''bras'', ''view_bra_item'', ''shop'', ''gm'', 11, 300"><img src="images/pc/items/gm/bras/11.jpg" height="150" /></a>'
  397. if gm_bras[12] = 0: *p '<a href="exec:gt ''bras'', ''view_bra_item'', ''shop'', ''gm'', 12, 300"><img src="images/pc/items/gm/bras/12.jpg" height="150" /></a>'
  398. if gm_bras[16] = 0: *p '<a href="exec:gt ''bras'', ''view_bra_item'', ''shop'', ''gm'', 16, 300"><img src="images/pc/items/gm/bras/16.jpg" height="150" /></a>'
  399. if gm_bras[18] = 0: *p '<a href="exec:gt ''bras'', ''view_bra_item'', ''shop'', ''gm'', 18, 300"><img src="images/pc/items/gm/bras/18.jpg" height="150" /></a>'
  400. act 'Return':
  401. $loc = $loc_bak
  402. $shoplocation = 'clothing'
  403. gt 'shop'
  404. end
  405. end
  406. !! Household appliances
  407. if $shoplocation = 'tech':
  408. $loc_s = 'shop'
  409. $args_s = 'tech'
  410. *clr & cla
  411. if hour < 8 or hour > 20:
  412. 'The household appliance department is currently closed.'
  413. act 'Leave': $backimage= '' & gt 'shop', 'start'
  414. exit
  415. end
  416. gs 'item_cart', 'shoppping_aisle', 'tech'
  417. gs 'stat'
  418. gs 'themes', 'indoors'
  419. $backimage= 'images/locations/shared/store/shop5.jpg'
  420. !! mc_inventory['tech_game_ds'] and mc_inventory['tech_webcam'] need a mc_inventory['tech_computer'] requirement
  421. !! also for some reason mc_inventory['tech_webcam'] doesn't work.
  422. !! It shows up as an item and you can put it into the item cart but buying it doesn't increase the value of mc_inventory['tech_webcam'].
  423. !!also having a Plasma TV shows up as having 2 TVs since I couldn''t change TV = 2 to a new variables without changing a lot of code and text.
  424. act 'Leave the appliance department': $backimage= '' & gt 'shop', 'start'
  425. end
  426. !! Ice cream counter
  427. if $shoplocation = 'icecream':
  428. '<center><img <<$set_imgh>> src="images/shared/store/icecreamcounter.jpg"></center>'
  429. 'Ice cream is available for 50 <b>₽</b>.'
  430. act 'Move away from the counter':gt 'shop', 'start'
  431. if money >= 50:
  432. act 'Buy ice cream':
  433. *clr & cla
  434. money -= 50
  435. fat += 3
  436. pcs_mood += 50
  437. pcs_hydra += 60
  438. pcs_energy += 30
  439. cumspclnt = 2
  440. gs 'cum_cleanup'
  441. pcs_breath = 0
  442. gs 'stat'
  443. '<center><img <<$set_imgh>> src="images/shared/food/icecreem.jpg"></center>'
  444. 'You buy some ice cream and eat it.'
  445. act 'Move away from the counter':gt 'shop', 'start'
  446. end
  447. end
  448. end
  449. if $shoplocation = 'megafon':
  450. *clr & cla
  451. minut+=3
  452. gs'stat'
  453. '<center><b><font color = maroon>MegaFon shop</font></b></center>'
  454. '<center><img src="images/system/phone/megafon2.jpg" ></center>'
  455. $tables = '<center><table>'
  456. $tablec = '</table></center>'
  457. if bankAccount = 0: '<center><h4>You need a valid bank account to buy monthly contracts.</h4></center>'
  458. $title = '<center><h4>Home Internet Subscription</h4></cemter>'
  459. price = 900
  460. if $home['current'] = 'parents_home':
  461. $line = '<tr><td align="center">Your parents are paying for the internet at home, and you can''t take out a second internet subscriptions for the same address</td></tr>'
  462. elseif property['internet_enabled'] = 0:
  463. $line = '<tr><td align="center">You can''t buy an internet subscription for <<$home[''display'']>></td></tr>'
  464. elseif subscription[$home['current']] = 1:
  465. $temp_home = '<<$home[''current'']>>-date'
  466. $line = '<tr><td align="center">You have an active internet subscription at <<$home[''display'']>> that will renew next month on day <<subscription[$temp_home]>> for <<price>> <b>₽</b></td></tr>'
  467. killvar '$temp_home'
  468. else
  469. $line = '<tr><td style="padding-left: 10px; padding-right: 10px; align: left; ">Monthly internet subscription for <<price>><b>₽</b> at your <<$home[''display'']>>. Automatically renews every month</td>'
  470. if bankAccount = 0:
  471. $line += '<td style="padding-left: 10px; padding-right: 10px;">No bank account</td></tr>'
  472. elseif karta+bankDebtLimit >= price:
  473. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''buy_subscription'', ''<<$home[''current'']>>'', <<price>>, 0 & minut += 30 & karta -= <<price>> & gs ''stat'' & gt ''shop'' ">Pay with Card</a></td></tr>'
  474. else
  475. $line += '<td style="padding-left: 10px; padding-right: 10px;">Insufficient balance</td></tr>'
  476. end
  477. end
  478. '<<$title>><<$tables>><<$line>><<$tablec>>'
  479. killvar 'line'
  480. killvar 'title'
  481. !! "Returns":
  482. !! $property_code[], $property_name[], $property_status[], property__is_current_home[]
  483. !! $property_stat values: 'rented', 'owned', 'tenants', 'no access'
  484. gs 'homes_properties', 'get_internet_enabled_properties', 'home', 'hasaccess'
  485. count = ARRSIZE('$property_name')
  486. if count > 0:
  487. :propertyloop
  488. if property__is_current_home[i] = 0:
  489. $title = '<center><h4>Internet Subscription for your other properties</h4></center>'
  490. if $property_status[i] = 'tenants':
  491. $line += '<tr><td align="center">You have rented out the <<LCASE($property_name[i])>> and you don''t have to buy internet for our tenants.</td></tr>'
  492. elseif subscription[$property_code[i]] = 0:
  493. $line += '<tr><td style="padding-left: 10px; padding-right: 10px; align: left; ">Monthly internet subscription for <<price>> <b>₽</b> at <<LCASE($property_name[i])>>. Automatically renews every month</td>'
  494. if bankAccount = 0:
  495. $line += '<td style="padding-left: 10px; padding-right: 10px;">No bank account</td></tr>'
  496. elseif karta+bankDebtLimit >= price:
  497. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''buy_subscription'', ''<<$property_code[i]>>'', <<price>>, 0 & minut += 30 & karta -= <<price>> & gs ''stat'' & gt ''shop'' ">Pay with card</a></td></tr>'
  498. else
  499. $line += '<td style="padding-left: 10px; padding-right: 10px;">Insufficient balance</td></tr>'
  500. end
  501. elseif subscription[$property_code[i]] > 0:
  502. $line += '<tr><td align="center">You have an active internet subscription for the <<LCASE($property_name[i])>> that will renew next month on day <<subscription[''<<$property_code[i]>>-date'']>> for <<price>> <b>₽</b></td></tr>'
  503. end
  504. end
  505. killvar '$property'
  506. i += 1
  507. if i < count: jump 'propertyloop'
  508. gs 'homes_properties', 'clean_up_property_data'
  509. killvar 'i' & killvar 'count'
  510. if $title ! '' : '<<$title>><<$tables>><<$line>><<$tablec>>'
  511. killvar 'line' & killvar 'title'
  512. end
  513. $title = '<center><h4>Mobile Internet Subscription</h4></center>'
  514. price = 1200
  515. if subscription['mobile'] = 1:
  516. $line = '<tr><td align="center">You have an active mobile internet subscription that will renew next month on day <<subscription[''mobile-date'']>> for <<price>><b>₽</b></td></tr>'
  517. else
  518. if subscription['metered_mobile'] > 0:
  519. !! Every 12 minutes gives back 1 ₽
  520. discount = subscription['metered_mobile'] / 12
  521. discount_left = max(price - discount, 0)
  522. $line = '<tr><td align="center">You still a have <b><<subscription[''metered_mobile'']>> ₽</b> balance for your metered mobile internet which gives you a <<discount>> <b>₽</b> discount</td></tr>'
  523. end
  524. $line += '<tr><td style="padding-left: 10px; padding-right: 10px; align: left; ">Monthly mobile internet subscription for'+iif(discount > 0, ' <s><<price>></s><<price-discount>>', ' <<price>>')+'<b>₽</b>. Automatically renews every month</td>'
  525. if bankAccount = 1 and karta + bankDebtLimit >= (price - discount): $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''buy_subscription'', ''mobile'', <<price>>, <<discount_left>> & gs ''internet_mobile'', ''cancel_subscription'', ''metered_mobile'' & minut += 30 & karta -= <<price-discount>> & gs ''stat'' & gt ''shop'' ">Pay with card</a></td></tr>'
  526. if bankAccount = 1 and karta + bankDebtLimit < (price - discount): $line += '<td style="padding-left: 10px; padding-right: 10px;">Insufficient funds</td></tr>'
  527. if bankAccount = 0: $line += '<td style="padding-left: 10px; padding-right: 10px;">No bank account</td></tr>'
  528. end
  529. '<<$title>><<$tables>><<$line>><<$tablec>>'
  530. killvar 'line'
  531. killvar 'title'
  532. $title = '<center><h4>Metered Internet</h4></center>'
  533. if subscription['mobile'] = 1:
  534. $line = '<tr><td align="center">You have an active mobile internet subscription for unlimited use, you can''t buy extra minutes </td></tr>'
  535. $line += '<tr><td align="left"><b>300 minutes</b> (5 hours) of mobile internet for 80 <b>₽</b></td></tr>'
  536. $line += '<tr><td align="left"><b>600 minutes</b> (10 hours) of mobile internet for 155 <b>₽</b></td></tr>'
  537. $line += '<tr><td align="left"><b>1200 minutes</b> (20 hours) of mobile internet for 295 <b>₽</b></td></tr>'
  538. $line += '<tr><td align="left"><b>3000 minutes</b> (50 hours) of mobile internet for 695 <b>₽</b></td></tr>'
  539. else
  540. $line = '<tr><td style="padding-left: 10px; padding-right: 10px; align: left; "><b>300 minutes</b> (5 hours) of mobile internet for 80<b>₽</b></td>'
  541. if money > 80:
  542. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_mobile'', 300 & money -= 80 & minut += 10 & gt ''shop'' ">Pay with cash</a></td>'
  543. else
  544. $line += '<td style="padding-left: 10px; padding-right: 10px;">Not enough cash</td>'
  545. end
  546. if bankAccount = 0:
  547. $line += '<td style="padding-left: 10px; padding-right: 10px;">No bank account</td></tr>'
  548. elseif karta+bankDebtLimit >= 80:
  549. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_mobile'', 300 & karta -= 80 & minut += 10 & gt ''shop'' ">Pay with card</a></td></tr>'
  550. else
  551. $line += '<td style="padding-left: 10px; padding-right: 10px;">Insufficient balance</td></tr>'
  552. end
  553. $line += '<tr><td style="padding-left: 10px; padding-right: 10px; align: left; "><b>600 minutes</b> (10 hours) of mobile internet for 115<b>₽</b></td>'
  554. if money > 155:
  555. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_mobile'', 600 & money -= 115 & minut += 10 & gt ''shop'' ">Pay with cash</a></td>'
  556. else
  557. $line += '<td style="padding-left: 10px; padding-right: 10px;">Not enough cash</td>'
  558. end
  559. if bankAccount = 0:
  560. $line += '<td style="padding-left: 10px; padding-right: 10px;">No bank account</td></tr>'
  561. elseif karta+bankDebtLimit >= 155:
  562. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_mobile'', 600 & karta -= 115 & minut += 10 & gt ''shop'' ">Pay with card</a></td></tr>'
  563. else
  564. $line += '<td style="padding-left: 10px; padding-right: 10px;">Insufficient balance</td></tr>'
  565. end
  566. $line += '<tr><td style="padding-left: 10px; padding-right: 10px; align: left; "><b>1200 minutes</b> (20 hours) of mobile internet for 295<b>₽</b></td>'
  567. if money > 295:
  568. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_mobile'', 1200 & money -= 295 & minut += 10 & gt ''shop'' ">Pay with cash</a></td>'
  569. else
  570. $line += '<td style="padding-left: 10px; padding-right: 10px;">Not enough cash</td>'
  571. end
  572. if bankAccount = 0:
  573. $line += '<td style="padding-left: 10px; padding-right: 10px;">No bank account</td></tr>'
  574. elseif karta+bankDebtLimit >= 295:
  575. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_mobile'', 1200 & karta -= 295 & minut += 10 & gt ''shop'' ">Pay with card</a></td></tr>'
  576. else
  577. $line += '<td style="padding-left: 10px; padding-right: 10px;">Insufficient balance</td></tr>'
  578. end
  579. $line += '<tr><td style="padding-left: 10px; padding-right: 10px; align: left; "><b>3000 minutes</b> (50 hours) of mobile internet for 695<b>₽</b></td>'
  580. if money > 695:
  581. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_mobile'', 3000 & money -= 695 & minut += 10 & gt ''shop'' ">Pay with cash</a></td>'
  582. else
  583. $line += '<td style="padding-left: 10px; padding-right: 10px;">Not enough cash</td>'
  584. end
  585. if bankAccount = 0:
  586. $line += '<td style="padding-left: 10px; padding-right: 10px;">No bank account</td></tr>'
  587. elseif karta+bankDebtLimit >= 695:
  588. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_mobile'', 3000 & karta -= 695 & minut += 10 & gt ''shop'' ">Pay with card</a></td></tr>'
  589. else
  590. $line += '<td style="padding-left: 10px; padding-right: 10px;">Insufficient balance</td></tr>'
  591. end
  592. end
  593. '<<$title>><<$tables>><<$line>><<$tablec>>'
  594. killvar 'line'
  595. killvar 'title'
  596. '<center>You have <b><<subscription[''metered_mobile'']>></b> minutes for mobile internet use</center>'
  597. $title = '<center><h4>Mobile Calls and Texts</h4></center>'
  598. price = 800
  599. if subscription['monthly_calls'] = 1:
  600. $line += '<tr><td align="center">You have an active mobile subscription that will renew next month on day <<subscription[''monthly_calls-date'']>> for <<price>> <b>₽</b></td></tr>'
  601. else
  602. if subscription['metered_calls'] > 0:
  603. discount = subscription['metered_calls'] / 2
  604. discount_left = max(price - discount, 0)
  605. $line += '<tr><td align="center">You have <b><<subscription[''metered_calls'']>>₽</b> for mobile calls and text messages which gives you a <<discount>> <b>₽</b> discount</td></tr>'
  606. end
  607. $line += '<tr><td style="padding-left: 10px; padding-right: 10px; align: left;">Monthly mobile subscription that allows you to make calls and send text messages for'+iif(discount > 0, '<b><s><<price>></s></b> <span color="red"><b><<price-discount>></b></span>', ' <b><<price>></b>')+'<b>₽</b> Automatically renews every month</td>'
  608. if bankAccount = 1 and karta + bankDebtLimit >= (price - discount): $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''buy_subscription'', ''monthly_calls'', <<price>>, <<discount_left>> & gs ''internet_mobile'', ''cancel_subscription'', ''metered_calls'' & minut += 30 & karta -= <<price>> & gs ''stat'' & gt ''shop'' ">Pay with card</a></td></tr>'
  609. if bankAccount = 1 and karta + bankDebtLimit < (price - discount): $line += '<td style="padding-left: 10px; padding-right: 10px;">Insufficient funds</td></tr>'
  610. if bankAccount = 0: $line += '<td style="padding-left: 10px; padding-right: 10px;">No bank account</td></tr>'
  611. end
  612. '<<$title>><<$tables>><<$line>><<$tablec>>'
  613. killvar 'title'
  614. killvar 'line'
  615. $title = '<center><h4>Metered Calls and Texts</h4></center>'
  616. if subscription['monthly_calls'] = 1:
  617. $line += '<tr><td>You have an active mobile subscription with unlimited minutes and texts, you can''t buy extra minutes</td></tr>'
  618. else
  619. $line += '<tr><td style="padding-left: 10px; padding-right: 10px; align: left;">60<b>₽</b> call pack for your mobile phone that gives you 60 minutes of calltime and 120 text messages</td>'
  620. if money >= 60:
  621. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_calls'', 60, 120 & money -= 60 & minut += 10 & gt ''shop'' ">Pay with cash</a></td>'
  622. else
  623. $line += '<td style="padding-left: 10px; padding-right: 10px;">Not enough cash</td>'
  624. end
  625. if bankAccount = 0:
  626. $line += '<td style="padding-left: 10px; padding-right: 10px;">No bank account</td></tr>'
  627. elseif bankAccount = 1 and karta+bankDebtLimit >= 60:
  628. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_calls'', 60, 120 & karta -= 60 & minut += 10 & gt ''shop'' ">Pay with card</a></td></tr>'
  629. else
  630. $line += '<td style="padding-left: 10px; padding-right: 10px;">Insufficient balance</td></tr>'
  631. end
  632. $line += '<tr><td style="padding-left: 10px; padding-right: 10px; align: left;">115<b>₽</b> call pack for your mobile phone that gives you 120 minutes of calltime and 240 text messages</td>'
  633. if money >= 115:
  634. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_calls'', 120, 240 & money -= 115 & minut += 10 & gt ''shop'' ">Pay with cash</a></td>'
  635. else
  636. $line += '<td style="padding-left: 10px; padding-right: 10px;">Not enough cash</td>'
  637. end
  638. if bankAccount = 0:
  639. $line += '<td style="padding-left: 10px; padding-right: 10px;">No bank account</td></tr>'
  640. elseif bankAccount = 1 and karta + bankDebtLimit >= 115:
  641. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_calls'', 120, 240 & karta -= 115 & minut += 10 & gt ''shop'' ">Pay with card</a></td></tr>'
  642. else
  643. $line += '<td style="padding-left: 10px; padding-right: 10px;">Insufficient balance</td></tr>'
  644. end
  645. $line += '<tr><td style="padding-left: 10px; padding-right: 10px; align: left;">170<b>₽</b> call pack for your mobile phone that gives you 180 minutes of calltime and 360 text messages</td>'
  646. if money >= 170:
  647. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_calls'', 180, 360 & money -= 170 & minut += 10 & gt ''shop'' ">Pay with cash</a></td>'
  648. else
  649. $line += '<td style="padding-left: 10px; padding-right: 10px;">Not enough cash</td>'
  650. end
  651. if bankAccount = 0:
  652. $line += '<td style="padding-left: 10px; padding-right: 10px;">No bank account</td></tr>'
  653. elseif bankAccount = 1 and karta + bankDebtLimit >= 170:
  654. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_calls'', 180, 360 & karta -= 170 & minut += 10 & gt ''shop'' ">Pay with card</a></td></tr>'
  655. else
  656. $line += '<td style="padding-left: 10px; padding-right: 10px;">Insufficient balance</td></tr>'
  657. end
  658. $line += '<tr><td style="padding-left: 10px; padding-right: 10px; align: left;">225<b>₽</b> call pack for your mobile phone that gives you 240 minutes of calltime and 480 text messages</td>'
  659. if money >= 225:
  660. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_calls'', 240, 480 & money -= 225 & minut += 10 & gt ''shop'' ">Pay with cash</a></td>'
  661. else
  662. $line += '<td style="padding-left: 10px; padding-right: 10px;">Not enough cash</td>'
  663. end
  664. if bankAccount = 0:
  665. $line += '<td style="padding-left: 10px; padding-right: 10px;">No bank account</td></tr>'
  666. elseif bankAccount = 1 and karta + bankDebtLimit >= 225:
  667. $line += '<td style="padding-left: 10px; padding-right: 10px;"><a href="exec: gs ''internet_mobile'', ''top_up_metered'', ''metered_calls'', 240, 480 & karta -=225 & minut += 10 & gt ''shop'' ">Pay with card</a></td></tr>'
  668. else
  669. $line += '<td style="padding-left: 10px; padding-right: 10px;">Insufficient balance</td></tr>'
  670. end
  671. end
  672. '<<$title>><<$tables>><<$line>><<$tablec>>'
  673. '<center>You have <b><<subscription[''metered_calls'']>> minutes</b> for mobile calls and <<subscription[''sms_limit'']>> text messages</center>'
  674. killvar 'title'
  675. killvar 'line'
  676. killvar 'discount'
  677. killvar 'discount_left'
  678. killvar 'price'
  679. act 'Return to the supermarket': gt'shop','start'
  680. end
  681. if $shoplocation = 'Anya':
  682. cla
  683. '<center><img <<$set_imgh>> src="images/characters/pavlovsk/resident/anya/anyabusywork.jpg"></center>'
  684. gs 'sister_chat', 'checks'
  685. '"Don''t disturb me at work, <<$pcs_nickname>>! Can''t you see that I have customers?"'
  686. act 'Move away': gt'shop','start'
  687. end
  688. --- shop ---------------------------------