Need general advice!

Hello cplusplus community!

First of all, I do not currently need any actual help with coding. I just need general advice of how to begin to work on an issue I have run into. Maybe you can help me out with some tips. :)

I have begun working on a C++ project in my free time using the QT IDE. I have heard a semester worth of lectures in C++ and I have watched a few QT tutorials to get accustomed to the immediate basics. In other words: I am still a bloody beginner.

My goal is to create a desktop application consisting of various windows functioning as small tools to do simple calculations or visual check lists.

I have devised this project up into small chunks to help me work towards concise goals. The first part will be a window allowing me to build rockets (the space flying sort) from stages. The user will be required to enter values such as mass and fuel and then select from a list of engines to be attached to the stage. The program will then do various calculations and display things such as burn time, effective impulse (delta-v) and generate a simple diagram of the entire rocket.

The part with the engines is what I am currently working on and I am unsure how to handle it. Each engine has characteristics such a name, a thrust, an isp, an mass and so on. I have chosen to create a class called "Engine" to help me store the data. Was this the correct decision? Are there maybe containers that can do the same job better in this case? Secondly, I want to load the 20 or so different engines from a list called "partdata.csv". This will happen on application start-up. If the file is not found, dummy data will be loaded instead. When the user is creating stages, he will be able to pick the desired Engine via a drop down menu.

I can handle loading the "partdata.csv" and parsing the necessary information, however I am unsure how to store it. I'll be needing to generate instances of "Engine" automatically and filling them with the data from the part table. I was thinking about generating a list of class instances. However, while working with lists in the past, I have realized that they are often tedious to extract information from (I seem to be needing to run an iterator to get to a certain point) and secondly, each Engine will have a unique identifier (index or short name) so I can save entire rockets for later use. I don't know how I could make that work with a list since you're allowed to delete and insert items at will. I need something more solid, like a data base.

Can you point me to the correct direction?

I'll be glad to receive ideas.

Three :)
Last edited on
Would you guys rather help with a concrete problem? Should I be posting my source code? :)

I'd figure that asking a general question would be better for you. :)
closed account (1vD3vCM9)
Building such thing as a KSP (Kerbal space program) requires you to know graphics programming, and the windows API ( if you want to work only on Windows )
If you are still a beginner, then the truth is sad. You won't be able to do such things so easily.
You need years of experience with C++.
For some thing you may create your own game engine (which is touching the sky. ), or use an existing one.
But first you need to learn the BASICS of C++, parsing info is extremely difficult.
Learn the basics for some months and practice a lot.
Then you can start to learn graphics programming, pick up a book lime Game Engine Architecture (8th edition) and the opengl red book.
I am not making anything like Kerbal Space Program. Like I said in the OP: It's a simple tool. A few windows, a few tiny diagrams.

I see. The way I asked this question made you guys not inclined to even read it. Maybe it's better I throw some half assed code into here and ask "me n00b fix plz".
closed account (1vD3vCM9)
A few Windows, diagrams, those things require graphics.

I have read it. But still a simple application with diagrams requires still graphics.
Then forget the diagrams. It's not the point of this post.

My question boils down to this: Are lists of class instances something good to work with? How do I handle indexing them?

The rest of the info is to help you understand what I am trying to build in the long run. I have no idea what information is necessary, that's why I included everything.
Last edited on
Topic archived. No new replies allowed.