Java-Gaming.org
Java4K - to go         Javadoc:
Featured games (67)
games approved by the League of Dukes
Games in Showcase (∞)
games submitted by our members



News: Read the Java Gaming Resources or peek at the official java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  Print  
  Ludum Dare #15  (Read 1915 times)
0 Members and 1 Guest are viewing this topic.
Offline Morre

Sr. Member
**

Posts: 494


I'm Dragonene on IRC.


« on: 2009-08-27 08:04:18 »

Ludum Dare #15, a solo 48h game programming competition, is coming up this weekend (August 28th-30th). I'm definitely planning to enter!

I know this is a bit of a late post about it, but better late than never, right? Smiley

Offline rdcarvallo

Sr. Member
**

Posts: 300


2D Java games forever!


« Reply #1 on: 2009-08-27 14:49:04 »

Ok,

    I registered in the site. I'll try to make something, hoping to have more time than the 6+ hours I had for the JGO'09 "Bending" compo.

    Look for rdcarvallo's posts on LD.

Offline Morre

Sr. Member
**

Posts: 494


I'm Dragonene on IRC.


« Reply #2 on: 2009-08-30 22:21:34 »

I'm done! Cavernous Shooter! is a little top-down shooter set in a cave environment.

Windows / OSX / Linux / Source
Java Webstart


Games published by our own members! Go get 'em!
Offline CommanderKeith

JGO Wizard
****

Posts: 1447
Medals: 9



« Reply #3 on: 2009-08-31 04:50:54 »

Cool game! I like that type of top-down view shooter. May I ask, how did you do the physics for when the player crashes into the walls?

Offline Morre

Sr. Member
**

Posts: 494


I'm Dragonene on IRC.


« Reply #4 on: 2009-08-31 10:51:09 »

Thanks!

As for my implementation, it is somewhat broken (I've a normalization bug, and didn't have time to fix it, and wall collision is a bit sloppy too), but here's the idea:

First I look for player/line intersections. If one is found, I move the player back to where he was before this update. Then I calculate the dot product of the player's movement vector and the surface's normal vector. Finally I subtract the normal vector multiplied by the dot product from the player's movement vector. This new movement is applied to the player, making him slide along the wall. That's it!

A better idea then looking for object/line intersections would naturally be to check if the object has passed or collided with the wall in the current update, but I was a bit lazy about that and am relying on framerate instead (which I suppose might have been a mistake in retrospect).

Maybe I should also point out that although levels are sets of polygons, I always split those up into a set of lines before actually doing any calculations on them.

Offline CommanderKeith

JGO Wizard
****

Posts: 1447
Medals: 9



« Reply #5 on: 2009-09-01 07:06:22 »

Wow, well that works well. I never knew it could be so simple, nice job!

Pages: [1]
  Print  
 
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.14 seconds with 20 queries.