home *** CD-ROM | disk | FTP | other *** search
/ AMIGA PD 1 / AMIGA-PD-1.iso / Programme_zum_Heft / Programmieren / Kurztests / ACE / Prgs / include / petr.lha / Example.b next >
Text File  |  1995-01-31  |  1KB  |  82 lines

  1. #include <Petr.h>
  2.  
  3. screen 1,640,256,2,2  
  4. window 1,,(0,0)-(640,256),32,1
  5.  palette 0,0,0.2,0
  6.  palette 1,1,1,1
  7.  palette 2,.2,0,1
  8.  palette 3,.8,.4,0
  9.  
  10. font "topaz",8    '..(This helps for the purposes of the demo. DB)
  11.  
  12. locate 5,5
  13. prints " Include `mys`, press left mouse button"
  14. Mys
  15. locate 15,10
  16. prints "Pressed left mouse button at position ";m.a;",";m.b
  17.  
  18. waitmouse
  19. pause(5)
  20. CLS
  21.  
  22. box(100,540,50,150,3,1)
  23. locate 12,20
  24. prints " This is made by include `BOX` "
  25. waitmouse
  26. pause(5)
  27.  
  28. color 2,3
  29. CLS
  30.  
  31. gline(10,10,22,0)
  32. prints " Include `Gline` up"
  33. gline(15,10,22,1)
  34. prints " Include `Gline` down"
  35. waitmouse
  36.  
  37. Again:
  38. color 1,2
  39. CLS
  40. locate 5,10
  41. prints "Input by include in$"
  42.  
  43. a$=in$(10,10," Insert any numeric value : ","123.456",8)
  44. locate 12,10
  45. prints " Inserted : ";a$
  46. locate 15,10
  47. prints " Include`s `Using` output of given value is ";Using$("#####.##",Val(NoSpace$(a$)),1)
  48. waitmouse
  49. CLS
  50.  
  51. locate 3,5
  52. prints " Include GAD used with include box : "
  53.  
  54.  
  55.     box(130,470,75,140,2,1)
  56.     box(150,450,85,130,3,0)
  57.     color 1,3
  58.     LOCATE 13,22
  59.     PrintS "Do you want to try in$ again ?"
  60.     t$(1)="yes"
  61.     t$(2)="no"
  62.     tg%(1,1)=15%
  63.     tg%(1,2)=25%
  64.     tg%(1,3)=5%
  65.     tg%(2,1)=15%
  66.     tg%(2,2)=47%
  67.     tg%(2,3)=4%
  68.    tg%(3,3)=0%
  69.   i=GAD%
  70. if i= 1 then again
  71.  
  72. color 1,0
  73. cls
  74. locate 10,10
  75. prints "so bye, be happy"
  76. locate 24,50
  77. prints "Oh - that is include waitmouse"
  78. waitmouse
  79. window close 1
  80. screen close 1
  81. END
  82.