Please Look At My Games I Really Want Feedback

I am a beginning C++ Coder and have worked on very basic projects.
I have been teaching myself with the internet for about 3 months. None of which I have published.
When my uncle(doesn't have any knowledge of code) had come over and wasn't impressed at all. I was pretty disappointed. So I set out to impress him.
So I decided to make a game and it devolved into 2.
I've showed my games to my family, but I want a larger opinion on them.
Below is a link to a weebly website with download links for my games. Any opinions are welcomed, but keep in mind I am a beginner and this is in no way to supposed to be better then a game like GTA V.


www.dicegame2.weebly.com

-DICE21
Congrats on making a game! That said...

You posted this on a C++ forum, but have linked us two binaries, the review of which does not require C++ coding expertise.

Programmers tend to treat binaries with some suspicion, mostly because there's no simple way to be sure what they do ahead of time without decompiling them, and reviewing decompiled code is, putting it mildly, not fun.

Additionally, that you've provided us with binaries for Windows alone makes it harder for anyone not on Windows to give any meaningful review*. It's possible that you rely on cross-platform libraries such that your code could compile on other platforms, but we don't know that. Even if you do rely on Windows-specific libraries or functionality, some people might still be able to offer input just based on the gameplay code.

If you want our opinion, it's probably in your best interest to share the source code with us, even if you're not specifically looking for a code review. At the very least, it would help with peace of mind that you're not distributing anything malicious. Otherwise, this thread may be better suited to the Lounge (which, you can move it there by clicking the Edit Topic button at the top).

Happy coding!

-Albatross

*Ignoring the fact that WINE and virtualization exist for a moment here.
Last edited on
Okay! Thanks for the feedback! The Code is below.



1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
#include <iostream>
#include <string>
#include <ctime>
#include <cstdlib>
using namespace std;
int main(){
	string aa;
	string cc;
	string dd;
	int a;
	int b;
	int c=100;
	int d;
	int z;
	for(string bb="yes";bb=="yes";){
	cout<<"Welcome to DICE INFINITE!\n";
	cout<<"Same Old DICE...\n";
	cout<<"BUT It's Infinite(Obviously)!!\n";
	cout<<"This is a Game of Chance!\n";
	cout<<"You Start With 100 Creidts!\n";
	cout<<"Choose a Number 1-6!\n";
	cout<<"If You Guess Correctly You Gain 40 Credits!\n";
	cout<<"If You Guess Incorrectly You Lose 10 Credits!\n";
	cout<<"Type 99 to End Game At Any Time!\n";
	cout<<"The Cheat Code Is Your Choice!!\n";
	cout<<"Please Enter Your Name!\n";
	cout<<"Name:";
	cin>>aa;
	cout<<"Cheat Code(Numbers Only): ";
	cin>>z;
	for(int cred=100;cred>0;){
	srand(time(0));
	b=1+(rand()%6);
	cout<<"\n";
	cout<<aa;
	cout<<" Chooses ";
	cin>>d;
	if(d==99){
	cred=0;
	}
	else{
	if(d==z){
	cout<<"Cheat Code Accepted!\n";
	cout<<"50 Credits Added!\n";
	cred=cred+50;
}
else{

if(d--==b){
		cout<"The Answer is: ";
		cout<<b;
		cout<<"\n";
		cout<<"You Win!\n\n";
		 cred=cred+40;
	}
	else{
		cout<<"The Correct Answer is:";
		cout<<b;
		cout<<"\n";
		cout<<"You Lost!\n";
		cout<<"Try Again!\n";
		 cred=cred-10;
	}
	}
}
	cout<<"You Have ";
	cout<<cred;
	cout<<" Credits\n";
if(cred<1){
cout<<"Sorry You Ran Out of Credits!\n";
cout<<"Play Again?\n";
cin>>bb;
}
}
}
system("pause");	
return 0;
}





1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
#include <iostream>
#include <string>
#include <ctime>
#include <cstdlib>
using namespace std;
int main(){
	string name;
	int cheat;
	string chi;
	for(string z="yes";z=="yes";){
	cout<<"Do You Know the Cheat Code?                                               V 0.3\n";
	cin>>chi;
	if(chi=="yes"){
	   cout<<"What is the Cheat Code?\n";
	   cout<<"Code:";
	   cin>>cheat;
		  if(cheat==5272){
	cout<<"Welcome to DICE!\n";
	cout<<"This is a Game of Chance!\n";
	cout<<"You Start With 100 Creidts!\n";
	cout<<"Choose a Number 1-6!\n";
	cout<<"If You Guess Correctly You Gain 40 Credits!\n";
	cout<<"If You Guess Incorrectly You Lose 10 Credits!\n";
	cout<<"If You Achevie 1000 Credits You WIN!\n";
	cout<<"The Cheat Code Activates at 200 Credits!\n";
	cout<<"Please Enter Your Name!\n";
	cout<<"Name:";
	cin>>name; 
	for(int cred=100;cred<999&&cred>0;){
		int creds=cred;
	cout<<"\n";
	srand(time(0));
	int b=1+(rand()%6);
	int a;
	cout<<name;
	cout<<" Chooses ";
	cin>>a;
if(a==5272&&cred>199){
	cout<<"Cheat Code Accepted!\n";
	cout<<"50 Credits Added!\n";
	cred=cred+50;
}
else{
if(a--==b){
		cout<<"The Answer is: ";
		cout<<b;
		cout<<"\n";
		cout<<"You Win!\n";
		 cred=cred+40;
	}
	else{
		cout<<"The Correct Answer is:";
		cout<<b;
		cout<<"\n";
		cout<<"You Lost!\n";
		cout<<"Try Again!\n";
		 cred=cred-10;
	}
}
	cout<<"You Have ";
	cout<<cred;
	cout<<" Credits\n";
}
if(cred>299)
cout<<"The Cheat Code is 5272!\n";
if(cred>999){
	cout<<"Congratulations!\n";
	cout<<"You WON!\n";
	cout<<"Play Again?";
	cin>>z;
}
if(cred<1){
cout<<"Sorry You Ran Out of Credits!\n";
cout<<"Play Again?\n";
cin>>z;
}
}
}
if(chi!="yes"){
cout<<"Welcome to DICE!\n";
	cout<<"This is a Game of Chance!\n";
	cout<<"You Start With 100 Creidts!\n";
	cout<<"Choose a Number 1-6!\n";
	cout<<"If You Guess Correctly You Gain 40 Credits!\n";
	cout<<"If You Guess Incorrectly You Lose 10 Credits!\n";
	cout<<"If You Achevie 1000 Credits You WIN!\n";
	cout<<"There is No Cheat Code on This Mode!\n";
	cout<<"Please Enter Your Name!\n";
	cout<<"Name:";
	cin>>name;
	for(int cred=100;cred<999&&cred>0;){
		int creds=cred;
	cout<<"\n";
	srand(time(0));
	int b=1+(rand()%6);
	int a;
	cout<<name;
	cout<<" Chooses ";
	cin>>a;
if(a--==b){
		cout<<"The Answer is: ";
		cout<<b;
		cout<<"\n";
		cout<<"You Win!\n";
		 cred=cred+40;
	}
	else{
		cout<<"The Correct Answer is:";
		cout<<b;
		cout<<"\n";
		cout<<"You Lost!\n";
		cout<<"Try Again!\n";
		 cred=cred-10;
	}
	cout<<"You Have ";
	cout<<cred;
	cout<<" Credits\n";
}
if(cred>299){
	cout<<"The Cheat Code is 5272!";
}
if(cred>999){
	cout<<"Congratulations!\n";
	cout<<"You WON!\n";
	cout<<"Play Again?";
	cin>>z;
}
if(cred<1){
cout<<"Sorry You Ran Out of Credits!\n";
cout<<"Play Again?\n";
cin>>z;
}	
}	
if(cheat!=5272){	
cout<<"Welcome to DICE!\n";
	cout<<"This is a Game of Chance!\n";
	cout<<"You Start With 100 Creidts!\n";
	cout<<"Choose a Number 1-6!\n";
	cout<<"If You Guess Correctly You Gain 40 Credits!\n";
	cout<<"If You Guess Incorrectly You Lose 10 Credits!\n";
	cout<<"If You Achevie 1000 Credits You WIN!\n";
	cout<<"There is No Cheat Code in This Mode!\n";
	cout<<"Please Enter Your Name!\n";
	cout<<"Name:";
	cin>>name;
	for(int cred=100;cred<999&&cred>0;){
		int creds=cred;
	cout<<"\n";
	srand(time(0));
	int b=1+(rand()%6);
	int a;
	cout<<name;
	cout<<" Chooses ";
	cin>>a;
if(a--==b){
		cout<<"The Answer is: ";
		cout<<b;
		cout<<"\n";
		cout<<"You Win!\n";
		 cred=cred+40;
	}
	else{
		cout<<"The Correct Answer is:";
		cout<<b;
		cout<<"\n";
		cout<<"You Lost!\n";
		cout<<"Try Again!\n";
		 cred=cred-10;
	}
	cout<<"You Have ";
	cout<<cred;
	cout<<" Credits\n";
}
if(cred>299){
	cout<<"The Cheat Code is 5272!\n";
}
if(cred>999){
	cout<<"Congratulations!\n";
	cout<<"You WON!\n";
	cout<<"Play Again?";
	cin>>z;
}
if(cred<1){
cout<<"Sorry You Ran Out of Credits!\n";
cout<<"Play Again?\n";
cin>>z;
}
}
}
cout<<"Good Bye!\n";
system("pause");
return 0;
}



I am currently working on a VS mode for 2 players
Last edited on
First snippet line 32,94, second snippet line 149:
Do not call srand() within a loop or a random number function. srand() sets the RNG to a particular starting point. Calling srand() repeatedly can cause the RNG to return the same random numbers. srand() should be called ONCE at the beginning of main().
http://www.cplusplus.com/reference/cstdlib/srand/

Second snippet lines 18-28, 80-90, 135-145: You have exactly the same code in three places. You should move the repeated code to a function.

First snippet lines 7-14: Your variable names are meaningless. A well named variable should convey what it is used for.

Thanks for the code feedback but im looking for feedback of the the game. I dont have the problem described by "Do not call srand() within a loop or a random number function. srand() sets the RNG to a particular starting point. Calling srand() repeatedly can cause the RNG to return the same random numbers." It is random each time. So can you please review the result of the code instead of the code itself.

Thank You for the feedback though.
Last edited on
This is a programming platform though. Besides, I don't think people enjoy playing text-based games anymore.

Not to break your dreams but, game industry is pretty competitive so if you want people to play your games or be impressed by them you'll need to forget what satisfaction is for a long long time and keep learning.
Last edited on
closed account (48T7M4Gy)
I think you need to address your question by conducting a survey with a series of ratings against a set of criteria based on what targets you have in mind for the game. Let people give a rating against your targets.

Obviously it would be more appropriate that your programming was surveyed because you can improve your work. (You have decided to concentrate on the product rather than the nuts and bolts and that's OK.)

In the absence of your (short) survey questionnaire I think my feedback to you would be best described as something like your uncles, but there is no reason a text based game can't be a bit of fun or even impressive.

I look forward to the survey. :)
Topic archived. No new replies allowed.