line wars!
- joelyboy94
- Posts: 67
- Joined: October 11th, 2012, 7:34 pm
line wars!
Hey guys,
just finished lesson 19 and thought I'd show you guys my work, it's a simple 2 player game where the aim is to not go outside the box, not hit your line, or the other player's line.
player 1 controls - up, down, left right.
player 2 controls - w,a,s,d.
when someone wins, their colour is displayed in the corner
IMPORTANT - you must right click on chili framework and go to properties - v110 if you are using visual studio 2012 and v100 if you are using 2010.
just finished lesson 19 and thought I'd show you guys my work, it's a simple 2 player game where the aim is to not go outside the box, not hit your line, or the other player's line.
player 1 controls - up, down, left right.
player 2 controls - w,a,s,d.
when someone wins, their colour is displayed in the corner
IMPORTANT - you must right click on chili framework and go to properties - v110 if you are using visual studio 2012 and v100 if you are using 2010.
- Attachments
-
- tron_mp_download.zip
- (42.57 KiB) Downloaded 280 times
Last edited by joelyboy94 on December 17th, 2012, 9:34 pm, edited 3 times in total.
Re: line wars!
Have you changed your VC++ directory for your include files in the project?
Because it is not linking to the standard directory, and I get a error if I try to compile it.(Have to change the include diretories).
Because it is not linking to the standard directory, and I get a error if I try to compile it.(Have to change the include diretories).
Last edited by poschi on December 8th, 2012, 5:22 pm, edited 1 time in total.
- joelyboy94
- Posts: 67
- Joined: October 11th, 2012, 7:34 pm
Re: line wars!
umm don't think so, is it not working?
Re: line wars!
By the way, is there a reason for using __ as variables?
Just asking because you should not do that. This kind of variables are actually reserved.
See also:
http://stackoverflow.com/questions/2287 ... identifier
First answer.
Anyway, good job, works like a charm
Just asking because you should not do that. This kind of variables are actually reserved.
See also:
http://stackoverflow.com/questions/2287 ... identifier
First answer.
Anyway, good job, works like a charm
- joelyboy94
- Posts: 67
- Joined: October 11th, 2012, 7:34 pm
Re: line wars!
I used the underscores to help me distinguish the parameter variables from the actual variables, but ok, didn't realise that, thanks for pointing it out
Also, didn't realise instead of using an overly convoluted if statement in the end of the boundary check function I could use the predefined min and max functions
and thanks, means alot!
Also, didn't realise instead of using an overly convoluted if statement in the end of the boundary check function I could use the predefined min and max functions
and thanks, means alot!
Re: line wars!
it doesn't work. it doesn't compile.
Poschi, how did you fix the problem?
Poschi, how did you fix the problem?
Re: line wars!
Cool game, it's like tron. Or actually it IS tron : -P
The problem should be fixed if you change the toolset from the project settings v110 -> v100. That's the thing to look at first if the program doesn't link properly.
The problem should be fixed if you change the toolset from the project settings v110 -> v100. That's the thing to look at first if the program doesn't link properly.
ʕ •ᴥ•ʔ
Re: line wars!
Nice work, I'm always glad to see people sharing their work. Good code organization and style (except for the underscore thing). I like that you use an Enum (they don't get enough love IMO).
HOWEVER, minus 1 billion chili points because you DIDN'T CLEAN YOUR SOLUTION!
It is huge and it will kill all of our collective bandwidthses. Unacceptable. Redo.
HOWEVER, minus 1 billion chili points because you DIDN'T CLEAN YOUR SOLUTION!
It is huge and it will kill all of our collective bandwidthses. Unacceptable. Redo.
Chili
- joelyboy94
- Posts: 67
- Joined: October 11th, 2012, 7:34 pm
Re: line wars!
It only vaguely resembles tron
and thanks Chili; sorry about the cleaning, i've done it now
and thanks Chili; sorry about the cleaning, i've done it now
Re: line wars!
Still doesn't compile for me.
Computer too slow? Consider running a VM on your toaster.