DEADSOFTWARE

Holmes cursor shadow cosmetix
[d2df-sdl.git] / src / game / g_grid.pas
index 153e6faa7bcc76f8339c2165c8d12a018cfd026b..6017ad4b492dfbc436da477ccd41a685a3bca7b1 100644 (file)
@@ -20,6 +20,7 @@
   {.$DEFINE D2F_DEBUG_XXQ}
   {.$DEFINE D2F_DEBUG_MOVER}
 {$ENDIF}
+{.$DEFINE GRID_USE_ORTHO_ACCEL}
 unit g_grid;
 
 interface
@@ -1283,8 +1284,10 @@ var
   f, ptag, distSq: Integer;
   x0, y0, x1, y1: Integer;
   // horizontal walker
+  {$IFDEF GRID_USE_ORTHO_ACCEL}
   wklen, wkstep: Integer;
   hopt: Boolean;
+  {$ENDIF}
 begin
   result := Default(ITP);
   lastObj := Default(ITP);
@@ -1506,6 +1509,7 @@ begin
   end;
   lq := mLastQuery;
 
+  {$IFDEF GRID_USE_ORTHO_ACCEL}
   // if this is strict horizontal trace, use optimized codepath
   if (ax0 = ax1) or (ay0 = ay1) then
   begin
@@ -1721,6 +1725,7 @@ begin
     if wasHit and not assigned(cb) then result := lastObj else begin ex := ax1; ey := ay1; end;
     exit;
   end;
+  {$ENDIF}
 
   {$IF DEFINED(D2F_DEBUG_RAYTRACE)}
   if assigned(dbgRayTraceTileHitCB) then dbgRayTraceTileHitCB((xptr^ div tsize*tsize)+minx, (yptr^ div tsize*tsize)+miny);