Jump to content
MakeWebGames

Recommended Posts

Posted

Look forward to trying New Worlds Engine out hopefully this weekend...... Since my classes are becoming more intense I havent been able to keep up with this.

I actually started writing my own C++ programs for the first time so that has been fun and challenging

Posted
Look forward to trying this out hopefully this weekend...... Since my classes are becoming more intense I havent been able to keep up with this.

I actually started writing my own C++ programs for the first time so that has been fun and challenging

Oh you're learning c++? So am I! :D

Where have you reached till now?

Posted

Moved posts to a new location... please feel free to continue to share your C++ (nightmares) here. /me abandoned C++ quiet some time ago... simply too painful and not all that useful for what I do anymore.

Posted

I didnt mean database as in for web development, I meant to store the information locally, right now for my bank program for example, what happens is that I input user details etc but once I switch off the program the user details are lost.

Posted

I see, do you think right now it would be more important for me to concentrate on c++ concepts like classes objects pointers etc or take a quick swing at data persistance?

Posted

Well, I haven't really used C++ a lot, I was busy more with just C, not that it's such a huge difference.

If you're up for the challenge, write a decent UI and make it work with a mysql database over the LAN. and in the end make it run on linux. I'll be happy to test it for you ;)

btw, if there relly is a decent interest in C/C++, we'll add a board for it, but that will only done when there are enough actual posts on the forum, here in other programming!

Posted

For user interface I strongly suggest QT. However as said, I don't believe C++ is that much a good language for it. Use Java or C# for interfaces / database / web development and more.

C++ is good for driver development, low level development, and high performance or embedded systems. C on the other side is good to understand how really code works (like pointers, pointers to functions and more).

Posted

That is why we learned C, it was merely to understand how the basics of programming work, like you said. We never made any real user interfaces or connect to other services. We did make a small console game, which was either fisherman or 4 in a row.

Still, I don't mind them trying. The experience will learn them something somehow.

Posted

For sure it is EXTREMELY useful. I would say you will never really have a good understanding of programming till you managed to understand pointers and pointers to functions. Why? Well even in PHP or Java where pointers are mostly hidden you find from time to time "references" which are nothing else as pointers (or related to pointers). Also understand how things work under allow you some times to grab more easily further concepts.

Posted

LOL wow I was like when did I create this thread LMAO

 

Actually I am in my first semester of C++ , we just started working on inputs and outputs, just the basics right now

Posted

Good! Exactly where you should start ... the basics :-P no point in trying to jump in the middle of all the action. You'll get lost, especially in C/C++ as it doesn't leave a lot of room for mistakes, which wouldn't even be considered mistakes in other languages.

Posted
oh man i have found that out really well so far

missing ; here and there are killing me LOL

In my theory paper I missed ' ' and I lost 2 marks straight :P

Oh and the difference between == and = also manages to confuse me everytime :P

Posted

Okay C++ question,

I have made a banking program, a library program and a random number guessing game all small projects in different files.

Now I was windering is it possible in C++ to make a central file which will call these files?

I'm thinking maybe a switch statement and if you input 1 it will call the banking program if you input 2 the library program and so on, can someone tell me if this is possible and if it is what is the code to call another file?

Posted
Okay C++ question,

I have made a banking program, a library program and a random number guessing game all small projects in different files.

Now I was windering is it possible in C++ to make a central file which will call these files?

I'm thinking maybe a switch statement and if you input 1 it will call the banking program if you input 2 the library program and so on, can someone tell me if this is possible and if it is what is the code to call another file?

A question about modular programming in C++. Oh the joys.

To answer it, yes, it's possible to link the files.

AFAIK, sources files are converted to .obj's, and linked together after compilation by the linker to form the lib/executable. You do not need to per say "include them", as it's linked afterwards. I'm not saying "#include <myfile.c>" won't work(it will), it's just not very proper to do so.

What you do rather in C/++/insert-random-descendant-here, is create header files. Those are very easy to spot, as they carry an extension .h.

One would define the functions(among others) in there, and then include it in the main .c script, eg. "#include <myfunc.h>".

Ref 1: http://gcc.gnu.org/onlinedocs/cpp/Include-Syntax.html

Ref 2: http://en.wikipedia.org/wiki/Header_file

Ref 3: http://www.cplusplus.com/forum/articles/10627/

Posted
A question about modular programming in C++. Oh the joys.

To answer it, yes, it's possible to link the files.

AFAIK, sources files are converted to .obj's, and linked together after compilation by the linker to form the lib/executable. You do not need to per say "include them", as it's linked afterwards. I'm not saying "#include <myfile.c>" won't work(it will), it's just not very proper to do so.

What you do rather in C/++/insert-random-descendant-here, is create header files. Those are very easy to spot, as they carry an extension .h.

One would define the functions(among others) in there, and then include it in the main .c script, eg. "#include <myfunc.h>".

Ref 1: http://gcc.gnu.org/onlinedocs/cpp/Include-Syntax.html

Ref 2: http://en.wikipedia.org/wiki/Header_file

Ref 3: http://www.cplusplus.com/forum/articles/10627/

Thanks! :)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...