]> git.cameronkatri.com Git - bsdgames-darwin.git/blob - larn/extern.h
More assorted cleanup merged from larn 12.2.
[bsdgames-darwin.git] / larn / extern.h
1 /* $NetBSD: extern.h,v 1.11 2008/02/04 01:07:01 dholland Exp $ */
2
3 /*
4 * Copyright (c) 1997 Christos Zoulas. All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:
9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer.
11 * 2. Redistributions in binary form must reproduce the above copyright
12 * notice, this list of conditions and the following disclaimer in the
13 * documentation and/or other materials provided with the distribution.
14 * 3. All advertising materials mentioning features or use of this software
15 * must display the following acknowledgement:
16 * This product includes software developed by Christos Zoulas.
17 * 4. The name of the author may not be used to endorse or promote products
18 * derived from this software without specific prior written permission.
19 *
20 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
21 * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
22 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
23 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
24 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
25 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
26 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
27 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
28 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
29 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30 */
31
32 /* bill.c */
33 void mailbill(void);
34
35 /* config.c */
36
37 /* create.c */
38 void makeplayer(void);
39 void newcavelevel(int);
40 void eat(int, int);
41 int fillmonst(int);
42
43 /* data.c */
44
45 /* diag.c */
46 void diag(void);
47 int dcount(int);
48 void diagdrawscreen(void);
49 int savegame(char *);
50 void restoregame(char *);
51
52 /* display.c */
53 void bottomline(void);
54 void bottomhp(void);
55 void bottomspell(void);
56 void bottomdo(void);
57 void bot_linex(void);
58 void bottomgold(void);
59 void draws(int, int, int, int);
60 void drawscreen(void);
61 void showcell(int, int);
62 void show1cell(int, int);
63 void showplayer(void);
64 int moveplayer(int);
65 void seemagic(int);
66
67 /* fortune.c */
68 const char *fortune(void);
69
70 /* global.c */
71 void raiselevel(void);
72 void loselevel(void);
73 void raiseexperience(long);
74 void loseexperience(long);
75 void losehp(int);
76 void losemhp(int);
77 void raisehp(int);
78 void raisemhp(int);
79 void raisemspells(int);
80 void losemspells(int);
81 int makemonst(int);
82 void positionplayer(void);
83 void recalc(void);
84 void quit(void);
85 void more(void);
86 int take(int, int);
87 int drop_object(int);
88 void enchantarmor(void);
89 void enchweapon(void);
90 int pocketfull(void);
91 int nearbymonst(void);
92 int stealsomething(void);
93 int emptyhanded(void);
94 void creategem(void);
95 void adjustcvalues(int, int);
96 int getpassword(void);
97 int getyn(void);
98 int packweight(void);
99 int rnd(int);
100 int rund(int);
101
102 /* help.c */
103 void help(void);
104 void welcome(void);
105 void retcont(void);
106
107 /* io.c */
108 void setupvt100(void);
109 void clearvt100(void);
110 int ttgetch(void);
111 void scbr(void);
112 void sncbr(void);
113 void newgame(void);
114 void lprintf(const char *, ...) __attribute__((__format__(__printf__, 1, 2)));
115 void lprint(long);
116 void lwrite(char *, int);
117 long lgetc(void);
118 long larn_lrint(void);
119 void lrfill(char *, int);
120 char *lgetw(void);
121 char *lgetl(void);
122 int lcreat(char *);
123 int lopen(char *);
124 int lappend(char *);
125 void lrclose(void);
126 void lwclose(void);
127 void lprcat(const char *);
128 void cursor(int, int);
129 void cursors(void);
130 void init_term(void);
131 void cl_line(int, int);
132 void cl_up(int, int);
133 void cl_dn(int, int);
134 void standout(const char *);
135 void set_score_output(void);
136 void lflush(void);
137 char *tmcapcnv(char *, char *);
138 void beep(void);
139
140 /* main.c */
141 int main(int, char **);
142 void showstr(void);
143 void qshowstr(void);
144 void t_setup(int);
145 void t_endup(int);
146 void showwear(void);
147 void showwield(void);
148 void showread(void);
149 void showeat(void);
150 void showquaff(void);
151 void show1(int, const char *[]);
152 void show3(int);
153 void randmonst(void);
154 void parse(void);
155 void parse2(void);
156 void run(int);
157 void wield(void);
158 void ydhi(int);
159 void ycwi(int);
160 void wear(void);
161 void dropobj(void);
162 void readscr(void);
163 void eatcookie(void);
164 void quaff(void);
165 unsigned long readnum(long);
166 void szero(char *);
167
168 /* monster.c */
169 void createmonster(int);
170 void createitem(int, int);
171 void cast(void);
172 void speldamage(int);
173 void loseint(void);
174 int isconfuse(void);
175 int nospell(int, int);
176 int fullhit(int);
177 void direct(int, int, const char *, int);
178 void godirect(int, int, const char *, int, int);
179 void ifblind(int, int);
180 void tdirect(int);
181 void omnidirect(int, int, const char *);
182 int vxy(int *, int *);
183 void dirpoly(int);
184 void hitmonster(int, int);
185 int hitm(int, int, int);
186 void hitplayer(int, int);
187 void dropgold(int);
188 void something(int);
189 int newobject(int, int *);
190 void checkloss(int);
191 int annihilate(void);
192 int newsphere(int, int, int, int);
193 int rmsphere(int, int);
194 void sphboom(int, int);
195 void genmonst(void);
196
197 /* moreobj.c */
198 void oaltar(void);
199 void othrone(int);
200 void odeadthrone(void);
201 void ochest(void);
202 void ofountain(void);
203 void fntchange(int);
204
205 /* movem.c */
206 void movemonst(void);
207 void movemt(int, int);
208 void mmove(int, int, int, int);
209 void movsphere(void);
210
211 /* nap.c */
212 void nap(int);
213
214 /* object.c */
215 void lookforobject(void);
216 void finditem(int);
217 void ostairs(int);
218 void oteleport(int);
219 void opotion(int);
220 void quaffpotion(int);
221 void oscroll(int);
222 void adjusttime(long);
223 void read_scroll(int);
224 void oorb(void);
225 void opit(void);
226 void obottomless(void);
227 void oelevator(int);
228 void ostatue(void);
229 void omirror(void);
230 void obook(void);
231 void readbook(int);
232 void ocookie(void);
233 void ogold(int);
234 void ohome(void);
235 void iopts(void);
236 void ignore(void);
237
238 /* regen.c */
239 void regen(void);
240
241 /* savelev.c */
242 void savelevel(void);
243 void getlevel(void);
244
245 /* scores.c */
246 int readboard(void);
247 int writeboard(void);
248 int makeboard(void);
249 int hashewon(void);
250 long paytaxes(long);
251 int winshou(void);
252 int shou(int);
253 void showscores(void);
254 void showallscores(void);
255 int sortboard(void);
256 void newscore(long, char *, int, int);
257 void new1sub(long, int, char *, long);
258 void new2sub(long, int, char *, int);
259 void died(int);
260 void diedsub(int);
261 void diedlog(void);
262 int getplid(char *);
263
264 /* signal.c */
265 void sigsetup(void);
266
267 /* store.c */
268 void dnd_2hed(void);
269 void dnd_hed(void);
270 void dndstore(void);
271 void sch_hed(void);
272 void oschool(void);
273 void obank(void);
274 void obank2(void);
275 void ointerest(void);
276 void obanksub(void);
277 void appraise(int);
278 void otradepost(void);
279 void cnsitm(void);
280 void olrs(void);
281
282 /* tok.c */
283 int yylex(void);
284 void flushall(void);
285 void sethard(int);
286 void readopts(void);