forked from noah-/d2bs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
JSExits.h
41 lines (33 loc) · 1.06 KB
/
JSExits.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#ifndef EXITS_H
#define EXITS_H
#include "js32.h"
#include <windows.h>
CLASS_CTOR(exit);
void exit_finalize(JSFreeOp *fop, JSObject *obj);
JSAPI_PROP(exit_getProperty);
enum exit_tinyid {
EXIT_X,
EXIT_Y,
EXIT_TARGET,
EXIT_TYPE,
EXIT_TILEID,
EXIT_LEVELID
};
static JSPropertySpec exit_props[] = {
{"x", EXIT_X, JSPROP_PERMANENT_VAR, JSOP_WRAPPER(exit_getProperty), JSOP_NULLWRAPPER },
{"y", EXIT_Y, JSPROP_PERMANENT_VAR, JSOP_WRAPPER(exit_getProperty), JSOP_NULLWRAPPER },
{"target", EXIT_TARGET, JSPROP_PERMANENT_VAR, JSOP_WRAPPER(exit_getProperty), JSOP_NULLWRAPPER },
{"type", EXIT_TYPE, JSPROP_PERMANENT_VAR, JSOP_WRAPPER(exit_getProperty), JSOP_NULLWRAPPER },
{"tileid", EXIT_TILEID, JSPROP_PERMANENT_VAR, JSOP_WRAPPER(exit_getProperty), JSOP_NULLWRAPPER },
{"level", EXIT_LEVELID, JSPROP_PERMANENT_VAR, JSOP_WRAPPER(exit_getProperty), JSOP_NULLWRAPPER },
{ 0, 0, 0, JSOP_NULLWRAPPER, JSOP_NULLWRAPPER }
};
struct myExit {
DWORD x;
DWORD y;
DWORD id;
DWORD type;
DWORD tileid;
DWORD level;
};
#endif