home *** CD-ROM | disk | FTP | other *** search
- typedef float vec_t;
- typedef vec_t vec3_t[3];
-
- typedef struct
- {
- float modelindex;
- vec3_t absmin;
- vec3_t absmax;
- float ltime;
- float movetype;
- float solid;
- vec3_t origin;
- vec3_t oldorigin;
- vec3_t velocity;
- vec3_t angles;
- vec3_t avelocity;
- vec3_t punchangle;
- float frame;
- float skin;
- float effects;
- vec3_t mins;
- vec3_t maxs;
- vec3_t size;
- float nextthink;
- int groundentity;
- float health;
- float frags;
- float weapon;
- float weaponframe;
- float currentammo;
- float ammo_shells;
- float ammo_nails;
- float ammo_rockets;
- float ammo_cells;
- float items;
- float takedamage;
- int chain;
- float deadflag;
- vec3_t view_ofs;
- float button0;
- float button1;
- float button2;
- float impulse;
- float fixangle;
- vec3_t v_angle;
- float idealpitch;
- int enemy;
- float flags;
- float colormap;
- float team;
- float max_health;
- float teleport_time;
- float armortype;
- float armorvalue;
- float waterlevel;
- float watertype;
- float ideal_yaw;
- float yaw_speed;
- int aiment;
- int goalentity;
- float spawnflags;
- float dmg_take;
- float dmg_save;
- int dmg_inflictor;
- int owner;
- vec3_t movedir;
- float sounds;
- } entvars_t;
-
- typedef struct edict_s
- {
- int free;
- int num_leafs;
- short leafnums[16];
- entvars_t v;
- } edict_t;
-
- #define VectorAdd(a,b,c) {c[0]=a[0]+b[0];c[1]=a[1]+b[1];c[2]=a[2]+b[2];}
- extern edict_t *prog_to_edict(void);
-
-
- float PF_checkclient (void)
- {
- edict_t *self;
- vec3_t view;
-
- self = prog_to_edict();
- VectorAdd (self->v.origin, self->v.view_ofs, view);
- return view[0];
- }
-