1: /*
   2:  * Copyright (c) 1987 by Ed James, UC Berkeley.  All rights reserved.
   3:  *
   4:  * Copy permission is hereby granted provided that this notice is
   5:  * retained on all partial or complete copies.
   6:  *
   7:  * For more info on this and all of my stuff, mail edjames@berkeley.edu.
   8:  */
   9: 
  10: #define AUTHOR_STR      "ATC - by Ed James"
  11: 
  12: #define PI          3.14159654
  13: 
  14: #define LOWFUEL         15
  15: 
  16: #define REALLOC         10
  17: 
  18: #define SGN(x)          ((x < 0) ? -1 : ((x > 0) ? 1 : 0))
  19: #define ABS(x)          ((x < 0) ? -(x) : (x))
  20: #define DIR_FROM_DXDY(dx,dy)    ((int) (atan2((double)(dy), (double)(dx)) \
  21:                 * MAXDIR / (2 * PI) + 2.5 + MAXDIR) % MAXDIR)
  22: 
  23: #define MAXDIR      8
  24: 
  25: #define D_LEFT      1
  26: #define D_RIGHT     2
  27: #define D_UP        3
  28: #define D_DOWN      4
  29: 
  30: #define T_NODEST    0
  31: #define T_BEACON    1
  32: #define T_EXIT      2
  33: #define T_AIRPORT   3
  34: 
  35: #define S_NONE      0
  36: #define S_GONE      1
  37: #define S_MARKED    2
  38: #define S_UNMARKED  3
  39: #define S_IGNORED   4
  40: 
  41: #define INPUT_LINES 3
  42: #define PLANE_COLS  20

Defined macros

ABS defined in line 19; used 5 times
AUTHOR_STR defined in line 10; used 1 times
DIR_FROM_DXDY defined in line 20; used 4 times
D_DOWN defined in line 28; used 1 times
D_LEFT defined in line 25; used 1 times
D_RIGHT defined in line 26; used 1 times
D_UP defined in line 27; used 1 times
INPUT_LINES defined in line 41; used 8 times
LOWFUEL defined in line 14; used 1 times
MAXDIR defined in line 23; used 23 times
PI defined in line 12; used 1 times
  • in line 21
PLANE_COLS defined in line 42; used 6 times
REALLOC defined in line 16; used 12 times
SGN defined in line 18; used 5 times
S_GONE defined in line 36; used 3 times
S_IGNORED defined in line 39; used 3 times
S_MARKED defined in line 37; used 6 times
S_NONE defined in line 35; never used
S_UNMARKED defined in line 38; used 4 times
T_AIRPORT defined in line 33; used 6 times
T_BEACON defined in line 31; used 1 times
T_EXIT defined in line 32; used 4 times
T_NODEST defined in line 30; used 2 times

Usage of this include

def.h used 1 times
Last modified: 1987-03-11
Generated: 2016-12-26
Generated by src2html V0.67
page hit count: 1345
Valid CSS Valid XHTML 1.0 Strict