ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/include/define.h
(Generate patch)

Comparing deliantra/server/include/define.h (file contents):
Revision 1.44 by root, Sat Jan 20 22:09:52 2007 UTC vs.
Revision 1.46 by root, Fri Feb 2 21:50:43 2007 UTC

82 82
83#define MAX_NAME 48 83#define MAX_NAME 48
84#define MAX_EXT_TITLE 98 84#define MAX_EXT_TITLE 98
85 85
86/* Fatal variables: */ 86/* Fatal variables: */
87//TODO: remove all calls to fatal and replace them by cleanup
87#define OUT_OF_MEMORY 0 88#define OUT_OF_MEMORY 0
88#define MAP_ERROR 1 89#define MAP_ERROR 1
89#define ARCHTABLE_TOO_SMALL 2 90#define ARCHTABLE_TOO_SMALL 2 // unused
90#define TOO_MANY_ERRORS 3 91#define TOO_MANY_ERRORS 3
91 92
92/* TYPE DEFINES */ 93/* TYPE DEFINES */
93 94
94/* Only add new values to this list if somewhere in the program code, 95/* Only add new values to this list if somewhere in the program code,
921#define CAN_APPLY_UNAPPLY_CHOICE 0x40 922#define CAN_APPLY_UNAPPLY_CHOICE 0x40
922 923
923/* Cut off point of when an object is put on the active list or not */ 924/* Cut off point of when an object is put on the active list or not */
924#define MIN_ACTIVE_SPEED 1e-5 925#define MIN_ACTIVE_SPEED 1e-5
925 926
926/*
927 * random() is much better than rand(). If you have random(), use it instead.
928 * You shouldn't need to change any of this
929 *
930 * 0.93.3: It looks like linux has random (previously, it was set below
931 * to use rand). Perhaps old version of linux lack rand? IF you run into
932 * problems, add || defined(__linux__) the #if immediately below.
933 *
934 * 0.94.2 - you probably shouldn't need to change any of the rand stuff
935 * here.
936 */
937
938#define RANDOM() (rndm.next () & 0x7fffffffU) 927#define RANDOM() (rndm.next () & 0xffffffU)
939#define SRANDOM(xyz) //TODO, get rid of 928#define SRANDOM(xyz) rndm.seed (xyz) //TODO, get rid of
940 929
941/* Returns the weight of the given object. Note: it does not take the number of 930/* Returns the weight of the given object. Note: it does not take the number of
942 * items (nrof) into account. 931 * items (nrof) into account.
943 */ 932 */
944#define WEIGHT(op) (op->nrof?op->weight:op->weight+op->carrying) 933#define WEIGHT(op) (op->nrof?op->weight:op->weight+op->carrying)

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines