091_saunabed 1018 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. # saunabed
  2. $metka = $ARGS[0]
  3. $loc = $CURLOC
  4. gs 'stat'
  5. '<center><b>bed</b></center>'
  6. '<center><img src="images/pics/son.jpg"></center>'
  7. if son < 10:
  8. if budon = 1:
  9. act 'Sleep before the alarm in <<alarm1>> hours <<alarm2>> minutes':
  10. cls
  11. inSleep = 1
  12. :markson
  13. needminut = 60 - minut
  14. sec += needminut * 60
  15. son += 3
  16. gs 'stat'
  17. if son >= 23 or alarm1 = hour and alarm2 = minut:
  18. inSleep = 2
  19. gt $locBroom, $metkaBroom
  20. else
  21. jump 'markson'
  22. end
  23. end
  24. end
  25. act 'Sleep as you want':
  26. cls
  27. inSleep = 1
  28. :markson
  29. needminut = 60 - minut
  30. sec += needminut * 60
  31. son += 3
  32. gs 'stat'
  33. if son < 23:jump 'markson'
  34. inSleep = 2
  35. gt $locBroom, $metkaBroom
  36. end
  37. end
  38. if budon = 1:
  39. 'Clock wound <<alarm1>> hours <<alarm2>> minutes'
  40. act 'Disable the alarm':budon = 0 & gt $curloc
  41. else
  42. act 'Enable Service':budon = 1 & gt $curloc
  43. end
  44. act 'set the alarm time':gt 'saunabud'
  45. act 'Get out of bed':sec += 5 & gt $locBroom, $metkaBroom
  46. --- saunabed ---------------------------------