add wraparound support to C2 physics
[openc2e.git] / cmddata.h
blob3bc3b36e113d4c8d5e1369ae0214062f7171def2
1 /*
2 * cmddata.h
3 * openc2e
5 * Created by Bryan Donlan on Thu 11 Aug 2005.
6 * Copyright (c) 2005-2006 Bryan Donlan. All rights reserved.
8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Lesser General Public
10 * License as published by the Free Software Foundation; either
11 * version 2 of the License, or (at your option) any later version.
13 * This library is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Lesser General Public License for more details.
19 #ifndef CMDDATA_H
20 #define CMDDATA_H 1
22 class caosVM;
24 enum ci_type {
25 CI_OTHER = -1,
26 CI_END = 0,
27 CI_COMMAND,
28 CI_NUMERIC,
29 CI_STRING,
30 CI_AGENT,
31 CI_VARIABLE,
32 CI_BYTESTR,
33 CI_VECTOR,
34 CI_BAREWORD,
35 CI_SUBCOMMAND,
36 CI_ANYVALUE
39 struct cmdinfo {
40 #ifndef VCPP_BROKENNESS
41 void (caosVM::*handler)();
42 void (caosVM::*savehandler)();
43 #else
44 int handler_idx;
45 int savehandler_idx;
46 #endif
47 const char *lookup_key;
48 const char *key;
49 const char *name;
50 const char *fullname;
51 const char *docs;
52 int argc;
53 int stackdelta;
54 const enum ci_type *argtypes;
55 enum ci_type rettype;
56 int evalcost;
59 void registerAutoDelegates();
60 #ifdef VCPP_BROKENNESS
61 void dispatchCAOS(class caosVM *vm, int idx);
62 #endif
64 #endif
67 /* vim: set noet: */