chiark / gitweb /
Initial revision
[ssr] / StraySrc / Libraries / Sapphire / sh / resources
1 ;
2 ; resources.sh
3 ;
4 ; Access to shared resource DLL
5 ;
6 ; © 1995-1998 Straylight
7 ;
8
9 ;----- Licensing note -------------------------------------------------------
10 ;
11 ; This file is part of Straylight's Sapphire library.
12 ;
13 ; Sapphire is free software; you can redistribute it and/or modify
14 ; it under the terms of the GNU General Public License as published by
15 ; the Free Software Foundation; either version 2, or (at your option)
16 ; any later version.
17 ;
18 ; Sapphire is distributed in the hope that it will be useful,
19 ; but WITHOUT ANY WARRANTY; without even the implied warranty of
20 ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
21 ; GNU General Public License for more details.
22 ;
23 ; You should have received a copy of the GNU General Public License
24 ; along with Sapphire.  If not, write to the Free Software Foundation,
25 ; 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
26
27 ;----- Overview -------------------------------------------------------------
28 ;
29 ; Functions provided:
30 ;
31 ;  resource_init
32 ;  resource_find
33
34                 [       :LNOT::DEF:resources__dfn
35                 GBLL    resources__dfn
36
37 ; --- resources_init ---
38 ;
39 ; On entry:     --
40 ;
41 ; On exit:      --
42 ;
43 ; Use:          Initialises the shared resource system, setting up the
44 ;               link to the SapphRes DLL.  Note that this initialisation is
45 ;               /not/ performed automatically.
46
47                 IMPORT  resources_init
48
49 ; --- resources_find ---
50 ;
51 ; On entry:     R0 == resource code
52 ;               R1 == pointer to name (only for rsType_template)
53 ;
54 ; On exit:      CS if found, and
55 ;                 R0 == pointer to resource
56 ;                 R1 == pointer to resource limit (only for rsType_message)
57 ;               else CC and
58 ;                 R0,R1 preserved
59 ;
60 ; Use:          Locates resources in the shared resource DLL.
61
62                 IMPORT  resources_find
63
64 ;----- Resource types -------------------------------------------------------
65
66                 ^       0
67 rsType_sprite   #       1
68 rsType_message  #       1
69 rsType_template #       1
70
71                 ]
72
73 ;----- That's all, folks ----------------------------------------------------
74
75                 END