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.

DarkBASIC Professional Discussion / Can't figure out how to code a sidescroller!

Author
Message
wattywatts
17
Years of Service
User Offline
Joined: 25th May 2009
Location: Michigan
Posted: 21st Nov 2011 03:34


Yeah, it should be so simple, but it's something I've never attempted to do in dark basic. Ideally what I want to do is have the characters in 2D, (as they were created out of clay for a distinctive look), and put them in a 3D world. I also need a bloom effect, that's pretty important.

So not only have I never attempted sidescroller mechanics, I've never tried to mesh 2D and 3D.
The main thing I'm not getting is, how do I adjust for the height of the ground the character is standing on?
Also, maybe even more important, does anyone know of an engine that will let me do this stuff without coding, and just concentrating on the art?
baxslash
Valued Member
Bronze Codemaster
19
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 22nd Nov 2011 14:33 Edited at: 22nd Nov 2011 14:36
I did this using Sparky's collision and plains. Here's a video:


I'd be happy to share some code with you if you get stuck. I'd suggest you think of it as a 3D game where you can only move in 2 dimensions. It'll make it a lot easier to code!

I was using Sphereslide collision from sparky's which meant I could produce my levels whatever shape I liked and I only had to make sure my guy reacted properly to the data returned.

EDIT:
Quote: "Also, maybe even more important, does anyone know of an engine that will let me do this stuff without coding, and just concentrating on the art?"

Just saw this... no I don't. Sorry. However there are numerous sparky's examples that could easily be edited for this application.

Daniel wright 2311
User Banned
Posted: 22nd Nov 2011 18:23
Or go to the 2d fourm to learn how,there is no magic 2d game kit to create nice 2d games to build your own games,Unless you use my doddol game and this does not let you build stand alone games.

my signature keeps being erased by a mod So this is my new signature.
wattywatts
17
Years of Service
User Offline
Joined: 25th May 2009
Location: Michigan
Posted: 22nd Nov 2011 20:42 Edited at: 22nd Nov 2011 20:49
Quote: "I did this using Sparky's collision and plains."

That was awesome baxslash!
I'll check out the Sparky's stuff, I always avoided it before because I sometimes can barely get by just using the in built dbp features and I figured anything else would just add to the complication.
I really do suck at coding. I'll give it a shot though.

I was really hoping there would be some sort of engine like the littlebigplanet level creator out there.

http://mattsmith.carbonmade.com/
baxslash
Valued Member
Bronze Codemaster
19
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 22nd Nov 2011 22:11
Quote: "I really do suck at coding. I'll give it a shot though."

That's the spirit! Self deprecation with a touch of the old US give it a go anyway. Welcome home soldier!

If you get stuck give me a shout...

basjak
16
Years of Service
User Offline
Joined: 16th Apr 2010
Location: feel like signing up for mars
Posted: 23rd Nov 2011 14:24
instead of making sprite, get a plane and texture it with the sprite.
baxslash
Valued Member
Bronze Codemaster
19
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 23rd Nov 2011 14:34
Quote: "instead of making sprite, get a plane and texture it with the sprite."

I should have said, that's what I did. That means your character can go behind scenery too

Nateholio
20
Years of Service
User Offline
Joined: 30th Dec 2005
Location: I\'ve Been Everywhere
Posted: 24th Nov 2011 08:21
Gotta agree with baxslash...give it a go anyway. Don't fall into the disgrace of "I can't do it"/"It's too hard" so many of the yung-uns here in the US fall into. If you think you can't you won't and might as well go hang out in Zuccotti Park, NY. I thought I'd never be able to get USGS terrains into my projects, but with determination I've got them working fairly well. Ask yourself this: is my project more important than the hassle of learning to code? Besides, everyone sucks at coding when they first start coding or code something they are just learning.

Good luck and happy coding!

In Development: K96 - Combat Simulation

Login to post a reply

Server time is: 2026-07-10 21:41:30
Your offset time is: 2026-07-10 21:41:30