   many noob questions!?
  a few yrs back i did a pong clone where i simply moved the ball +1 on the x and y coordinates per frame to simulate movement. when i wanted the ball to move at a faster rate, i increased it to +2 increments per frame. as you can see now, its gets ugly and doesnt really simulate real movement.now i am using a rendering engine and would like to know how its done. i know time is important and the game time doesnt care what the frame rate is correct?for example if i wanted a ball to move horizontally slowly from position x 1 to x 100 and reach its destination in 10 seconds with a smooth animation, what values are important to make this happen with a game engine? time, speed, and the time between the current and last frame?a frame is nothing but a picture/snapshot of everything that is visible in the view right? just like a flip picture book right?also, when you define something in size x/y coordinates, how large is that? does the size of x/y change from the distance you are looking at it from?for example lets say i define a square that is 10 by 10 starting at the 0 x/y coordinate. and lets say my camera exist on the z coordinate defined to 50 looking at the square. how large is the square? basically what sizes should be typically used if i was to make another pong clone?    
  I'm only going to answer a few of your items right now, hopefully others will be by soon.  (BTW numbering your lists makes it easier for responses to be directed to the right question).4.  (Frame / Flipbook)  Correct, a frame is just one rendering of the screen / image of the game world.  It is usually a single snapshot of the world that correctly represents a moment in time.5.  The "size" of a unit is not defined (I'm answering from an OpenGL point of view).  You define it and use it consistently within your rendering, then you affect the camera and non-world items to control how it is rendered on screen.  Usually you determine this by experiment.  For instance, say you choose centimeters as your base unit.  Then when you make models you choose to store them using numbers that would match this.  In the case of pong, there is no such thing as a "real world" measure to use.  So you pick an arbitrarily defined unit.  You could say "1 represents the size of a standard ball" or the length of a standard paddle.  Or even, 1 represents the height of the window (which is a good choice for a sideways pong game because then everything in the game world would be in percentages of the size of the "goal".Then when you show the screen, if you use "orthogonal" projections, things do not get smaller as they get farther away, if you use "perscpective" projections, they do.  So you pick your zoom / camera settings to make the world look correct (which is whatever you want it to look like).   ;  oic see, so everything i define in terms of size should just be relative to each other.now about the frame instance, typically in what unit of time is this measured? seconds, milisecods, etc...? Quote:Original post by XaiI'm only going to answer a few of your items right now, hopefully others will be by soon.  (BTW numbering your lists makes it easier for responses to be directed to the right question).4.  (Frame / Flipbook)  Correct, a frame is just one rendering of the screen / image of the game world.  It is usually a single snapshot of the world that correctly represents a moment in time.5.  The "size" of a unit is not defined (I'm answering from an OpenGL point of view).  You define it and use it consistently within your rendering, then you affect the camera and non-world items to control how it is rendered on screen.  Usually you determine this by experiment.  For instance, say you choose centimeters as your base unit.  Then when you make models you choose to store them using numbers that would match this.  In the case of pong, there is no such thing as a "real world" measure to use.  So you pick an arbitrarily defined unit.  You could say "1 represents the size of a standard ball" or the length of a standard paddle.  Or even, 1 represents the height of the window (which is a good choice for a sideways pong game because then everything in the game world would be in percentages of the size of the "goal".Then when you show the screen, if you use "orthogonal" projections, things do not get smaller as they get farther away, if you use "perscpective" projections, they do.  So you pick your zoom / camera settings to make the world look correct (which is whatever you want it to look like).;Quote:Original post by bakera few yrs back i did a pong clone where i simply moved the ball +1 on the x and y coordinates per frame to simulate movement. when i wanted the ball to move at a faster rate, i increased it to +2 increments per frame. as you can see now, its gets ugly and doesnt really simulate real movement.now i am using a rendering engine and would like to know how its done.I recently made a pong clone using the HGE library to see how I liked using it. The way I did the movement was with some simple physics.Heres the basic way I went about doing it:xBallPosition += (xBallVelocity) * ballSpeed * time;yBallPosition += (yBallVelocity) * ballSpeed * time;All values are designated as float data types.;Quote:Original post by DevLiquidKnightQuote:Original post by bakera few yrs back i did a pong clone where i simply moved the ball +1 on the x and y coordinates per frame to simulate movement. when i wanted the ball to move at a faster rate, i increased it to +2 increments per frame. as you can see now, its gets ugly and doesnt really simulate real movement.now i am using a rendering engine and would like to know how its done.I recently made a pong clone using the HGE library to see how I liked using it. The way I did the movement was with some simple physics.Heres the basic way I went about doing it:xBallPosition += (xBallVelocity) * ballSpeed * time;yBallPosition += (yBallVelocity) * ballSpeed * time;All values are designated as float data types.you multiply the velocity, time and speed?i thought it was just velocity and time or speed and time?why all 3? or am i missing the meaning of the parentheses?;  Perhaps x/yBallVelocity are the X and Y components of a unit vector describing the motion of the ball?   ;  Yeah, my guess is that xBallVeloity and yBallVelocity are just the x and y components of a direction vector for the ball.And for your other question, the way time is measured is up to you and how much resolution you need on it.  Usually you use milliseconds to measure elapsed time because most functions that tell you about elapsed time will give you the reuslt in milliseconds.  If you measure in seconds, you'll either have to use a function that gives it to you as a floating point value (like 0.01 seconds), or deal with 1 second resolution time (as in, your objects only perceive change once per second).  Using milliseconds (assuming a decent resolution on the timer), will usually let you measure elapsed time to a resolution of 1/100 second or better.To move an object using a time basis, you need at least three values: current position p, velocity v, and elapsed timet.  Current position and velocity are both vectors (in as many dimensions as your object can traverse) and elapsed time is a scalar.  Then you would find the new position like so:p_new = p + t*vTypically, position is in units, time is in milliseconds and velocity is in units per millisecond.  Alternatively, time is in seconds and velocity is in units per second.As already mentioned, units is an arbitrary measurement that you define relative to your camera usage and the other objects in your scene.  You typically endeavour to make the unit sizes as convenient as possible.  This might be disorienting, but do realize that the real world measurement systems are no less arbitrary (feet and inches are derived from the sizes of the feet and some part of the hand of rulers in Europe), so you just have to pick some way to gauge a unit in your scenes.Hope that's all helpful...-Auron;  "Typically, position is in units, time is in milliseconds and velocity is in units per millisecond. Alternatively, time is in seconds and velocity is in units per second."The distinction should be noted that velocity is usually represented by a vector or other way to measuring the direction componenents. That is what makes velocity different than speed, the "direction" information.   