1
0

bank.qsrc 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. # bank
  2. if $ARGS[0] = 'start':
  3. cla
  4. *clr
  5. minut += 2
  6. gs 'stat'
  7. gs 'themes', 'indoors'
  8. '<center><b><font color="maroon">Bank</font></b></center>'
  9. '<center><img <<$set_imgh>> src="images/locations/city/citycenter/bank/bank.jpg"></center>'
  10. if week <= 5 and hour = 16 and minut >= 30 and mey_vika['mey_vika_qw'] >= 32:
  11. !r125
  12. 'Seems like <a href="exec:gs''mey_tamara_events'',''tamara''">Tamara Mikhailovna</a> is heading home.'
  13. end
  14. if bankAccount = 0:
  15. 'Do you want to open an account?'
  16. else
  17. if karta >= 0:
  18. 'You have <<karta>> <b>₽</b> in your account.'
  19. 'You can take out a loan of <font color="blue"><<bankDebtLimit>></font>!'
  20. else
  21. 'You hava a debt of <font color="red"><<-1 * karta>></font> <b>₽</b>.'
  22. 'You can take out a loan of <font color="blue"><<bankDebtLimit + karta>></font>!'
  23. end
  24. end
  25. if BankPapper = 1 and dayBankPapper = daystart:
  26. act 'Show documents':
  27. cls
  28. minut += 15
  29. BankPapper = 2
  30. gs 'stat'
  31. 'You went to the office and showed the required documents to the manager.'
  32. act 'Leave':
  33. minut += 5
  34. if bankloc = 1:
  35. gt 'down'
  36. else
  37. gt 'pavCommercial'
  38. end
  39. end
  40. end
  41. end
  42. if money > 0:
  43. act 'Deposit money':
  44. cla
  45. kartaIN = input ("How much money you want to deposit into the account?")
  46. if kartaIN <= 0 or kartaIN > money:
  47. 'That is not a valid operation.'
  48. else
  49. karta += kartaIN
  50. money -= kartaIN
  51. if bankAccount = 0:
  52. bankAccount = 1
  53. bankDebtLimit = 5000
  54. end
  55. '<br>You deposited <<kartaIN>> <b>₽</b>, your account balance is now <<karta>> <b>₽</b>.'
  56. end
  57. act 'Walk away':gt 'bank', 'start'
  58. end
  59. end
  60. if karta + bankDebtLimit > 0:
  61. act 'Withdraw money':
  62. cla
  63. kartaOUT = input ("How much do you want to withdraw from account?")
  64. if kartaOUT <= 0 or kartaOUT > karta + bankDebtLimit:
  65. 'That is not a valid operation.'
  66. else
  67. karta -= kartaOUT
  68. money += kartaOUT
  69. if karta > 0:
  70. '<br>You withdraw <<kartaOUT>> <b>₽</b>. You have <<karta>> <b>₽</b> left in your bank account.'
  71. elseif karta = 0:
  72. '<br>You withdraw <<kartaOUT>> <b>₽</b>. You have no money left in your bank account.'
  73. else
  74. '<br>You withdraw <<kartaOUT>> <b>₽</b>. <font color="red">Your bank account is overdrawn by <b><<karta>> ₽</b>.</font>'
  75. end
  76. end
  77. act 'Walk away':gt 'bank', 'start'
  78. end
  79. end
  80. act 'Leave':
  81. minut += 2
  82. if bankloc = 1:
  83. gt 'down'
  84. else
  85. gt 'pavCommercial'
  86. end
  87. end
  88. end
  89. --- bank ---------------------------------