- don't recheck the placement location if trace_fraction == 1

This commit is contained in:
Adam Olsen 2001-10-12 23:28:18 +00:00
parent 81f9c7f253
commit 63999de0a0

View file

@ -690,13 +690,17 @@ void(float objtobuild) TeamFortress_Build =
endpos_z = self.absmin_z - obj.mins_z - 20; endpos_z = self.absmin_z - obj.mins_z - 20;
checkmove(startpos, obj.mins, obj.maxs, endpos, MOVE_NORMAL, self); checkmove(startpos, obj.mins, obj.maxs, endpos, MOVE_NORMAL, self);
if (trace_startsolid || trace_fraction == 1) { if (trace_fraction == 1) {
sprint (self, PRINT_HIGH, "Not enough room to build here\n");
dremove (obj);
return;
} else if (trace_startsolid) {
checkmove (trace_endpos, obj.mins, obj.maxs, trace_endpos, checkmove (trace_endpos, obj.mins, obj.maxs, trace_endpos,
MOVE_NORMAL, self); MOVE_NORMAL, self);
printtrace (TRUE); printtrace (TRUE);
if (trace_startsolid) { if (trace_startsolid) {
sprint(self, PRINT_HIGH, "Not enough room to build here\n"); sprint (self, PRINT_HIGH, "Not enough room to build here\n");
dremove(obj); dremove (obj);
return; return;
} }
} }