Evolution of XI Raycast Engine
Loading...
1,780
Loading...
Uploader Comments (xilefian)
see all
All Comments (13)
-
@xilefian Ohhh! Brilliant! Thank you. This is very helpful.
-
@pugay69 It is my engine, I emailed Lode personally for his advice and information on his code, it's rapidly different though, the test grid is still the same.
For example, the floor and ceiling code is entirely different now, the wall rendering is no longer done per slice but is a polygon, the sprites remain the same, the movement code has been changed to vector based collisions, rotation code has recently been swapped for a more efficient one, and ySheering added along with models.
No SDL too
-
@theobserver5000 Yes
Loading...
What's the best way to slice textures onto the walls? In my raycast engine, I can draw blank walls made from rectangles, I just can't think of a good way to slice the 64x64 tiles onto the walls.
VoltageEntertainment 3 months ago
@VoltageEntertainment record the offset the camera is on the grid(if player is at 8.2, 3.4 the offset is 0.2, 0.4) check if it's a north/south or east/west wall to define which offset is used, use that offset to calculate the x co-ord on the texture, stretch the full y height of the texture onto the height of the slice.
hope you understand or have some new ideas
xilefian 3 months ago
@xilefian ultimately you want to find how far along the grid sector the ray hits and that tells you how far along the texture to start drawing
xilefian 3 months ago
@xilefian So, don't cut the image literally, just scale it down?
VoltageEntertainment 3 months ago
@VoltageEntertainment cut the x slice out (So it's 1px wide) and then scale the height based on the distance found by the raycaster for that specific ray value
xilefian 3 months ago
I can tell you followed the lodev.org tuts, so it's not really "your" engine....
pugay69 5 months ago
@pugay69 All versions in this video are VB.NET also, it's only recently become a C++ engine, doesn't use SDL and uses classes now, it is rapidly different and faster.
xilefian 5 months ago