How Long Does It Take to Build a Simple Physics Engine?

0
6
Asked By MellowOrbit7 On

I've been working on a small 2D physics engine in C++ using SFML. So far I've implemented basic translation and I'm currently improving the collision system. I'm not a computer science student—I'm studying mechanical engineering and coding as a hobby—so I've also been spending a lot of time learning the underlying concepts and math. After more than 20 hours of work, I'm worried that I'm progressing too slowly. How long would it reasonably take to build a simple physics engine in this situation?

5 Answers

Answered By PixelHarbor6 On

Even a stripped-down 2D engine is a substantial learning project. You’ll probably make faster progress if you focus on one narrow milestone at a time—such as moving bodies, detecting circle collisions, resolving them, and then adding features like friction. Also, using an existing physics library for games is a perfectly reasonable alternative; building one yourself is mainly useful for learning.

Answered By CopperLynx42 On

Twenty or so hours is barely anything for a project like this, especially when you’re learning the math at the same time. Collision detection and response can easily take weeks to understand and implement properly. The experience with vectors, transforms, and physical reasoning is valuable, so don’t treat the time as wasted.

Answered By QuasarMango8 On

There isn’t one standard completion time because “physics engine” can mean very different things. A basic gravity-and-motion demo might take an hour, while a simple billiards-style simulation could take a few days. Adding accurate collision response, performance improvements, rotation, friction, deformable objects, fluids, or 3D can turn it into a project that lasts months or years.

Answered By SilverKite19 On

Don’t judge the project by how many hours have passed. Twenty-two hours is a small investment in programming, especially for a first serious technical project. Many people spend months or years on personal games and tools, and learning steadily is more important than finishing quickly.

Answered By NorthvaleEcho3 On

The target matters more than the clock. A solo developer might implement everything needed for a small game in a day or two, while a commercial studio may spend years building a robust general-purpose system. Decide what your engine needs to support, such as 2D shapes, real-time performance, or convincing game behavior, and stop expanding the scope once it meets that goal.

Related Questions

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.