I've read the/a pointer tutorial when i was 12, when i was 13, and just recently.
All three times, I have not figured out a use, or what it does actually
My question is, should I even...
Type: Posts; User: s3abass
I've read the/a pointer tutorial when i was 12, when i was 13, and just recently.
All three times, I have not figured out a use, or what it does actually
My question is, should I even...
I was thinking of something .... like..
(note: not actual variables, just a bunch of bs)
if (ghost.x < pacman.x) {
direction = 2;//left
}
if (ghost.x == pacman.x) {
QBasic was the first language I learned.. and it was so simple, It made me puke -- even without knowing what other languages are like
I haven't done C++ in like... 1 or 2+ years...
and I redownload some compiler and decide to start agian.
and i look at some tutorial to refresh my memory...
using namespace std;
Yes, i us like 100's of while(1) loops in my "games"
do it through while() { loops
and if you want the while loop to stop, just use the function break;
Also, you're forgetting all the semi-colons at the end of certain functions/declarations.
Because, the collision function checks if you are on the exact same place at the same time
so if you were standing under one, and he moves down at the same time you move up, then you will be...
I used dec_w(); for collision detection
//Declare where the walls are
void dec_w( int nvalue, int xvalue, int yvalue ) {
walls[nvalue].wx = xvalue;
walls[nvalue].wy = yvalue;
...
This is my first game!... actually, I've done plenty of games before... but most of them were either AS-flash or, really crappy projects that weren't succesfful
So, this game here, to me is an...
Ok, sleep(); is under what header?
I need it to pause, because, if i just declare them all at once it completely crashes.
And plus, this is the easiest way for me :D
edit:
this is what im taliking about
the function is
hello, im making pacman in ascii console
and, i have to load levels; and for collision detecting, i have each "X" [a wall sector] have a spot in walls.wx[3] and walls.wy[3];
Well, when I make...