1
0

bank 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. # bank
  2. if $ARGS[0] = 'start':
  3. cla
  4. clr
  5. *clr
  6. minut += 5
  7. gs 'stat'
  8. fcolor = rgb(0, 0, 0)
  9. bcolor = rgb(255, 255, 255)
  10. lcolor = rgb(106, 90, 205)
  11. '<center><b><font color="maroon">Bank</font></b></center>'
  12. '<center><img src="images/etogame/bank.jpg"></center>'
  13. if bankAccount = 0:
  14. 'Do you want to open your account?'
  15. else
  16. if karta >= 0:
  17. 'You have <<karta>> <b>₽</b> in your account.'
  18. 'You have an approved credit of <font color="blue"><<bankDebtLimit>></font>!'
  19. else
  20. 'You hava a debt of <font color="red"><<-1 * karta>></font> <b>₽</b>.'
  21. 'You have an approved credit of <font color="blue"><<bankDebtLimit + karta>></font>!'
  22. end
  23. end
  24. if BankPapper = 1 and dayBankPapper = daystart:
  25. act 'Give documents':
  26. cls
  27. minut += 15
  28. BankPapper = 2
  29. gs 'stat'
  30. 'You went to the office and gave the documents to the manager.'
  31. act 'Leave':minut += 5 & gt 'down'
  32. end
  33. end
  34. if money > 0:
  35. act 'Deposit money':
  36. cla
  37. minut += 5
  38. kartaIN = input ("How much money you want to deposit into the account?")
  39. if kartaIN <= 0 or kartaIN > money:
  40. 'Not correct operation.'
  41. else
  42. karta += kartaIN
  43. money -= kartaIN
  44. if bankAccount = 0:
  45. bankAccount = 1
  46. bankDebtLimit = 5000
  47. end
  48. '<br>You put on the account <<kartaIN>> <b>₽</b>, now you have <<karta>> <b>₽</b> on it.'
  49. end
  50. act 'Move away':gt 'bank', 'start'
  51. end
  52. end
  53. if karta + bankDebtLimit > 0:
  54. act 'Withdraw money':
  55. cla
  56. minut += 5
  57. kartaOUT = input ("How much do you want to withdraw from account?")
  58. if kartaOUT <= 0 or kartaOUT > karta + bankDebtLimit:
  59. 'Not correct operation.'
  60. else
  61. karta -= kartaOUT
  62. money += kartaOUT
  63. '<br>You debited <<kartaOUT>> <b>₽</b>, now you have <<karta>> <b>₽</b> on it.'
  64. end
  65. act 'Move away':gt 'bank', 'start'
  66. end
  67. end
  68. act 'Leave':gt 'down'
  69. end
  70. --- bank ---------------------------------