|
||
|
GP Mailing List
ATXGPSIG List
|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: 2D Movement
Well, you would need 4 if statements,... for left, right, up, down.
Assuming, the game allowed it. But a side scroller would be fine for that
:)
Ben Humphrey
Game Programmer
WebHost of www.GameTutorials.com
benh@humongous.com
benjina@mindspring.com
----- Original Message -----
From: Robert S Whitlock <roberts.j.whitlock@juno.com>
To: <gameprogrammer@gameprogrammer.com>
Sent: Wednesday, July 12, 2000 4:21 AM
Subject: Re: 2D Movement
> > if(They hit the left arrow key)
> > {
> > draw bitmap("WalkingLeft.bmp", CurrentPosition.x,
> > CurrentPosition.y);
> > }
> > else if (They hit the RIGHT arrow key)
> > {
> > draw bitmap("WalkingRight.bmp", CurrentPosition.x,
> > CurrentPosition.y);
> > }
> > etc...
>
> or
>
> drawbitmap((they hit the left)? "WalkingLeft.bmp": "WalkingRight.bmp",
> curpos.x, curpos.y);
> =================================================================
> The GameProgrammer.Com mailing list is for the open discussion
> of any topic related to the art, science, and business of
> programming games. This list is especially tolerant of beginners.
> We were all beginners once
>
> To SUBSCRIBE or UNSUBSCRIBE please visit:
> http://gameprogrammer.com/mailinglist.html
=================================================================
The GameProgrammer.Com mailing list is for the open discussion
of any topic related to the art, science, and business of
programming games. This list is especially tolerant of beginners.
We were all beginners once
To SUBSCRIBE or UNSUBSCRIBE please visit:
http://gameprogrammer.com/mailinglist.html
|
|