Am building a 2D top down game where there are roads, and intersections, and the user is creating a path, for the car to follow, but that path can be created only on the road, and it has to centre itself on that road. How would I attempt to do this? Am developing in Unity btw.
Right now am gathering the points on input, and based on the direction of the drawn path, it knows if its moving horizontally or vertically, but I am not quite sure how to figure out if its turning. My implementation knows if its turning but it also includes diagonals.
When building a physics engine, how do we handle simulation time, how can it be controlled from system to system (different hardware), how is it maintained? Can you also explain to me the most efficient way to handle frame data, for backtracking and so on.
Am planning on trying to build a game engine. Its gonna be an engine that would be refined or built specifically for fighters, and beat em ups. Anyway, I was kinda wondering what are the tools or libraries I may need in conjunction with OpenGL, GLSL, and C++.
- A simpler math library, support for vectors, quaternions, and so on. I have been using GLM, but I'd like to just have header file.
- A sound library, I want to be able to possibly use the pitch and tone, etc to manipulate colors, and lighting.
- A model loader of sorts, support for .obj, .max, etc..
- A GUI library.
Let me know if you know of any that meet the above criteria, and if you think of any other libs or tools that could come in handy please let me know.
Hey, am trying to move an object along a series of slopes, and also make it follow a trajectory when it reaches a certain velocity at the apex of a slope. Am having a few issues with my code. Am coding in C# Unity, so am using Unity's rigid body and collision system, and varying properties as and when required. I would really appreciate it someone could just check and see if there is anything wrong with it.
When I accelerate up a slope, it accelerates but on reaching the top or the apex of the slope it starts to move back down. And when I accelerate down a slope it moves very slowly or doesn't move at all (it should be moving at a greater acceleration).
What is the appropriate condition or process to use to synch all the movement together (such that it is smooth and seamless).