Page 1 of 1

Game Maker

Posted: Fri Jun 26, 2009 2:25 pm
by Jesusfreak
So far I've been able to make enemies spawn and fire bullets in the right direction, but I have a problem I can't figure out how to fix:

The enemies only go horizontally. They're supposed to go sideways of whatever direction they're facing, so if one is facing left or right, it should go up, but it doesn't. Also, I notice that ones facing down tend to fire more than others.

Got any ideas? I'll add screenies so you can see what I'm doing:

Re: Game Maker

Posted: Fri Jun 26, 2009 3:07 pm
by hallsofvallhalla
i cant help out here but nice work sticking with this

Re: Game Maker

Posted: Fri Jun 26, 2009 3:47 pm
by Jesusfreak
Oh, yah, that reminds me...

Can someone post the link to the tutorials? I remember the tutorials being linked once but I can't find it again...
It might be in the tutorials... chances are, I put something in the wrong order or used the wrong action.

Re: Game Maker

Posted: Sat Jun 27, 2009 1:55 am
by Warriorccc0
You could have it check for what sprite the enemy currently has, then shoot the right direction.

Re: Game Maker

Posted: Sat Jun 27, 2009 12:05 pm
by Jesusfreak
That's what I did. Apparently, it didn't seem to do it quite right.

What did I do wrong? (I posted screenies so you could see)

Re: Game Maker

Posted: Sat Jun 27, 2009 4:59 pm
by Warriorccc0
Well, whats with the brackets in it?

Re: Game Maker

Posted: Sat Jun 27, 2009 6:17 pm
by Jesusfreak
It gives an error message when you use variables without brackets, doesn't it? Or at least it did before I added the brackets...

Re: Game Maker

Posted: Sat Jun 27, 2009 11:01 pm
by Warriorccc0
GM never uses brackets except if its for something like background[0], alarm[1], view_xview[2], etc.

Re: Game Maker

Posted: Sun Jun 28, 2009 1:12 pm
by Jesusfreak
Ok, I removed the brackets, but the ones that are supposed to travel vertically still go horizontally, and for some reason, more of them point down than left (and I've yet to see a right or up at all).
Maybe I arranged the "Chance" variables the wrong way?