CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 9 of 9
  1. #1
    Join Date
    Jun 2006
    Posts
    15

    Post What C++ would be best?

    Hey, Im going to learn C++ to build a server for an online im going to create.. what do you recommend I use. VC++ 6 or VC++ .NET?

    thanks.

    EDIT: Im not sure if this is in the right forum, sorry.
    Last edited by Benan; June 19th, 2006 at 09:47 AM.

  2. #2
    Join Date
    Jun 2002
    Location
    Stockholm, Sweden
    Posts
    1,641

    Re: What C++ would be best?

    I'm not sure what you mean, but in any case I would recommend old-style C++ because I find it more powerful and flexible.
    VC++.NET runs under a virtual machine and makes it very difficult to play with pointers, assembly code and such.

    Please note that it is possible to program old-style C++ aka "win32 application" in the new VS.NET IDE, so you do not have to buy old VS6.

  3. #3
    Join Date
    Sep 2004
    Posts
    519

    Re: What C++ would be best?

    If you want to program C++ with VS you really should use at least VS.NET 2003. The older versions of VS were good in their time (around 1998) but are severly lacking today in terms of language conformance.

    As previous poster pointed out you are not enforced to program "managed" when you program C++ in VS.NET. In fact I would say you are encouraged not to because if you want to go the managed track I think you should choose C# or VB.NET (so far I've only been tempted once to use Managed C++ and that was to leverage a C++ fixed size string serilializer I wrote that relied heavily on meta-programming techniques to push the performance to maximum while at the same time being type-safe and keeping code redundancy to a minimum).

    Also, the Microsoft compiler is actually free to download and with VS.Express you even get a stripped down studio for free to build your applications in.

    Having said that, if you want to build an server for an online game you will find that the threshold for that it is _much_ lower in C#, VB.NET or Java.

    Unless you have specific reasons for chosing C++ I think you should consider any of the forementioned languages as they have excellent support in their SDKs for building servers. You will be productive much faster.

    Hope this helps

  4. #4
    Join Date
    Jul 2005
    Location
    Germany
    Posts
    1,194

    Re: What C++ would be best?

    Why do you think C#, VB.NET or Java will be better than C++ using sockets?
    Please don't forget to rate users who helped you!

  5. #5
    Join Date
    Sep 2004
    Posts
    519

    Re: What C++ would be best?

    Quote Originally Posted by philkr
    Why do you think C#, VB.NET or Java will be better than C++ using sockets?
    From OP's post I assumed that he was new to C++ and wanted to learn it in order to build a server for an online service.

    Not better but it is easier and thus more productive. In this case where OP wants to learn C++ because he wants to implement a server for an online service. If he wants to do this is in C++ I suspect he needs to familiarize himself with at least:

    Threading (no support in C++ standard library)
    Sockets (no support in C++ standard library)
    Databases (no support in C++ standard library)
    Resource life-time management (easily managed in C++ if you adopt RAII but RAII isn't immedietly intuitive for most novices)

    All this is of course fixable by including platform libraries or other third-party libraries which is in itself a hassle.

    Java/VB.NET/C# has all the things above in their standard library. Also OP might be happy with a webservice/webapp and those are so easy to build in .NET that it's scary.

    Add a language (Java, C# and VB.NET are almost most equivalent) which many consider easier to learn than C++ due primary to two facts in my book:
    1. Garbage Collector (I'm not a big fan of this but many novices likes it)
    2. A fundamental string type (Which is great and unfortunately we will probably never get it in C++)

    I then think it's obvious for OP that he should at least consider other options that may turn out more productive for him.

    Don't get me wrong here. I really enjoy C++ and think it's a great language with many short comings (Lack of a fundamental string type the most glaringly obvious one IMO. Try to manipulate strings while writing meta-programs and you'll quickly see what I mean by no fundamental string type). In many situation it is the optimal choice but in one area it just can't beat Java/C#/VB.NET: Productivity

    And productivity matters in many real-world projects.

    Hope this helps

    PS. I can feel my rating drop after being the devil's advocate for a non-C++ language but I'm a strong believer of the right tool for the task.

  6. #6
    Join Date
    Jun 2006
    Posts
    16

    Re: What C++ would be best?

    Dont forget that Microsoft are implementing LINQ with C# and VB.NET, not with C++.NET

  7. #7
    Join Date
    Jun 2006
    Posts
    15

    Re: What C++ would be best?

    So what would you recommend.. The game im trying to build will be similar to runescape only different graphics and isnt targetted at Medi-evil.. I thought C++ would be the best, but if Java/C#/VB.NET is better.. then what one do you strictly recommend I built it in?

  8. #8
    Ejaz's Avatar
    Ejaz is offline Elite Member Power Poster
    Join Date
    Jul 2002
    Location
    Lahore, Pakistan
    Posts
    4,211

    Re: What C++ would be best?

    [ Moved Thread ]

  9. #9
    Join Date
    Dec 2004
    Posts
    85

    Re: What C++ would be best?

    Quote Originally Posted by Benan
    So what would you recommend.. The game im trying to build will be similar to runescape only different graphics and isnt targetted at Medi-evil.. I thought C++ would be the best, but if Java/C#/VB.NET is better.. then what one do you strictly recommend I built it in?
    It depends on whether you want users to have to download client software to be able to connect to the game. If you want users to be able to play it by going to a website (like with Runescape) you really have no choice but to write it in Java. Otherwise, I would go with one of the .NET languages.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured