mirror of
https://github.com/yquake2/yquake2remaster.git
synced 2024-11-24 21:41:10 +00:00
game: code style
This commit is contained in:
parent
03cb2be1e6
commit
6fd9e0ecc4
12 changed files with 27 additions and 27 deletions
|
@ -672,7 +672,7 @@ SP_target_spawner(edict_t *self)
|
|||
if (!Q_stricmp(level.mapname, "fact2")
|
||||
&& VectorCompare(self->s.origin, fact2spawnpoint1) )
|
||||
{
|
||||
VectorSet (forward, 0, 0, 1);
|
||||
VectorSet(forward, 0, 0, 1);
|
||||
VectorMA (self->s.origin, -8, forward, self->s.origin);
|
||||
}
|
||||
|
||||
|
|
|
@ -314,7 +314,7 @@ void actorMachineGun (edict_t *self)
|
|||
vec3_t start, target;
|
||||
vec3_t forward, right;
|
||||
|
||||
AngleVectors (self->s.angles, forward, right, NULL);
|
||||
AngleVectors(self->s.angles, forward, right, NULL);
|
||||
G_ProjectSource (self->s.origin, monster_flash_offset[MZ2_ACTOR_MACHINEGUN_1], forward, right, start);
|
||||
if (self->enemy)
|
||||
{
|
||||
|
@ -325,7 +325,7 @@ void actorMachineGun (edict_t *self)
|
|||
}
|
||||
else
|
||||
{
|
||||
VectorCopy (self->enemy->absmin, target);
|
||||
VectorCopy(self->enemy->absmin, target);
|
||||
target[2] += (self->enemy->size[2] / 2);
|
||||
}
|
||||
VectorSubtract (target, start, forward);
|
||||
|
@ -333,7 +333,7 @@ void actorMachineGun (edict_t *self)
|
|||
}
|
||||
else
|
||||
{
|
||||
AngleVectors (self->s.angles, forward, NULL, NULL);
|
||||
AngleVectors(self->s.angles, forward, NULL, NULL);
|
||||
}
|
||||
monster_fire_bullet (self, start, forward, 3, 4, DEFAULT_BULLET_HSPREAD, DEFAULT_BULLET_VSPREAD, MZ2_ACTOR_MACHINEGUN_1);
|
||||
}
|
||||
|
@ -341,12 +341,12 @@ void actorMachineGun (edict_t *self)
|
|||
|
||||
void actor_dead (edict_t *self)
|
||||
{
|
||||
VectorSet (self->mins, -16, -16, -24);
|
||||
VectorSet (self->maxs, 16, 16, -8);
|
||||
VectorSet(self->mins, -16, -16, -24);
|
||||
VectorSet(self->maxs, 16, 16, -8);
|
||||
self->movetype = MOVETYPE_TOSS;
|
||||
self->svflags |= SVF_DEADMONSTER;
|
||||
self->nextthink = 0;
|
||||
gi.linkentity (self);
|
||||
gi.linkentity(self);
|
||||
}
|
||||
|
||||
static mframe_t actor_frames_death1 [] =
|
||||
|
@ -506,8 +506,8 @@ void SP_misc_actor (edict_t *self)
|
|||
self->movetype = MOVETYPE_STEP;
|
||||
self->solid = SOLID_BBOX;
|
||||
self->s.modelindex = gi.modelindex("players/male/tris.md2");
|
||||
VectorSet (self->mins, -16, -16, -24);
|
||||
VectorSet (self->maxs, 16, 16, 32);
|
||||
VectorSet(self->mins, -16, -16, -24);
|
||||
VectorSet(self->maxs, 16, 16, 32);
|
||||
|
||||
if (!self->health)
|
||||
self->health = 100;
|
||||
|
@ -525,7 +525,7 @@ void SP_misc_actor (edict_t *self)
|
|||
|
||||
self->monsterinfo.aiflags |= AI_GOOD_GUY;
|
||||
|
||||
gi.linkentity (self);
|
||||
gi.linkentity(self);
|
||||
|
||||
self->monsterinfo.currentmove = &actor_move_stand;
|
||||
self->monsterinfo.scale = MODEL_SCALE;
|
||||
|
@ -651,8 +651,8 @@ void SP_target_actor (edict_t *self)
|
|||
|
||||
self->solid = SOLID_TRIGGER;
|
||||
self->touch = target_actor_touch;
|
||||
VectorSet (self->mins, -8, -8, -8);
|
||||
VectorSet (self->maxs, 8, 8, 8);
|
||||
VectorSet(self->mins, -8, -8, -8);
|
||||
VectorSet(self->maxs, 8, 8, 8);
|
||||
self->svflags = SVF_NOCLIENT;
|
||||
|
||||
if (self->spawnflags & 1)
|
||||
|
@ -667,5 +667,5 @@ void SP_target_actor (edict_t *self)
|
|||
self->movedir[2] = st.height;
|
||||
}
|
||||
|
||||
gi.linkentity (self);
|
||||
gi.linkentity(self);
|
||||
}
|
||||
|
|
|
@ -871,7 +871,7 @@ makron_torso_origin(edict_t *self, edict_t *torso)
|
|||
|
||||
tr = gi.trace(self->s.origin, torso->mins, torso->maxs, v, self, MASK_SOLID);
|
||||
|
||||
VectorCopy (tr.endpos, torso->s.origin);
|
||||
VectorCopy(tr.endpos, torso->s.origin);
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -1007,7 +1007,7 @@ makron_die(edict_t *self, edict_t *inflictor /* unused */, edict_t *attacker /*
|
|||
|
||||
/* lower bbox since the torso is gone */
|
||||
self->maxs[2] = 64;
|
||||
gi.linkentity (self);
|
||||
gi.linkentity(self);
|
||||
|
||||
self->monsterinfo.currentmove = &makron_move_death2;
|
||||
}
|
||||
|
|
|
@ -122,7 +122,7 @@ dog_leap_step(edict_t *self)
|
|||
{
|
||||
vec3_t forward;
|
||||
|
||||
AngleVectors (self->s.angles, forward, NULL, NULL);
|
||||
AngleVectors(self->s.angles, forward, NULL, NULL);
|
||||
self->s.origin[2] += 1;
|
||||
VectorScale(forward, 300, self->velocity);
|
||||
self->velocity[2] = 200;
|
||||
|
|
|
@ -191,7 +191,7 @@ FireShalrathPod(edict_t *self)
|
|||
vec3_t vec;
|
||||
vec3_t offset = {16, 0, 16};
|
||||
|
||||
AngleVectors (self->s.angles, forward, right, NULL);
|
||||
AngleVectors(self->s.angles, forward, right, NULL);
|
||||
G_ProjectSource(self->s.origin, offset, forward, right, start);
|
||||
VectorCopy(self->enemy->s.origin, vec);
|
||||
vec[2] += self->enemy->viewheight;
|
||||
|
|
|
@ -710,8 +710,8 @@ SP_monster_shambler(edict_t* self)
|
|||
}
|
||||
|
||||
self->s.modelindex = gi.modelindex("models/monsters/shambler/tris.md2");
|
||||
VectorSet (self->mins, -32, -32, -24);
|
||||
VectorSet (self->maxs, 32, 32, 64);
|
||||
VectorSet(self->mins, -32, -32, -24);
|
||||
VectorSet(self->maxs, 32, 32, 64);
|
||||
self->movetype = MOVETYPE_STEP;
|
||||
self->solid = SOLID_BBOX;
|
||||
|
||||
|
|
|
@ -539,11 +539,11 @@ TankRocket(edict_t *self)
|
|||
|
||||
if (blindfire)
|
||||
{
|
||||
VectorCopy (self->monsterinfo.blind_fire_target, target);
|
||||
VectorCopy(self->monsterinfo.blind_fire_target, target);
|
||||
}
|
||||
else
|
||||
{
|
||||
VectorCopy (self->enemy->s.origin, target);
|
||||
VectorCopy(self->enemy->s.origin, target);
|
||||
}
|
||||
|
||||
if (blindfire)
|
||||
|
|
|
@ -145,7 +145,7 @@ tarbaby_jump_step(edict_t *self)
|
|||
self->movetype = MOVETYPE_BOUNCE;
|
||||
self->touch = tarbaby_touch;
|
||||
|
||||
AngleVectors (self->s.angles, forward, NULL, NULL);
|
||||
AngleVectors(self->s.angles, forward, NULL, NULL);
|
||||
self->s.origin[2] += 1;
|
||||
VectorScale(forward, 600, self->velocity);
|
||||
self->velocity[2] = 200 + (random() * 150);
|
||||
|
|
|
@ -221,7 +221,7 @@ wizard_spit(edict_t *self)
|
|||
vec3_t vec;
|
||||
vec3_t offset = {0, 0, 30};
|
||||
|
||||
AngleVectors (self->s.angles, forward, right, NULL);
|
||||
AngleVectors(self->s.angles, forward, right, NULL);
|
||||
G_ProjectSource(self->s.origin, offset, forward, right, start);
|
||||
VectorCopy(self->enemy->s.origin, vec);
|
||||
vec[2] += self->enemy->viewheight;
|
||||
|
|
|
@ -321,7 +321,7 @@ CheckChasecam_Viewent(edict_t *ent)
|
|||
|
||||
ent->client->oldplayer->flags = ent->flags;
|
||||
/* end Lazarus */
|
||||
gi.linkentity (ent->client->oldplayer);
|
||||
gi.linkentity(ent->client->oldplayer);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -432,7 +432,7 @@ SV_CalcViewOffset(edict_t *ent)
|
|||
}
|
||||
else
|
||||
{
|
||||
VectorSet (v, 0, 0, 0);
|
||||
VectorSet(v, 0, 0, 0);
|
||||
if (ent->client->chasecam)
|
||||
{
|
||||
ent->client->ps.pmove.origin[0] = ent->client->chasecam->s.origin[0] * 8;
|
||||
|
|
|
@ -210,8 +210,8 @@ PlayerNoise_Spawn(edict_t *who, int type)
|
|||
|
||||
noise->classname = "player_noise";
|
||||
noise->spawnflags = type;
|
||||
VectorSet (noise->mins, -8, -8, -8);
|
||||
VectorSet (noise->maxs, 8, 8, 8);
|
||||
VectorSet(noise->mins, -8, -8, -8);
|
||||
VectorSet(noise->maxs, 8, 8, 8);
|
||||
noise->owner = who;
|
||||
noise->svflags = SVF_NOCLIENT;
|
||||
|
||||
|
|
Loading…
Reference in a new issue