Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 4 of 4

Thread: repeating world

  1. #1
    Newbie Newbie
    Join Date
    Oct 2013
    Posts
    2

    repeating world

    I'm making a game where, like pacman, if you go off one side of the screen you come out on the other side. However the camera follows the player so it cant just be a matter of changing the player's coordinates. Is there an opengl solution other than just re rendering everthing multiple times?

  2. #2
    Intern Newbie
    Join Date
    Dec 2013
    Posts
    45
    How large is the world? If it is smaller than your intended render distance, I'm sure that could complicate things much more. The details of the problem really affect the possible solutions.

  3. #3
    Newbie Newbie
    Join Date
    Oct 2013
    Posts
    2
    I would have thought I'm going to render smaller than the world. But I'm still not sure how you would go about solving this problem.

  4. #4
    Intern Newbie
    Join Date
    Dec 2013
    Posts
    45
    You could probably split your world up into multiple sections (say, different sections for each edge and corner), and then translate them to where you want them to be seen when the camera is near the edge or corner. Then, once you cross the line, you could change the players coordinates to wrap around seamlessly.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •