Home » Archimedes archive » Archimedes World » AW-1994-02-Disc1.adf » Disk1Feb94 » !AWFeb94/Goodies/Basic/House/Housey4

!AWFeb94/Goodies/Basic/House/Housey4

This website contains an archive of files for the Acorn Electron, BBC Micro, Acorn Archimedes, Commodore 16 and Commodore 64 computers, which Dominic Ford has rescued from his private collection of floppy disks and cassettes.

Some of these files were originally commercial releases in the 1980s and 1990s, but they are now widely available online. I assume that copyright over them is no longer being asserted. If you own the copyright and would like files to be removed, please contact me.

Tape/disk: Home » Archimedes archive » Archimedes World » AW-1994-02-Disc1.adf » Disk1Feb94
Filename: !AWFeb94/Goodies/Basic/House/Housey4
Read OK:
File size: 0520 bytes
Load address: 0000
Exec address: 0000
File contents
    1MODE MODE
    2LIBRARY "PathLib:OS_units.Paths"
    3LIBRARY "PathLib:OS_units.Transforms"
    4ORIGIN 640,512
    5PROCCreate_House
    6PROCCreateTransform
    7PROCDrawObjects
    8END
    9
   10DEF PROCCreateTransform
   11 PROCPath_CreateTransform(rotmag%)
   12 PROCPath_Rotation(rotmag%,PI/16)
   13 PROCPath_Magnify(rotmag%,.95)
   14ENDPROC
   15
   16DEF PROCDrawObjects
   17 REPEAT
   18  SYS "Draw_Stroke",house%
   19  PROCPath_Transform(house%,rotmag%)
   20  x$=GET$
   21 UNTIL FALSE
   22ENDPROC
   23
   24DEF PROCCreate_House
   25PROCPath_ObjectBegin(house%,200)
   26 x%=0 : y%=0 : w%=400 : h%=300
   27 PROCPath_Rectangle(x%+w%DIV2,y%+h%DIV2,w%,h%)            : REM body of house
   28 PROCPath_Rectangle(x%+w%DIV2,y%+h%DIV6,w%DIV8,h%DIV3)    : REM door
   29 PROCPath_Rectangle(x%+w%DIV4,y%+2*h%DIV3,w%DIV8,h%DIV4)  : REM window
   30  PROCPath_Move(x%+3*w%DIV16,y%+2*h%DIV3)
   31  PROCPath_Draw(x%+5*w%DIV16,y%+2*h%DIV3)
   32  PROCPath_Move(x%+w%DIV4,y%+2*h%DIV3-h%DIV8)
   33  PROCPath_Draw(x%+w%DIV4,y%+2*h%DIV3+h%DIV8)
   34 PROCPath_Rectangle(x%+3*w%DIV4,y%+2*h%DIV3,w%DIV8,h%DIV4): REM window
   35  PROCPath_Move(x%+11*w%DIV16,y%+2*h%DIV3)
   36  PROCPath_Draw(x%+13*w%DIV16,y%+2*h%DIV3)
   37  PROCPath_Move(x%+3*w%DIV4,y%+2*h%DIV3-h%DIV8)
   38  PROCPath_Draw(x%+3*w%DIV4,y%+2*h%DIV3+h%DIV8)
   39 PROCPath_Move(x%,y%+h%)                                  : REM Roof
   40  PROCPath_Draw(x%+w%DIV8,y%+h%+h%DIV4)
   41  PROCPath_Draw(x%+7*w%DIV8,y%+h%+h%DIV4)
   42  PROCPath_Draw(x%+w%,y%+h%)
   43 PROCPath_Rectangle(x%+w%DIV4+w%DIV32,y%+5*h%DIV4+h%DIV16,w%DIV16,h%DIV8)
   44PROCPath_ObjectEnd
   45ENDPROC
� �
ț "PathLib:OS_units.Paths"
$ț "PathLib:OS_units.Transforms"
ȑ 640,512
�Create_House
�CreateTransform
�DrawObjects
�
	

� �CreateTransform
# �Path_CreateTransform(rotmag%)
! �Path_Rotation(rotmag%,�/16)

 �Path_Magnify(rotmag%,.95)
�

� �DrawObjects
 �
  ș "Draw_Stroke",house%
%  �Path_Transform(house%,rotmag%)

  x$=�
 � �
�

� �Create_House
!�Path_ObjectBegin(house%,200)
" x%=0 : y%=0 : w%=400 : h%=300
H �Path_Rectangle(x%+w%�2,y%+h%�2,w%,h%)            : � body of house
; �Path_Rectangle(x%+w%�2,y%+h%�6,w%�8,h%�3)    : � door
= �Path_Rectangle(x%+w%�4,y%+2*h%�3,w%�8,h%�4)  : � window
&  �Path_Move(x%+3*w%�16,y%+2*h%�3)
&  �Path_Draw(x%+5*w%�16,y%+2*h%�3)
 (  �Path_Move(x%+w%�4,y%+2*h%�3-h%�8)
!(  �Path_Draw(x%+w%�4,y%+2*h%�3+h%�8)
"= �Path_Rectangle(x%+3*w%�4,y%+2*h%�3,w%�8,h%�4): � window
#'  �Path_Move(x%+11*w%�16,y%+2*h%�3)
$'  �Path_Draw(x%+13*w%�16,y%+2*h%�3)
%*  �Path_Move(x%+3*w%�4,y%+2*h%�3-h%�8)
&*  �Path_Draw(x%+3*w%�4,y%+2*h%�3+h%�8)
'C �Path_Move(x%,y%+h%)                                  : � Roof
($  �Path_Draw(x%+w%�8,y%+h%+h%�4)
)&  �Path_Draw(x%+7*w%�8,y%+h%+h%�4)
*  �Path_Draw(x%+w%,y%+h%)
+> �Path_Rectangle(x%+w%�4+w%�32,y%+5*h%�4+h%�16,w%�16,h%�8)
,�Path_ObjectEnd
-�
�
00000000  0d 00 01 07 eb 20 eb 0d  00 02 1f c8 9b 20 22 50  |..... ....... "P|
00000010  61 74 68 4c 69 62 3a 4f  53 5f 75 6e 69 74 73 2e  |athLib:OS_units.|
00000020  50 61 74 68 73 22 0d 00  03 24 c8 9b 20 22 50 61  |Paths"...$.. "Pa|
00000030  74 68 4c 69 62 3a 4f 53  5f 75 6e 69 74 73 2e 54  |thLib:OS_units.T|
00000040  72 61 6e 73 66 6f 72 6d  73 22 0d 00 04 0e c8 91  |ransforms"......|
00000050  20 36 34 30 2c 35 31 32  0d 00 05 11 f2 43 72 65  | 640,512.....Cre|
00000060  61 74 65 5f 48 6f 75 73  65 0d 00 06 14 f2 43 72  |ate_House.....Cr|
00000070  65 61 74 65 54 72 61 6e  73 66 6f 72 6d 0d 00 07  |eateTransform...|
00000080  10 f2 44 72 61 77 4f 62  6a 65 63 74 73 0d 00 08  |..DrawObjects...|
00000090  05 e0 0d 00 09 04 0d 00  0a 16 dd 20 f2 43 72 65  |........... .Cre|
000000a0  61 74 65 54 72 61 6e 73  66 6f 72 6d 0d 00 0b 23  |ateTransform...#|
000000b0  20 f2 50 61 74 68 5f 43  72 65 61 74 65 54 72 61  | .Path_CreateTra|
000000c0  6e 73 66 6f 72 6d 28 72  6f 74 6d 61 67 25 29 0d  |nsform(rotmag%).|
000000d0  00 0c 21 20 f2 50 61 74  68 5f 52 6f 74 61 74 69  |..! .Path_Rotati|
000000e0  6f 6e 28 72 6f 74 6d 61  67 25 2c af 2f 31 36 29  |on(rotmag%,./16)|
000000f0  0d 00 0d 1f 20 f2 50 61  74 68 5f 4d 61 67 6e 69  |.... .Path_Magni|
00000100  66 79 28 72 6f 74 6d 61  67 25 2c 2e 39 35 29 0d  |fy(rotmag%,.95).|
00000110  00 0e 05 e1 0d 00 0f 04  0d 00 10 12 dd 20 f2 44  |............. .D|
00000120  72 61 77 4f 62 6a 65 63  74 73 0d 00 11 06 20 f5  |rawObjects.... .|
00000130  0d 00 12 1d 20 20 c8 99  20 22 44 72 61 77 5f 53  |....  .. "Draw_S|
00000140  74 72 6f 6b 65 22 2c 68  6f 75 73 65 25 0d 00 13  |troke",house%...|
00000150  25 20 20 f2 50 61 74 68  5f 54 72 61 6e 73 66 6f  |%  .Path_Transfo|
00000160  72 6d 28 68 6f 75 73 65  25 2c 72 6f 74 6d 61 67  |rm(house%,rotmag|
00000170  25 29 0d 00 14 0a 20 20  78 24 3d be 0d 00 15 08  |%)....  x$=.....|
00000180  20 fd 20 a3 0d 00 16 05  e1 0d 00 17 04 0d 00 18  | . .............|
00000190  13 dd 20 f2 43 72 65 61  74 65 5f 48 6f 75 73 65  |.. .Create_House|
000001a0  0d 00 19 21 f2 50 61 74  68 5f 4f 62 6a 65 63 74  |...!.Path_Object|
000001b0  42 65 67 69 6e 28 68 6f  75 73 65 25 2c 32 30 30  |Begin(house%,200|
000001c0  29 0d 00 1a 22 20 78 25  3d 30 20 3a 20 79 25 3d  |)..." x%=0 : y%=|
000001d0  30 20 3a 20 77 25 3d 34  30 30 20 3a 20 68 25 3d  |0 : w%=400 : h%=|
000001e0  33 30 30 0d 00 1b 48 20  f2 50 61 74 68 5f 52 65  |300...H .Path_Re|
000001f0  63 74 61 6e 67 6c 65 28  78 25 2b 77 25 81 32 2c  |ctangle(x%+w%.2,|
00000200  79 25 2b 68 25 81 32 2c  77 25 2c 68 25 29 20 20  |y%+h%.2,w%,h%)  |
00000210  20 20 20 20 20 20 20 20  20 20 3a 20 f4 20 62 6f  |          : . bo|
00000220  64 79 20 6f 66 20 68 6f  75 73 65 0d 00 1c 3b 20  |dy of house...; |
00000230  f2 50 61 74 68 5f 52 65  63 74 61 6e 67 6c 65 28  |.Path_Rectangle(|
00000240  78 25 2b 77 25 81 32 2c  79 25 2b 68 25 81 36 2c  |x%+w%.2,y%+h%.6,|
00000250  77 25 81 38 2c 68 25 81  33 29 20 20 20 20 3a 20  |w%.8,h%.3)    : |
00000260  f4 20 64 6f 6f 72 0d 00  1d 3d 20 f2 50 61 74 68  |. door...= .Path|
00000270  5f 52 65 63 74 61 6e 67  6c 65 28 78 25 2b 77 25  |_Rectangle(x%+w%|
00000280  81 34 2c 79 25 2b 32 2a  68 25 81 33 2c 77 25 81  |.4,y%+2*h%.3,w%.|
00000290  38 2c 68 25 81 34 29 20  20 3a 20 f4 20 77 69 6e  |8,h%.4)  : . win|
000002a0  64 6f 77 0d 00 1e 26 20  20 f2 50 61 74 68 5f 4d  |dow...&  .Path_M|
000002b0  6f 76 65 28 78 25 2b 33  2a 77 25 81 31 36 2c 79  |ove(x%+3*w%.16,y|
000002c0  25 2b 32 2a 68 25 81 33  29 0d 00 1f 26 20 20 f2  |%+2*h%.3)...&  .|
000002d0  50 61 74 68 5f 44 72 61  77 28 78 25 2b 35 2a 77  |Path_Draw(x%+5*w|
000002e0  25 81 31 36 2c 79 25 2b  32 2a 68 25 81 33 29 0d  |%.16,y%+2*h%.3).|
000002f0  00 20 28 20 20 f2 50 61  74 68 5f 4d 6f 76 65 28  |. (  .Path_Move(|
00000300  78 25 2b 77 25 81 34 2c  79 25 2b 32 2a 68 25 81  |x%+w%.4,y%+2*h%.|
00000310  33 2d 68 25 81 38 29 0d  00 21 28 20 20 f2 50 61  |3-h%.8)..!(  .Pa|
00000320  74 68 5f 44 72 61 77 28  78 25 2b 77 25 81 34 2c  |th_Draw(x%+w%.4,|
00000330  79 25 2b 32 2a 68 25 81  33 2b 68 25 81 38 29 0d  |y%+2*h%.3+h%.8).|
00000340  00 22 3d 20 f2 50 61 74  68 5f 52 65 63 74 61 6e  |."= .Path_Rectan|
00000350  67 6c 65 28 78 25 2b 33  2a 77 25 81 34 2c 79 25  |gle(x%+3*w%.4,y%|
00000360  2b 32 2a 68 25 81 33 2c  77 25 81 38 2c 68 25 81  |+2*h%.3,w%.8,h%.|
00000370  34 29 3a 20 f4 20 77 69  6e 64 6f 77 0d 00 23 27  |4): . window..#'|
00000380  20 20 f2 50 61 74 68 5f  4d 6f 76 65 28 78 25 2b  |  .Path_Move(x%+|
00000390  31 31 2a 77 25 81 31 36  2c 79 25 2b 32 2a 68 25  |11*w%.16,y%+2*h%|
000003a0  81 33 29 0d 00 24 27 20  20 f2 50 61 74 68 5f 44  |.3)..$'  .Path_D|
000003b0  72 61 77 28 78 25 2b 31  33 2a 77 25 81 31 36 2c  |raw(x%+13*w%.16,|
000003c0  79 25 2b 32 2a 68 25 81  33 29 0d 00 25 2a 20 20  |y%+2*h%.3)..%*  |
000003d0  f2 50 61 74 68 5f 4d 6f  76 65 28 78 25 2b 33 2a  |.Path_Move(x%+3*|
000003e0  77 25 81 34 2c 79 25 2b  32 2a 68 25 81 33 2d 68  |w%.4,y%+2*h%.3-h|
000003f0  25 81 38 29 0d 00 26 2a  20 20 f2 50 61 74 68 5f  |%.8)..&*  .Path_|
00000400  44 72 61 77 28 78 25 2b  33 2a 77 25 81 34 2c 79  |Draw(x%+3*w%.4,y|
00000410  25 2b 32 2a 68 25 81 33  2b 68 25 81 38 29 0d 00  |%+2*h%.3+h%.8)..|
00000420  27 43 20 f2 50 61 74 68  5f 4d 6f 76 65 28 78 25  |'C .Path_Move(x%|
00000430  2c 79 25 2b 68 25 29 20  20 20 20 20 20 20 20 20  |,y%+h%)         |
00000440  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00000450  20 20 20 20 20 20 20 20  20 3a 20 f4 20 52 6f 6f  |         : . Roo|
00000460  66 0d 00 28 24 20 20 f2  50 61 74 68 5f 44 72 61  |f..($  .Path_Dra|
00000470  77 28 78 25 2b 77 25 81  38 2c 79 25 2b 68 25 2b  |w(x%+w%.8,y%+h%+|
00000480  68 25 81 34 29 0d 00 29  26 20 20 f2 50 61 74 68  |h%.4)..)&  .Path|
00000490  5f 44 72 61 77 28 78 25  2b 37 2a 77 25 81 38 2c  |_Draw(x%+7*w%.8,|
000004a0  79 25 2b 68 25 2b 68 25  81 34 29 0d 00 2a 1d 20  |y%+h%+h%.4)..*. |
000004b0  20 f2 50 61 74 68 5f 44  72 61 77 28 78 25 2b 77  | .Path_Draw(x%+w|
000004c0  25 2c 79 25 2b 68 25 29  0d 00 2b 3e 20 f2 50 61  |%,y%+h%)..+> .Pa|
000004d0  74 68 5f 52 65 63 74 61  6e 67 6c 65 28 78 25 2b  |th_Rectangle(x%+|
000004e0  77 25 81 34 2b 77 25 81  33 32 2c 79 25 2b 35 2a  |w%.4+w%.32,y%+5*|
000004f0  68 25 81 34 2b 68 25 81  31 36 2c 77 25 81 31 36  |h%.4+h%.16,w%.16|
00000500  2c 68 25 81 38 29 0d 00  2c 13 f2 50 61 74 68 5f  |,h%.8)..,..Path_|
00000510  4f 62 6a 65 63 74 45 6e  64 0d 00 2d 05 e1 0d ff  |ObjectEnd..-....|
00000520