|
Post by TheRPGNOOb on Dec 16, 2004 17:01:00 GMT -5
Like in Astroids, where the player goes out the other side and comes in the other. How to do that in d3d without creating a noticable screen 'twitch'.
|
|
|
Post by IsmAvatar on Dec 17, 2004 13:52:31 GMT -5
draw the room beyond its boundaries, repeating whatever's on the other side. This way, the user will see the other side of the room, so it doesn't look like they walk into a wall which turns out to be a portal.
then, when they hit the boundary, just make them jump back to the other side of the world.
|
|
|
Post by TheRPGNOOb on Dec 17, 2004 19:52:43 GMT -5
That's something like what I did...problem is getting it to jump to the right place when it's outside of the boundry, that's how I got the screen twitch. Besides trial-and-error is there another way that I can calculate where it needs to place the player?
|
|
|
Post by IsmAvatar on Dec 17, 2004 21:32:59 GMT -5
if you use direction and speed, you can use hspeed and vspeed to get the offset when you wrap.
|
|