Log In  


Simple raycast test.

Cart #mulperiraycast-0 | 2023-04-17 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
5

5


Pretty cool effect, I like it!


1

Thank you, I will be using this later in my games for line of sight


2

be aware that your current code is quite slow - there is no need to iterate over pixels to find a hit, this should be done in grid space - suggest to look at how a typical raycasting engine solves that.
example: https://www.permadi.com/tutorial/raycast/rayc7.html


Thank you @freds72 for taking the time to check the code and suggest better way of doing it!
I will try to understand it. Hopefully it won't be beyond my capabilities to implement :)


Hi,nice implementation! I did one a while ago, i don't which one is more suitable though: https://www.lexaloffle.com/bbs/?tid=49151


taxicomics: your function is not any better perf wise!



[Please log in to post a comment]