Was going to post this for 1c1p's first birthday, but was off-line at the time and it kinda slipped me by.
Anyway it's our scroller engine, which was based on code by Token3 ( Thanks Mike ).
Basically it's a copy and paste scroller class.
With that in mind it's not going to run as quickly as a custom written scroller, but it's pretty speedy, and you've just got to pass it some properties and hey presto, instant 8 way scrolling.
The example is just a simple horizontal scroller ( Based on my old Amiga game "Torque", which was just a copy of the C64 game Uridium ), but it shouldn't be too much effort to alter it to what ever you want.
The map format for the demo is runlength encoded, but it supports the normal oos / jailbitc'h format.
The actual class is pretty huge, and I wouldn't even bother looking through it, just accept that it works and it's a nice easy way for you to prototype your game before putting in your own scroller code.
I’d sing a very belated happy birthday, but I hear the performing rights are quite expensive. But you know where to send the scroller royalties? – right
The actual class is pretty huge, and I wouldn't even bother looking through it, just accept that it works and it's a nice easy way for you to prototype your game before putting in your own scroller code.
Reading through the code gave me a headache, but it works like a charm, and it's damn fast for a plug in and play engine
tonypa:
Hmmm dunno to be honest. I just found it all today and zipped it up quickly, figured it would work ( Does here ).
Not finding the map file ?
Pauly:
lol, as if.
I really was going to post it up for the 1c1p first birthday, as a little way of saying thanks to the community for their continued support, but missed it thanks to moving house and being dsl-less.
I've not used tiles for so long now that it seemed a bit of a waste it just sitting around on my hd.
It was written in MX ( 2.4k wasn't even out then ) and I just altered a few tiny things today and made a point of re-saving it as a MX file to make it open to more people.
I'll have a look later see if I can see anything staring me in the face.
Apart from that, looks pretty cool. Don't have time to go through the code now, but later I'll have a look.
Nice one Squize!
"wen i found my gerbil dead my other gerbil was eating it i just cried and screamed" http://www.livescripts.net
-------------------------------------------------------------------------------- Last edited by some moderator : Today at 9:01 PM.
so is there an advantage to using this sort of method over simply attaching arbitrary objects based on a datastructure divided into screensized tiles...? there must be, because i took one look at the endless sea of lines of code and felt dizzy! ;-)
but seriously, its a lot more complex, is it alot smoother/more stable or something?
and that looks like it could be a really fun game, with the switching and such. the style would make a fun WW2 ship sinking(strafing/bombing) game!
>flashl!ght<
All the normal names were taken.
Ron Paul was right.
Looks like I'll have to play around and make it MX compatable, sorry for the wasted d/loads guys.
Chris, my days of being smutty are long gone
I still using tile based stuff where I need to, I'm not anti-tb or anything silly like that ( I come from a history of 8/16 bit machines so tb is all I really know ), but I've not had to do anything tiley scrolly for ages.
It's just a case of using the best approach for what you need. I used tb in a puzzle type game the other month, and yet uxb ( Bomb Jack clone ) is largely art-based.
T1ger yeah you should mate. This class is just handy for whipping something up nice and quick, so you can spend more time on the gameplay.
Although it's as fast as most scrollers out there, and pretty flexable, I'd still be kinda disappointed if people just used it for the final game.
I know kdsh7 had an 8-way scroller up and running using this in about 10mins, and that's what it's there for.
Cheap and cheerful
"so is there an advantage to using this sort of method over simply attaching arbitrary objects based on a datastructure divided into screensized tiles...?
Wow, that's a proper mouthfull
I don't like the super tile approach, I know it can be quicker ( Much in strille's excellent engine ) but I find it really inflexable.
To me the main point of tiles is still the original purpose of tiles ( Or "Blocks" if you're as old as me ), and that's to allow a lot of graphical variation taking up as little memory as possible.
Really well designed tiles don't look like tiles, but I really don't think the same is true about supertiles.
I know you can use graphics and just lay them down in each spT [supertile] mc, but I imagine setting up the collision detection points is really more trouble than it's worth, having to mess around with each unique spT.
Sticking with nice little 32x32 tiles gives you a load more possabilities.
As to the code, there's a load of stuff that isn't really needed, such as the whole hitTest routines ( They're specific to one game ), but I wanted to build it up every time I used it so it could be copy and paste for whatever scrolling project I wanted to do, and also I didn't want to go around deleting code just before zipping it up as it's prone to getting messed up ( Even though it is anyway )
"and that looks like it could be a really fun game, with the switching and such"
Uridium is one of my favourite ever shooters, and if you legally own the original for the C64 I'd suggest everyone check it out
( Uridium II on the Amiga is still the finest piece of code I've ever seen ).
Be fantastic if a good clone came about from this code.