Jump to content

  • Log In with Google      Sign In   
  • Create Account


Member Since 18 Oct 2012
Offline Last Active Private

#5020520 Is it such possible to create fast games without using C/C++ ?

Posted by on 11 January 2013 - 05:24 PM

Comparing a C/C++ run-time to the Java/.NET framework dependency is a bit too much? The game I am working on has around 7 binary lib dependencies.. And they are all statically linked. The EXE has zero dependencies (other than standard Windows DLLs of course). Heck, it does not even need an installer. The only reason why most of the C++ games require MSVCR DLLs installed are because developers are lazy, don't want to build static libraries themselves for their compiler/MT/MD support and just link with the binary DLL packages they can find on the net.

#5019566 Is it such possible to create fast games without using C/C++ ?

Posted by on 09 January 2013 - 12:55 PM

Personally I think C/C++ is beautiful. You haven't learned programming until you are at the hardware level C/C++ allows you to be at. Still, for a newcomer - learning C++ (or even just C) is a bit overkill. As all the others, I do suggest starting with something more abstracted (Java/Python/C#/you name it).

#5016161 Strange bug in Release mode

Posted by on 31 December 2012 - 02:01 PM

I think there is no need for more code because even if i just add vector declaration (and nothing else) it just crashes my app in Release build, comment it and everything works.


I have recently seen some weird things happen when I use templates in VS2012. Have your tried to "Clean" up the .obj files and do a full rebuild of the project?

#5016016 How come many of you prefer to make games from scratch rather than use an eng...

Posted by on 31 December 2012 - 04:12 AM

I like engines. But more importantly, I like well abstracted, stable, flexible libraries. Isn't it great to wake up in the morning and realize there is a new 1.x.x release for one of the libraries you are using? It's like another person on the team did the job while you were sleeping. Same thing applies to engines.

#5015368 std::string and erase() to get data I need from string

Posted by on 29 December 2012 - 01:54 AM

Another approach (with regular expressions and boost lexical cast):

#include <regex>
#include <boost/lexical_cast.hpp>

std::cmatch matches;
std::regex regExp("\\s{0,}([0-9]+)\\s{0,}x([0-9]+)\\s{0,}x\\s{0,}([0-9]+)\\s{0,}", std::regex_constants::icase);

if (std::regex_match("100X200 x 300", matches, regExp)) {
  unsigned int width = boost::lexical_cast<unsigned int>(matches[1].str());
  unsigned int height = boost::lexical_cast<unsigned int>(matches[2].str());
  unsigned int depth = boost::lexical_cast<unsigned int>(matches[3].str());