Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

2D All the way! / 2D Horizontal Shooter....(need help on bullet and border)

Author
Message
Dexter
20
Years of Service
User Offline
Joined: 4th Nov 2005
Location: Ohio
Posted: 4th Nov 2005 19:32
k how do i add bullets and a border for the Y axis so the sprite doesnt go off screen...

thank you

Mr. Noob

Who Dey Bengals
Zergei
21
Years of Service
User Offline
Joined: 9th Feb 2005
Location: Everywhere
Posted: 5th Nov 2005 03:52 Edited at: 5th Nov 2005 03:53
You'll have to be more specific with the bullet thing, unless its a image of a bullet you want on screen...

...about the Y axis, you could just use the LINE command or a sprite if needed. However, if you want to add this line so that it collides with the sprite and unables it from going off screen, you'd better do it throught code, such as...



...that is just a quick example of how. The -10 on the IF condition is because the image is 10 pixels width, so as to have it stop at the very end of the screen and be able to see it, if not it will stop once its upper-left corner reaches the border of the screen, and doing so will put the sprite off screen. Hope it helped someway....
Dexter
20
Years of Service
User Offline
Joined: 4th Nov 2005
Location: Ohio
Posted: 6th Nov 2005 01:23
OK the border is working fine but it moved my sprite on the x axis... do you know how i can get it back over to the right..?

also the bullet will be a image of a spear.. i attaxhed a pic of the guy... help me with this please.. got to learn... lol. thanx.

Who Dey Bengals

Login to post a reply

Server time is: 2026-07-10 12:34:41
Your offset time is: 2026-07-10 12:34:41