]> git.xonotic.org Git - xonotic/gmqcc.git/blob - data/functions.qc
cache the IMMEDIATE string in the builder directly
[xonotic/gmqcc.git] / data / functions.qc
1 /* this is the WIP test for the parser...
2  * constantly adding stuff here to see if things break
3  */
4 void(string)        print  = #1;
5 void(string,string) print2 = #1;
6 void(string,string,string) print3 = #1;
7 string(float)       ftos   = #2;
8 entity()            spawn  = #3;
9 void(entity)        kill   = #4;
10
11 .float vis;
12 .entity other;
13
14 float(entity targ) visible = {
15     return targ.vis;
16 };
17
18 void() printworking = {
19     print("Working\n");
20 };
21
22 void(void() callback) testcallback = {
23     callback();
24 };
25
26 void(float) has1param = {};
27
28 void() main = {
29     local entity pawn, pawn2;
30
31     pawn = spawn();
32     pawn2 = spawn();
33
34     pawn.other = pawn2;
35     pawn.other.vis = 0;
36
37     if (!visible(pawn.other))
38         print("Yes\n");
39
40     testcallback(printworking);
41
42     has1param();
43 };