summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/world.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/world.cpp b/src/world.cpp
index 8a7720c..46dcde5 100644
--- a/src/world.cpp
+++ b/src/world.cpp
@@ -331,10 +331,8 @@ trace_t world_t::trace(v2f_t start, v2f_t end, cflags_t cflags)
index = (tile_index_t(x.floor()) ^ transforms_index[quad]) +
offsets_index[quad];
- //rectf_t tile(index, (v2f_t)index + v2f_t(1, 1));
- if (get_tile(index, false)->type > cflags) { // FIXME
- //debug_render->render_hlrect(tile, sf::Color::Red);
+ if (tiles[get_tile(index, false)->type] & cflags) {
res.hit = true;
res.end = x ^ transforms[quad];
res.frac = (x - start).len() / (end - start).len();
@@ -342,7 +340,6 @@ trace_t world_t::trace(v2f_t start, v2f_t end, cflags_t cflags)
}
mod = x - x.floor();
- //debug_render->render_hlrect(tile, sf::Color::Green);
// Project onto x = const.
P[0] = 1.0f - mod[0];