360 Degree Scroller Background Effects

BlitzMax Forums/BlitzMax Programming/360 Degree Scroller Background Effects

Sean Doherty(Posted 2005) [#1]
I am working on a 2D 360 degree scroller and I have been trying to figure out how to improve the background graphics effects. At the moment, I have a static starmap that scrolls; it look ok but I would really like to do something better. I can improve the backround using tiles but I would still have a static backround.

How can I add some animation to the backgound? For example, Fliaxoid and Xeno Assault II both have good background scenes?


ImaginaryHuman(Posted 2005) [#2]
If you have a tilemap for your background, all you have to do it have animated tiles - you draw a different frame from the animated tiles each time you update the screen.


Sean Doherty(Posted 2005) [#3]
Are there other ways? That seems like a lot of work and I am fairly sure that Flaixoid is not using a tile map? Looks like a a couple of different graphics being overlayed and rotated?


Duckstab[o](Posted 2005) [#4]
You Could have 3 layers of images

First Draw Detail Textures
Then Two Use Alpha layers to bend with First
Create a motion type to keep information on the layers rotation speed and blending values
and have these updated each cycle

Try having 12 images per layer and rotate them when they leave the screen area so the background seems a little less manufactured

Cos and sin formulars really help making organic backgrounds


Sean Doherty(Posted 2005) [#5]
What do you mean when yoou say 12 images per layer and the rotate then when leaving the screen. What is my space is 4000 by 4000. Can you give me an example using this size of map?

Thanks


Duckstab[o](Posted 2005) [#6]


Some Hacked up code when working with particals

You Can add layers like that over you detail back ground just some blending concepts replace blend1.png with a alpha image of you choice maybe 400*400

Smoke and cloud images prolly work best


Sean Doherty(Posted 2005) [#7]
Ok, I got it working! I couple of questions:

1) I guess I would render my detail tile map before this effect?

2) Would you recommend a different image for every layer?

3) I only seems for work if I specify 32 bit?

4) Why is the SetColor setup to only work with red in the rample code?

Thanks


Duckstab[o](Posted 2005) [#8]
I just Wacked the code together to give an example
so it it a bit rough

1) yes and no depending on what effect you want
you can use methods like these to add light and shadow effects to different layers on the screen

ie
layer 1 land Detail
layer 2 Shadows (effects layer 1)
layer 3 Building Detail
layer 4 Shadows (effects layer 1,2,3)
layer 5 enviromental effect is clouds smoke light (effects layers 1,2,3,4)

2) you can use as many images as you want per layer it just means you have to control what they do a bit more

3) Yes there is a problem with aphlabanding in 16bit modes

4) remove the comments and play around with the values