?login_element?

Subversion Repositories NedoOS

Rev

Rev 126 | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed

  1.     MACRO filler x1, x2, y1, y2
  2.         IF (y1 < 0)
  3.             ld  hl,y1*2
  4.             add hl,sp
  5.             ld  sp,hl
  6.         ENDIF
  7.         IF (0 <= y1)
  8.             ld  hl,y1*2
  9.             add hl,sp
  10.             ld  sp,hl
  11.         ENDIF
  12.  
  13.         ld  hl,y1*2
  14.         add hl,sp
  15.         ld  sp,hl
  16.         dup (y2 - y1)
  17.             ld  de,x1
  18.             pop hl
  19.             add hl,de
  20.  
  21.             dup (x2 - x1)
  22.                 ld  (hl),a
  23.                 inc l
  24.             edup
  25.  
  26.             ld  (hl),a
  27.         edup
  28.     ENDM
  29.  
  30.     output "if_in_macro.bin"
  31.  
  32.     filler 17, 20, 37, 40
  33.  
  34.     IF ($ < 0x40)
  35.         ds  0x40 - $, 201
  36.     ENDIF
  37.  
  38.     ret
  39.  
  40.     ; verify that IF works inside macro even if there's nothing after the macro.
  41.     filler 117, 120, 137, 140