123
-=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- (c) WidthPadding Industries 1987 0|40|0 -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=-
Socoder -> Off Topic -> Raycaster at PlayMyCode

Page : 1 2 Next
Prev
Thu, 07 Jul 2011, 19:12
CodersRule
I tried to learn how to make a raycaster earlier, but then remembered that I can neither code nor do proper maths. Quite depressing. I do like the little hand bob by the way. For a second I actually thought the whole screen was moving until I remembered it was a raycaster.
Thu, 07 Jul 2011, 19:12
JL235
and my Raycaster demo is complete: Linkage

[pmc]joe/raycaster[/pmc]

|edit| embedded the raycaster |edit|
Fri, 08 Jul 2011, 07:21
JL235
It also has a simple day/night system now.
Fri, 08 Jul 2011, 07:33
waroffice
I get errors when I try your games

NS_ERROR_NOT_AVAILABLE

Component returned failure code: 0x80040111 (NS_ERROR_NOT_AVAILABLE) [nsIDOMCanvasRenderingContext2D.drawImag

I'm on FF 3.6.12
Fri, 08 Jul 2011, 07:40
JL235
Upgrade your copy of FireFox.

To clarify further, the issue older versions of FF did not keep to the correct spec. This meant stuff I did, which was valid, can cause FF 3.6 to crash. FF 4 and 5 are far more compliant to the spec.
Fri, 08 Jul 2011, 09:58
CodersRule
This raycaster reminds me of that old win95 maze screensaver that I used to absolutely love. Didn't know it was raycasting back then, mainly because I didn't know what raycasting was. ^^
Fri, 08 Jul 2011, 10:20
waroffice
I can't update the pc at work until I get (hopefully) the promotion in the next week or 2 where I can run any OS i want (Amiga workbench it is then!!!)

I will however test it from home
Fri, 08 Jul 2011, 10:27
spinal
I always wanted to learn to make a raycaster, never got round to it

-=-=-
Check out my excellent homepage!
Fri, 08 Jul 2011, 10:31
JL235
I never actually learnt how to build one, I just followed some of the (excellent) tutorials out there. They handle all the maths for you, and you can usually get enough of an impression to be able to tweak/optimize/improve it for your needs.
Fri, 08 Jul 2011, 10:35
waroffice
interesting, do you have a link to a good tutorial or should I just Google it?
Fri, 08 Jul 2011, 14:02
JL235
The first raycasting tutorial (this one) is the one I used to build that.
Fri, 08 Jul 2011, 14:57
CodersRule
Egads. I just deleted my post. Not entirely sure how.
Fri, 08 Jul 2011, 15:03
shroom_monk
@CodersRule: SoCoder was having connection issues for me a minute ago... maybe your post didn't get sent or something?

-=-=-
A mushroom a day keeps the doctor away...

Keep It Simple, Shroom!
Fri, 08 Jul 2011, 15:32
Jayenkai
No, it was sent!

Forum-Post-Delete's a very "click it once, BANG! And the post is GONE!!" button, isn't it.. Perhaps it's time to move it inside the Edit thing, like in Comments..


I love the Raytracer, really well done!
It's a shame it's doing that "little blue line" thing. A 0/1 number issue, perhaps?
*shrugs*
Maybe it'd be easier if you artificially pad out the graphics by a pixel, to hide the line?

-=-=-
''Load, Next List!''
Fri, 08 Jul 2011, 15:35
JL235
I think it's a rounding problem. Currently one of the values is rounded, if I floor it instead then it moves the issue to different walls. Ceiling doesn't help either.

I'll look into it, or feel free to edit the project and debug my code.
Fri, 08 Jul 2011, 15:37
JL235
There is also a secret fullscreen version available here, but don't expect fullscreen urls to work forever (they might change)!
Fri, 08 Jul 2011, 15:40
Jayenkai
Mmmmm.. fullscreen!!!
Let us know once that's a perma-feature

-=-=-
''Load, Next List!''
Fri, 08 Jul 2011, 15:52
JL235
It needs a bit more polishing, like when it loads the background moves. We also need to come up with a symbol for it on the player.

There is also the issue about someone playing a game, then wanting to go fullscreen. They will lose their progress.
Sat, 09 Jul 2011, 13:28
JL235
I have also added 'conanical movement', which is essentially 'Shining in the Darkness' style movement.
Sat, 09 Jul 2011, 14:53
jedimastersterli
That's cool! There was no button list. Are there any options other than move forward backward and turn?
Sat, 09 Jul 2011, 17:01
JL235
Nope, no other options. But you could freely copy the code and add your own!
Sun, 10 Jul 2011, 10:24
JL235
It also now has two movement systems, free and conanical (you can press space to switch), crouch (left ctrl) and a basic zoom (z to zoom out, c to zoom in and x to reset).

I'm planning to build it into a fully working raycasting engine for others to use. Hopefully there will be a suddenly influx of Shining / Wolfenstein games in a few weeks.
Wed, 13 Jul 2011, 19:20
JL235
... and I've just added a fog, the walls now get darker as they are further away. It looks a lot prettier; I'd really like to build something proper with this.


Wed, 13 Jul 2011, 21:24
dna

the game makes me think of castle wolfenstein.

Was this game made before the first Duke nukem?

-=-=-
DNA
Thu, 14 Jul 2011, 15:18
jedimastersterli
You added angular motion, It was kinda annoying the first time having to do left, right, left, right, to move at an angle. It looks realy cool.

Reminds me of a Doom game i played when I was 8. just need a chainsaw and an evil alien and you'll be all set, lol.
Page : 1 2 Next
Prev