|
-
Aug 15th, 2008, 10:35 AM
#1
Thread Starter
Frenzied Member
Walking in 2D game
Hi,
I want to see if my theory is a good one or if there is an easier way to do this. I want to create a 2D scrolling game similar to mario style where you walk, jump, etc. And I want the land that you walk on to change height such as slopes, etc. And also have multi-platforms on one screen where you can jump up on the other and walk.
Here is how I was thinking of doing it.
First I was going to drawn a very wide background full of graphics for the level. Then I was going to create an array for each platform having the X/Y coordinates. Each platform is a different array. For example, if there is one platform to walk on all the way along the bottom, thats one array. then any others above are seperate ones.
When I move my character, it just checks the coordinates of when moving forward and change the height of the character according to the coordinates. This keeps the character level with however the platform changes if it slopes, etc.
Is this a good way of moving the character when walking around?
Thanks!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|