home *** CD-ROM | disk | FTP | other *** search
-
- ;how to do system alerts by Shagratt/LSD
-
- Section ddp,CODE
-
- OPT c-,o+,w-
-
- ***** includes *****
-
- Incdir "dh0:Include/"
- Include "Exec/Exec_Lib.i"
- include "intuition/intuition_lib.i"
-
-
- ***** MACROS *****
-
- alert_text MACRO
- dc.w 320-((\1)*4) ; x co-ords
- dc.b \2 ; y co-ord
- down SET down+10
- ENDM
-
- ***** PROGRAM *****
-
- Start Lea intName,a1
- Clr.l d0
- CALLEXEC OpenLibrary
- Move.l d0,_IntuitionBase
- Beq Error
-
- move.l #0,d0
- move.l #alert_string,a0
- move.l #alert_size,d1
-
- callint displayalert
- error: moveq #0,d0
- rts
-
- *---------------------------------------*
-
- intname: INTNAME
- _intuitionbase: dc.l 0
-
- *---------------------------------------*
-
- alert_string:
-
- down SET 20
-
- alert_text (.a2-.a1),down
- .a1 dc.b "Can't open REQTOOLS.Library",0
- .a2 dc.b 0 ; another line
-
- dc.b 0
- even
-
- alert_size = down+5
-
- *---------------------------------------*
-
- end
-
-
-