summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: a172225)
raw | patch | inline | side by side (parent: a172225)
author | Ketmar Dark <ketmar@ketmar.no-ip.org> | |
Wed, 23 Aug 2017 21:07:32 +0000 (00:07 +0300) | ||
committer | Ketmar Dark <ketmar@ketmar.no-ip.org> | |
Wed, 23 Aug 2017 21:07:57 +0000 (00:07 +0300) |
src/game/g_grid.pas | patch | blob | history |
diff --git a/src/game/g_grid.pas b/src/game/g_grid.pas
index 19c4d0d2ca8f31fc39170217693375c3d8cc5de2..647a45d8329519461cb257e423a8176de017d077 100644 (file)
--- a/src/game/g_grid.pas
+++ b/src/game/g_grid.pas
dx2 -= dy2;
// first move, to skip starting point
+ // DON'T DO THIS! loop will take care of that
if (xd = term) then exit;
prevx := xptr^+minx;
prevy := yptr^+miny;
+ (*
// move coords
if (e >= 0) then begin yd += sty; e -= dx2; end else e += dy2;
xd += stx;
// done?
if (xd = term) then exit;
+ *)
{$IF DEFINED(D2F_DEBUG)}
if (xptr^ < 0) or (yptr^ < 0) or (xptr^ >= gw*tsize) and (yptr^ >= gh*tsize) then raise Exception.Create('raycaster internal error (0)');
{$ENDIF}
- lastGA := (yptr^ div tsize)*gw+(xptr^ div tsize);
- ccidx := mGrid[lastGA];
+ // DON'T DO THIS! loop will take care of that
+ //lastGA := (yptr^ div tsize)*gw+(xptr^ div tsize);
+ //ccidx := mGrid[lastGA];
{$IF DEFINED(D2F_DEBUG_RAYTRACE)}
//if assigned(dbgRayTraceTileHitCB) then e_WriteLog('1:TRACING!', MSG_NOTIFY);