What is C++ for?
#1
Posted 09 May 2012 - 08:00 AM
- Hunter Console - A Small Gadget
- HunterPad - Basic Notepad aimed at Programmers
- Betters UP! - Betting Game
#2
Posted 09 May 2012 - 08:06 AM
Was that a rhetorical question?What is C++ used for?
Who said C++ isn't good for UI creation? I'm currently using Opera which is written in C++ and that has a fancy UI.
Edit: This is a limited list, but you can clearly C++ is used quite a lot in software development.
Edited by guinness, 09 May 2012 - 08:11 AM.
Example List: _AdapterConnections() • _AlwaysRun() • _AppMon() • _AppMonEx() • _BinaryBin() • _CheckMsgBox() • _CmdLineRaw() • _ContextMenu() • _DesktopDimensions() • _DisplayPassword() • _Fibonacci() • _FileCompare() • _FileCompareContents() • _FileNameByHandle() • _FilePrefix/SRE() • _FindInFile() • _GetBackgroundColor()/_SetBackgroundColor() • _GetConrolID() • _GetCtrlClass() • _GetDirectoryFormat() • _GetDriveMediaType() • _GetFilename()/_GetFilenameExt() • _GetHardwareID() • _GetIP() • _GetIP_Country() • _GetOSLanguage() • _GetSavedSource • _GetStringSize() • _GetSystemPaths() • _GetURLImage() • _GIFImage() • _GoogleWeather() • _GUICtrlCreateGroup() • _GUICtrlListBox_CreateArray() • _GUICtrlListView_CreateArray() • _GUICtrlListView_SaveCSV() • _GUICtrlListView_SaveHTML() • _GUICtrlListView_SaveTxt() • _GUICtrlListView_SaveXML() • _GUICtrlMenu_Recent() • _GUICtrlMenu_SetItemImage() • _GUICtrlTreeView_CreateArray() • _GUIDisable() • _GUIImageList_SetIconFromHandle() • _GUISetIcon() • _Icon_Clear()/_Icon_Set() • _InetGet() • _InetGetGUI() • _InetGetProgress() • _IPDetails() • _IsFileOlder() • _IsGUID() • _IsHex() • _IsPalindrome() • _IsRegKey() • _IsStringRegExp() • _IsUPX() • _IsValidType() • _IsWebColor() • _Language() • _Log() • _MicrosoftInternetConnectivity() • _MSDNDataType() • _PathFull/GetRelative/Split() • _PathSplitEx() • _PrintFromArray() • _ProgressSetMarquee() • _ReDim() • _RockPaperScissors()/_RockPaperScissorsLizardSpock() • _ScrollingCredits • _SelfDelete() • _SelfRename() • _SelfUpdate() • _SendTo() • _ShellAll() • _ShellFile() • _ShellFolder() • _SingletonHWID() • _SingletonPID() • _Startup() • _StringIsValid() • _StringReplaceWholeWord() • _StringStripChar() • _Temperature() • _TrialPeriod() • _UKToUSDate()/_USToUKDate() • _WinAPI_CreateGUID() • _WMIDateStringToDate()/_DateToWMIDateString() • AutoIt Search • AutoIt3 Portable • AutoItWinGetTitle()/AutoItWinSetTitle() • Coding • FileInstallr • GeoIP database • GUI - Only Close Button • GUI Examples • GUICtrlDeleteImage() • GUICtrlGetBkColor() • GUICtrlGetStyle() • GUIGetBkColor() • LockFile() • PasteBin • SciTE Jump • Signature Creator • WM_COPYDATA • More Examples...Updated: 11/04/2013
#3
Posted 09 May 2012 - 08:27 AM
- Hunter Console - A Small Gadget
- HunterPad - Basic Notepad aimed at Programmers
- Betters UP! - Betting Game
#4
Posted 09 May 2012 - 08:33 AM
C++ is the dominant general programming language in the world today I imagine (though I haven't see the stats recently). It is powerful, far more so than AutoIt, and of course it can make GUIs using a number of toolkits (in most cases just the Windows API, but you'll a lot of GTK+ apps as well).
I don't know where I'm going, but I'm on my way.
#5
Posted 09 May 2012 - 08:42 AM
I didn't think you were rude, just misled.I didnt mean to come across rude, but I was more just wondering.
Example List: _AdapterConnections() • _AlwaysRun() • _AppMon() • _AppMonEx() • _BinaryBin() • _CheckMsgBox() • _CmdLineRaw() • _ContextMenu() • _DesktopDimensions() • _DisplayPassword() • _Fibonacci() • _FileCompare() • _FileCompareContents() • _FileNameByHandle() • _FilePrefix/SRE() • _FindInFile() • _GetBackgroundColor()/_SetBackgroundColor() • _GetConrolID() • _GetCtrlClass() • _GetDirectoryFormat() • _GetDriveMediaType() • _GetFilename()/_GetFilenameExt() • _GetHardwareID() • _GetIP() • _GetIP_Country() • _GetOSLanguage() • _GetSavedSource • _GetStringSize() • _GetSystemPaths() • _GetURLImage() • _GIFImage() • _GoogleWeather() • _GUICtrlCreateGroup() • _GUICtrlListBox_CreateArray() • _GUICtrlListView_CreateArray() • _GUICtrlListView_SaveCSV() • _GUICtrlListView_SaveHTML() • _GUICtrlListView_SaveTxt() • _GUICtrlListView_SaveXML() • _GUICtrlMenu_Recent() • _GUICtrlMenu_SetItemImage() • _GUICtrlTreeView_CreateArray() • _GUIDisable() • _GUIImageList_SetIconFromHandle() • _GUISetIcon() • _Icon_Clear()/_Icon_Set() • _InetGet() • _InetGetGUI() • _InetGetProgress() • _IPDetails() • _IsFileOlder() • _IsGUID() • _IsHex() • _IsPalindrome() • _IsRegKey() • _IsStringRegExp() • _IsUPX() • _IsValidType() • _IsWebColor() • _Language() • _Log() • _MicrosoftInternetConnectivity() • _MSDNDataType() • _PathFull/GetRelative/Split() • _PathSplitEx() • _PrintFromArray() • _ProgressSetMarquee() • _ReDim() • _RockPaperScissors()/_RockPaperScissorsLizardSpock() • _ScrollingCredits • _SelfDelete() • _SelfRename() • _SelfUpdate() • _SendTo() • _ShellAll() • _ShellFile() • _ShellFolder() • _SingletonHWID() • _SingletonPID() • _Startup() • _StringIsValid() • _StringReplaceWholeWord() • _StringStripChar() • _Temperature() • _TrialPeriod() • _UKToUSDate()/_USToUKDate() • _WinAPI_CreateGUID() • _WMIDateStringToDate()/_DateToWMIDateString() • AutoIt Search • AutoIt3 Portable • AutoItWinGetTitle()/AutoItWinSetTitle() • Coding • FileInstallr • GeoIP database • GUI - Only Close Button • GUI Examples • GUICtrlDeleteImage() • GUICtrlGetBkColor() • GUICtrlGetStyle() • GUIGetBkColor() • LockFile() • PasteBin • SciTE Jump • Signature Creator • WM_COPYDATA • More Examples...Updated: 11/04/2013
#6
Posted 09 May 2012 - 08:42 AM
- Hunter Console - A Small Gadget
- HunterPad - Basic Notepad aimed at Programmers
- Betters UP! - Betting Game
#7
Posted 09 May 2012 - 08:43 AM
Edited by guinness, 09 May 2012 - 08:45 AM.
Example List: _AdapterConnections() • _AlwaysRun() • _AppMon() • _AppMonEx() • _BinaryBin() • _CheckMsgBox() • _CmdLineRaw() • _ContextMenu() • _DesktopDimensions() • _DisplayPassword() • _Fibonacci() • _FileCompare() • _FileCompareContents() • _FileNameByHandle() • _FilePrefix/SRE() • _FindInFile() • _GetBackgroundColor()/_SetBackgroundColor() • _GetConrolID() • _GetCtrlClass() • _GetDirectoryFormat() • _GetDriveMediaType() • _GetFilename()/_GetFilenameExt() • _GetHardwareID() • _GetIP() • _GetIP_Country() • _GetOSLanguage() • _GetSavedSource • _GetStringSize() • _GetSystemPaths() • _GetURLImage() • _GIFImage() • _GoogleWeather() • _GUICtrlCreateGroup() • _GUICtrlListBox_CreateArray() • _GUICtrlListView_CreateArray() • _GUICtrlListView_SaveCSV() • _GUICtrlListView_SaveHTML() • _GUICtrlListView_SaveTxt() • _GUICtrlListView_SaveXML() • _GUICtrlMenu_Recent() • _GUICtrlMenu_SetItemImage() • _GUICtrlTreeView_CreateArray() • _GUIDisable() • _GUIImageList_SetIconFromHandle() • _GUISetIcon() • _Icon_Clear()/_Icon_Set() • _InetGet() • _InetGetGUI() • _InetGetProgress() • _IPDetails() • _IsFileOlder() • _IsGUID() • _IsHex() • _IsPalindrome() • _IsRegKey() • _IsStringRegExp() • _IsUPX() • _IsValidType() • _IsWebColor() • _Language() • _Log() • _MicrosoftInternetConnectivity() • _MSDNDataType() • _PathFull/GetRelative/Split() • _PathSplitEx() • _PrintFromArray() • _ProgressSetMarquee() • _ReDim() • _RockPaperScissors()/_RockPaperScissorsLizardSpock() • _ScrollingCredits • _SelfDelete() • _SelfRename() • _SelfUpdate() • _SendTo() • _ShellAll() • _ShellFile() • _ShellFolder() • _SingletonHWID() • _SingletonPID() • _Startup() • _StringIsValid() • _StringReplaceWholeWord() • _StringStripChar() • _Temperature() • _TrialPeriod() • _UKToUSDate()/_USToUKDate() • _WinAPI_CreateGUID() • _WMIDateStringToDate()/_DateToWMIDateString() • AutoIt Search • AutoIt3 Portable • AutoItWinGetTitle()/AutoItWinSetTitle() • Coding • FileInstallr • GeoIP database • GUI - Only Close Button • GUI Examples • GUICtrlDeleteImage() • GUICtrlGetBkColor() • GUICtrlGetStyle() • GUIGetBkColor() • LockFile() • PasteBin • SciTE Jump • Signature Creator • WM_COPYDATA • More Examples...Updated: 11/04/2013
#8
Posted 09 May 2012 - 08:47 AM
The stats recently.C++ is the dominant general programming language in the world today I imagine (though I haven't see the stats recently).
@OP, you have to be patient. First you learn programming, then you learn to make games. Doing both at once, some people have done it, but they're either not very good programmers or not very good game designers.
I started game programming with C# + XNA using this tutorial. It's extremely lacking in teaching you how to program well, but it does teach you how to draw 2D and 3D objects. Don't start with this if you don't already have decent object oriented programming experience. (The tutorial ends with a single 624 line file with one class containing about 30 declarations and 15 methods.)
If you need programming experience, you may as well stick with AutoIt for a year and then explore other languages. There are no "automatic winner" beginner languages, but something imperative, dynamic and weakly typed will get you a long way with relative little effort.
Edited by Manadar, 09 May 2012 - 08:51 AM.
#9
Posted 09 May 2012 - 11:30 AM
That's a lot of people still using C. I wonder how many of those results is people not making the distinction between the two clear, on stackoverflow one of the most common problems is people that tag a question "C/C++" when it applies to just one of them.The stats recently.
I don't know where I'm going, but I'm on my way.
#10
Posted 09 May 2012 - 12:23 PM
I wondered the same thing. If I must guess, I would say a lot. Perhaps bringing C++ to #1?That's a lot of people still using C. I wonder how many of those results is people not making the distinction between the two clear, on stackoverflow one of the most common problems is people that tag a question "C/C++" when it applies to just one of them.
#11
Posted 09 May 2012 - 01:13 PM
COBOL is still on that list. I'm worried for those businesses.The stats recently.
#12
Posted 09 May 2012 - 03:46 PM
What do you think where it would be positioned if included in survey?
eMyvnE
#13
Posted 09 May 2012 - 03:58 PM
Thats a very simple test though.
I don't know where I'm going, but I'm on my way.
#14
Posted 09 May 2012 - 04:59 PM
Right, very simple. A more useful comparison would be the popularity among windows programmers since AutoIt cannot be used on Unix/Linux. The Google search cannot respect that fact.Thats a very simple test though.
#15
Posted 09 May 2012 - 06:15 PM
I checked if AutoIt could be added but they say AutoIt should be presented on the other sites they mention. AutoIt is not on many of them.Why isn't there a mention of AutoIt?
What do you think where it would be positioned if included in survey?
This is one of the downsides of having everything in one big forum. Quite a lack of exposure.
Edited by Manadar, 09 May 2012 - 06:16 PM.
#16
Posted 09 May 2012 - 07:19 PM
WTL begs to differ. MFC does too although I don't like MFC bloat. I'd argue that WTL and/or MFC present better APIs than AutoIt does because AutoIt's GUI relies on too much auto-magic bullshit and lots of buggy shit code to do things.You can make GUIs in almost any language. It just depends how much work you are willing to do. Don't expect something like AutoIt where most of the hard work is done for you (in C++ by the way) and you only have to call some very easy functions.
#17
Posted 09 May 2012 - 07:26 PM
I disagree. I think all platforms should be taken into account. If AutoIt was available for linux tomorrow then by the above logic it would become less popular overnight.Right, very simple. A more useful comparison would be the popularity among windows programmers since AutoIt cannot be used on Unix/Linux. The Google search cannot respect that fact.
You will still have to deal with other language features, like types, that AutoIt covers up. I won't argue with "better" APIs, but I haven't seen anything easier (particularly for people with no programming experience) than AutoIt yet.WTL begs to differ. MFC does too although I don't like MFC bloat. I'd argue that WTL and/or MFC present better APIs than AutoIt does because AutoIt's GUI relies on too much auto-magic bullshit and lots of buggy shit code to do things.
Edited by Mat, 09 May 2012 - 07:30 PM.
I don't know where I'm going, but I'm on my way.
#18
Posted 09 May 2012 - 08:04 PM
- you need packages, headers, and systems, that are tested and comfortable for you and your team.
- you'll use systems that already work and you'll write your own.
- I write a bunch of functions and classes, such as:
int winselect=-1; bool dragging=0; int buttonw=-1, buttonid=-1; class windowclass { public: int x, y, w, h; int windisx, windisy; int buttons; bool nodrag; #define buttonmax 30 SDL_Rect button[buttonmax]; char buttonlable[buttonmax][256]; SDL_Surface *buttonpic[buttonmax]; SDL_Surface *surf, *_surf; windowclass *wdrag; int lbuttonid; int rbuttonid; windowclass() { x=0; y=0; w=0; h=0; windisx=0; windisy=0; int i=0; buttons=0; nodrag=0; for(i=0; i<buttonmax; i++) { button[i].x=0; button[i].y=0; button[i].w=0; button[i].h=0; buttonpic[i]=NULL; } memset(buttonlable, NULL, sizeof(buttonlable)); surf=NULL; _surf=NULL; wdrag=NULL; lbuttonid=-1; rbuttonid=-1; } windowclass::makewindow(int x, int y, int w, int h, int type, int red, int green, int blue, int alpha); windowclass::addbutton(int x, int y, int w, int h); windowclass::addbutton(SDL_Rect rect, char *lable); windowclass::addbutton(SDL_Rect rect); draw(); int drag(); int drag(bool &redraw); clearwin(int x, int y, int w, int h); clearwin(); drawbackup(); }; windowclass::clearwin() { int i=0; sge_Blit(_surf, surf, 0, 0, 0, 0, w, h); } windowclass::clearwin(int x, int y, int w, int h) { sge_Blit(_surf, surf, x, y, x, y, w, h); } windowclass::addbutton(int x, int y, int w, int h) { button[buttons].x=x; button[buttons].y=y; button[buttons].w=w; button[buttons].h=h; if(buttons<buttonmax-1) buttons++; } windowclass::addbutton(SDL_Rect rect) { button[buttons]=rect; if(buttons<buttonmax) buttons++; } windowclass::addbutton(SDL_Rect rect, char *lable) { button[buttons]=rect; strcpy(buttonlable[buttons], lable); if(buttons<buttonmax) buttons++; } int windowclass::drag() { int i=0; if(mbDown[mbLEFT]==1) { if(dragging==0) { if(mouseoverrect(x, y, w, h)) { if(buttons>0) { for(i=0; i<buttons; i++) { if(mouseoverrect(x+button[i].x, y+button[i].y, button[i].w, button[i].h)) { return i; } } } SDL_GetMouseState(&mousex, &mousey); windisx = mousex - x; windisy = mousey - y; dragging=1; wdrag=this; } } } if(wdrag==this && dragging && !nodrag) { SDL_GetMouseState(&mousex, &mousey); x = mousex-windisx; y = mousey-windisy; } if(mbDown[mbLEFT]==0) { dragging=0; wdrag=NULL; } return -1; } int windowclass::drag(bool &redraw) { int i=0; if(mbDown[mbLEFT]==1) { if(dragging==0) { if(mouseoverrect(x, y, w, h)) { if(buttons>0) { for(i=0; i<buttons; i++) { if(mouseoverrect(x+button[i].x, y+button[i].y, button[i].w, button[i].h)) { lbuttonid = i; return i; } } } SDL_GetMouseState(&mousex, &mousey); windisx = mousex - x; windisy = mousey - y; dragging=1; wdrag=this; } } } if(mbDown[mbRIGHT]==1) { if(dragging==0) { if(mouseoverrect(x, y, w, h)) { if(buttons>0) { for(i=0; i<buttons; i++) { if(mouseoverrect(x+button[i].x, y+button[i].y, button[i].w, button[i].h)) { rbuttonid=i; return i; } } } SDL_GetMouseState(&mousex, &mousey); windisx = mousex - x; windisy = mousey - y; dragging=1; wdrag=this; } } } if(wdrag==this && dragging && !nodrag) { SDL_GetMouseState(&mousex, &mousey); x = mousex-windisx; y = mousey-windisy; redraw=1; } if(mbDown[mbLEFT]==0) { dragging=0; wdrag=NULL; } return -1; } windowclass::draw() { if(surf!=NULL) {// if surface of win[i] NOT = NULL then draw win[i].surf sge_Blit(surf, screen, 0, 0, x, y, w, h); } } windowclass::makewindow(int x, int y, int w, int h, int type, int red, int green, int blue, int alpha) { int i=0; if(surf!=NULL) { //SDL_FreeSurface(surf); } surf = createsurface(w, h); switch(type) { // This type variable is used to draw the surface of win case 0: { // case 0 do not fill window surface with any background colors NULL; break;} case 1: {//draws colored lines from top and bottom getting brighter on window surface for(i=0; i<h/2+1; i++) { sge_HLine(surf, 0, surf->w-2, i, int(i* 255/h*2)* red, int(i* 255/h*2)*green, int(i* 255/h*2)*blue); sge_HLine(surf, 0, surf->w-2, h-i, int(i* 255/h*2)* red, int(i* 255/h*2)*green, int(i* 255/h*2)*blue); } break;} case 2: {//draws colored lines from top and bottom getting brighter on window surface for(i=0; i<h/2; i++) { sge_HLine(surf, 1, surf->w, 1+i,127* red, 127*green , 127*blue); sge_HLine(surf, 1, surf->w, h-i-1,127* red, 127*green , 127*blue); } break;} }//end switch(type) sge_Rect(surf, 0, 0, surf->w-1, surf->h-1, 255, 0, 0); SDL_SetAlpha(surf, SDL_SRCALPHA, alpha); windowclass::x=x; windowclass::y=y; windowclass::w=w; windowclass::h=h; _surf = sge_copy_surface(surf); } windowclass::drawbackup() { freesurf(_surf); _surf = sge_copy_surface(surf); }
You can't just jump into making a game like Wow, you'll hurt yourself.
You need a team and a viable plan. You're also going to need funding for living space, electricity, (internet helps), spaghetti, pop tarts, and coffee.
Wow has money, lets just say allot. Programmers are paid to contribute to the project. I liked it better when gamers were developing games that they wanted to play.
- Rock'n Roll Racing
- Lost Vikings
- Blackthorne
- Diablo 1, 2
They got paid too, but it was different then.
(fuck MFC I wrote my own windowclass)
Of course I say that because I am not comfortable using MFC with SDL
Edited by Xandy, 11 May 2012 - 08:44 PM.
#19
Posted 10 May 2012 - 10:21 AM
if you need to ask what C++ is then you are a long way from the point of having to worry about writing a game.
Hit the books, study hard and someday you too will be able to write "Hello World".
- shanet likes this
#20
Posted 18 May 2012 - 01:35 AM
Lol I can Write basic functions, I am not that new, I was just wondering....For the OP
if you need to ask what C++ is then you are a long way from the point of having to worry about writing a game.
Hit the books, study hard and someday you too will be able to write "Hello World".
- Hunter Console - A Small Gadget
- HunterPad - Basic Notepad aimed at Programmers
- Betters UP! - Betting Game
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users




