New to game programming

Whether you're a newbie or an experienced programmer, any questions, help, or just talk of any language will be welcomed here.

Moderator: Coders of Rage

User avatar
MrDeathNote
ES Beta Backer
ES Beta Backer
Posts: 594
Joined: Sun Oct 11, 2009 9:57 am
Current Project: cocos2d-x project
Favorite Gaming Platforms: SNES, Sega Megadrive, XBox 360
Programming Language of Choice: C/++
Location: Belfast, Ireland
Contact:

Re: New to game programming

Post by MrDeathNote »

Avishaiozeri wrote:The links you'v sent are very helpful! thanks. But i have one problem. I'm using c++ now with the visual c++ express, and although its good, i'v sent one of my programs to my friend, and he couldn't run it! i'v read on the internet that for running programs that were developed in visual c++ you need to download some software, that i'v noticed that most of the games aoutomatclly install. It may say that companys use it, but its really annoying! does dev ++ has the same problem? because if it doesn't, i think i'll start using it. wich of these are better?
When you say you sent it too a friend, did you send the whole project or just the .exe file?What kind of a program was it, was it plain c++ or did it use SDL? Did he compile it, if so what error did he get? He may need to install the c++ runtime to run the program, but with a few more details i could give you a better answer. Also, IDE's are a matter of choice, if your comfortable using Visual Studio then use that. I personnaly prefer VS but it's really up to you.
http://www.youtube.com/user/MrDeathNote1988

Image
Image

"C makes it easy to shoot yourself in the foot. C++ makes it
harder, but when you do, it blows away your whole leg." - Bjarne Stroustrup
Avishaiozeri
Chaos Rift Cool Newbie
Chaos Rift Cool Newbie
Posts: 85
Joined: Wed Mar 17, 2010 4:32 pm

Re: New to game programming

Post by Avishaiozeri »

VS is good. But i'v sent the .EXE file, that the compiler produced, to my friend, and it didn't work :x , i didn't use sdl,just C++ codes , my practice as a beginner. you now, like simple Guess my number games just for practice... My friend said the error said :
"This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem." :nono:
i think you need to install some software from microsoft, because i'v noticed that some games i'v installed, automaticlly installed that program... Does it worth the effort? Couldn't i just use some other IDE? :|
User avatar
hurstshifter
ES Beta Backer
ES Beta Backer
Posts: 713
Joined: Mon Jun 08, 2009 8:33 pm
Favorite Gaming Platforms: SNES
Programming Language of Choice: C/++
Location: Boston, MA
Contact:

Re: New to game programming

Post by hurstshifter »

Avishaiozeri wrote:VS is good. But i'v sent the .EXE file, that the compiler produced, to my friend, and it didn't work :x , i didn't use sdl,just C++ codes , my practice as a beginner. you now, like simple Guess my number games just for practice... My friend said the error said :
"This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem." :nono:
i think you need to install some software from microsoft, because i'v noticed that some games i'v installed, automaticlly installed that program... Does it worth the effort? Couldn't i just use some other IDE? :|
Was this a Debug or Release build? I believe if you built it in Debug state it includes a lot of debugging configuration within the .exe and you need visual studio or at least MS C++ Redistibutable for it to run.
"Time is an illusion. Lunchtime, doubly so."
http://www.thenerdnight.com
Avishaiozeri
Chaos Rift Cool Newbie
Chaos Rift Cool Newbie
Posts: 85
Joined: Wed Mar 17, 2010 4:32 pm

Re: New to game programming

Post by Avishaiozeri »

Ahhh, now i understand! thanks! i didn't even know theres a diffrence between debug compile and regular build...

edited: i'v tried building it, and there were an error!
"Project : error PRJ0003 : Error spawning 'cmd.exe'"
What does it mean??
User avatar
MrDeathNote
ES Beta Backer
ES Beta Backer
Posts: 594
Joined: Sun Oct 11, 2009 9:57 am
Current Project: cocos2d-x project
Favorite Gaming Platforms: SNES, Sega Megadrive, XBox 360
Programming Language of Choice: C/++
Location: Belfast, Ireland
Contact:

Re: New to game programming

Post by MrDeathNote »

Avishaiozeri wrote:Ahhh, now i understand! thanks! i didn't even know theres a diffrence between debug compile and regular build...

edited: i'v tried building it, and there were an error!
"Project : error PRJ0003 : Error spawning 'cmd.exe'"
What does it mean??
I found a good post after about 30 seconds googling lol, http://social.msdn.microsoft.com/Forums ... dd10e1d745, see if this helps.
http://www.youtube.com/user/MrDeathNote1988

Image
Image

"C makes it easy to shoot yourself in the foot. C++ makes it
harder, but when you do, it blows away your whole leg." - Bjarne Stroustrup
User avatar
mv2112
Chaos Rift Junior
Chaos Rift Junior
Posts: 240
Joined: Sat Feb 20, 2010 4:15 am
Current Project: Java Tower Defence Game
Favorite Gaming Platforms: N64/Xbox 360/PC/GameCube
Programming Language of Choice: C/++, Java
Location: /usr/home/mv2112
Contact:

Re: New to game programming

Post by mv2112 »

hurstshifter wrote:
Avishaiozeri wrote:VS is good. But i'v sent the .EXE file, that the compiler produced, to my friend, and it didn't work :x , i didn't use sdl,just C++ codes , my practice as a beginner. you now, like simple Guess my number games just for practice... My friend said the error said :
"This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem." :nono:
i think you need to install some software from microsoft, because i'v noticed that some games i'v installed, automaticlly installed that program... Does it worth the effort? Couldn't i just use some other IDE? :|
Was this a Debug or Release build? I believe if you built it in Debug state it includes a lot of debugging configuration within the .exe and you need visual studio or at least MS C++ Redistibutable for it to run.
LOL :oops: ,
i better rebuild my project in Release mode lol.
Avishaiozeri
Chaos Rift Cool Newbie
Chaos Rift Cool Newbie
Posts: 85
Joined: Wed Mar 17, 2010 4:32 pm

Re: New to game programming

Post by Avishaiozeri »

MrDeathNote wrote:
Avishaiozeri wrote:Ahhh, now i understand! thanks! i didn't even know theres a diffrence between debug compile and regular build...

edited: i'v tried building it, and there were an error!
"Project : error PRJ0003 : Error spawning 'cmd.exe'"
What does it mean??
I found a good post after about 30 seconds googling lol, http://social.msdn.microsoft.com/Forums ... dd10e1d745, see if this helps.
Thanks, i think i got it. i'll try what it says, hope it'll work!
mv2112 wrote:
hurstshifter wrote:
Avishaiozeri wrote:VS is good. But i'v sent the .EXE file, that the compiler produced, to my friend, and it didn't work :x , i didn't use sdl,just C++ codes , my practice as a beginner. you now, like simple Guess my number games just for practice... My friend said the error said :
"This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem." :nono:
i think you need to install some software from microsoft, because i'v noticed that some games i'v installed, automaticlly installed that program... Does it worth the effort? Couldn't i just use some other IDE? :|
Was this a Debug or Release build? I believe if you built it in Debug state it includes a lot of debugging configuration within the .exe and you need visual studio or at least MS C++ Redistibutable for it to run.
LOL :oops: ,
i better rebuild my project in Release mode lol.
lol :lol:


edited: It worked! build with no errors! but when i do 'compile' i cant find the .EXE file preduced... Normally its in the debug folder, because i debug it. but now when i'v built it, i cant find it! someone knows where can it be? (in visual c++ 2008 express).
edited again: I found the problem, i did it wrong. now i'v built it for release, and found it! now i'll check if it'll solve the problem. (that i cant run it in other computers)
Avishaiozeri
Chaos Rift Cool Newbie
Chaos Rift Cool Newbie
Posts: 85
Joined: Wed Mar 17, 2010 4:32 pm

Re: New to game programming

Post by Avishaiozeri »

(Sorry for the double post)
It worked :) ! the program runs okay on my friends computer! thank you all for your help! :mrgreen:
Avishaiozeri
Chaos Rift Cool Newbie
Chaos Rift Cool Newbie
Posts: 85
Joined: Wed Mar 17, 2010 4:32 pm

Re: New to game programming

Post by Avishaiozeri »

MrDeathNote , Wow man! i saw the game you made - on youtube! b-e-a-utiful!
Last edited by Avishaiozeri on Wed Mar 24, 2010 8:17 am, edited 1 time in total.
User avatar
MrDeathNote
ES Beta Backer
ES Beta Backer
Posts: 594
Joined: Sun Oct 11, 2009 9:57 am
Current Project: cocos2d-x project
Favorite Gaming Platforms: SNES, Sega Megadrive, XBox 360
Programming Language of Choice: C/++
Location: Belfast, Ireland
Contact:

Re: New to game programming

Post by MrDeathNote »

Avishaiozeri wrote:MrDeathNote , Wow man! i saw the game you made - on youtube! b-e-a-utiful!!!
Lol thanks man, i could have done alot more but i only had 10 weeks, and just in my spare time i managed to write the first build of my map editor, the game and an animation previewer so i was pretty happy :) .
http://www.youtube.com/user/MrDeathNote1988

Image
Image

"C makes it easy to shoot yourself in the foot. C++ makes it
harder, but when you do, it blows away your whole leg." - Bjarne Stroustrup
Avishaiozeri
Chaos Rift Cool Newbie
Chaos Rift Cool Newbie
Posts: 85
Joined: Wed Mar 17, 2010 4:32 pm

Re: New to game programming

Post by Avishaiozeri »

MrDeathNote wrote:
Avishaiozeri wrote:MrDeathNote , Wow man! i saw the game you made - on youtube! b-e-a-utiful!!!
Lol thanks man, i could have done alot more but i only had 10 weeks, and just in my spare time i managed to write the first build of my map editor, the game and an animation previewer so i was pretty happy :) .
Nice, i saw your editor too, he's good!
And how much code you wrote for this game! more then a 1000 lines! its a long way for me to go until i could do such things. good luck on your other projects! and thanks for all the help!
User avatar
MrDeathNote
ES Beta Backer
ES Beta Backer
Posts: 594
Joined: Sun Oct 11, 2009 9:57 am
Current Project: cocos2d-x project
Favorite Gaming Platforms: SNES, Sega Megadrive, XBox 360
Programming Language of Choice: C/++
Location: Belfast, Ireland
Contact:

Re: New to game programming

Post by MrDeathNote »

Avishaiozeri wrote:
MrDeathNote wrote:
Avishaiozeri wrote:MrDeathNote , Wow man! i saw the game you made - on youtube! b-e-a-utiful!!!
Lol thanks man, i could have done alot more but i only had 10 weeks, and just in my spare time i managed to write the first build of my map editor, the game and an animation previewer so i was pretty happy :) .
Nice, i saw your editor too, he's good!
And how much code you wrote for this game! more then a 1000 lines! its a long way for me to go until i could do such things. good luck on your other projects! and thanks for all the help!
No problem, and together with the editor it was more like 4000 - 5000 lines of code lol.
http://www.youtube.com/user/MrDeathNote1988

Image
Image

"C makes it easy to shoot yourself in the foot. C++ makes it
harder, but when you do, it blows away your whole leg." - Bjarne Stroustrup
Avishaiozeri
Chaos Rift Cool Newbie
Chaos Rift Cool Newbie
Posts: 85
Joined: Wed Mar 17, 2010 4:32 pm

Re: New to game programming

Post by Avishaiozeri »

Wow, thats alot of lines! Does all 2d games have so many lines?
User avatar
MrDeathNote
ES Beta Backer
ES Beta Backer
Posts: 594
Joined: Sun Oct 11, 2009 9:57 am
Current Project: cocos2d-x project
Favorite Gaming Platforms: SNES, Sega Megadrive, XBox 360
Programming Language of Choice: C/++
Location: Belfast, Ireland
Contact:

Re: New to game programming

Post by MrDeathNote »

Avishaiozeri wrote:Wow, thats alot of lines! Does all 2d games have so many lines?
It really depends on what your trying to do, you could make pong in a few hundred lines(or less). I made the game very easy to extend which adds a lot of code that could be removed but i wanted to keep everything as generic as possible. Plus i could have hard coded all the maps instead of writing the editor which would have cut even more code but thats not how i wanted to do it.
http://www.youtube.com/user/MrDeathNote1988

Image
Image

"C makes it easy to shoot yourself in the foot. C++ makes it
harder, but when you do, it blows away your whole leg." - Bjarne Stroustrup
Avishaiozeri
Chaos Rift Cool Newbie
Chaos Rift Cool Newbie
Posts: 85
Joined: Wed Mar 17, 2010 4:32 pm

Re: New to game programming

Post by Avishaiozeri »

MrDeathNote wrote:
Avishaiozeri wrote:Wow, thats alot of lines! Does all 2d games have so many lines?
It really depends on what your trying to do, you could make pong in a few hundred lines(or less). I made the game very easy to extend which adds a lot of code that could be removed but i wanted to keep everything as generic as possible. Plus i could have hard coded all the maps instead of writing the editor which would have cut even more code but thats not how i wanted to do it.
So, Its really smart to do so, because it lets you expand your game in the future. I guess i need to stop asking questions and start actually learning the languages.. :) Thanks again for the help. Now, Alot of time of hard working and learning, building Tons of useless programs for practice! Here i come!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Post Reply