Jump to content
gauauu

Wall collisions in Adventure

Recommended Posts

Does anyone know exactly how the wall collisions were handled in Adventure?  

 

The way the ball (player) squashes against the walls (and missiles for the weird black walls, if I remember correctly?) makes it look like it's checking hardware collisions. But the fact that the walls aren't "sticky" means that Warren did something smarter than just the naive "reset the position if there's a collision" method. 

 

As best I can tell, from staring at the disassembly and stepping through frames, he was definitely doing hardware collision detection. It looks like maybe he resets the X position separately from resetting the Y position, on different frames (checking collisions each time). But if that's the case, I can't figure out how your movement doesn't end up going more slowly when you are dragging along a wall (if it wastes a frame trying to reset position in one dimension).

 

Thanks!

Share this post


Link to post
Share on other sites

Ah, the part I missed is that he does it differently in different frames. Like I suspected, he checks X-only direction one frame, and Y-only direction in a different frame.

Share this post


Link to post
Share on other sites

Ah, the part I missed is that he does it differently in different frames. Like I suspected, he checks X-only direction one frame, and Y-only direction in a different frame.

 

I did a similar thing with my Carrot Kingdom game it works well for splitting up gravity and horizontal collisions as well. :3

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...