Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: AisforAxe on Mon 20/06/2011 22:13:37

Title: Keeping room properties when changing the background.
Post by: AisforAxe on Mon 20/06/2011 22:13:37

Hello everyone:

I made an animated background too big for a test game, resulting in most of the sky being cut off.

I didn't cared about that then but now I want to polish the game a little and lower the sky in that particular room: Is there a simple way to switch to the new background while keeping the room settings such as walkable areas, hotspots, walk-behinds, etc. ?


Thanks in advance!


(I searched the forums and the manual for this, sorry if I missed an obvious answer.)
Title: Re: Keeping room properties when changing the background.
Post by: monkey0506 on Mon 20/06/2011 22:22:43
If you replace the background in the editor it shouldn't replace walkable areas, walk-behinds, hotspots, or regions so long as the background image is the same size..

You said you originally created the image too large, so perhaps you could just pad the image with a black bar at the top (which would be cut off in-game).
Title: Re: Keeping room properties when changing the background.
Post by: AisforAxe on Tue 21/06/2011 00:48:35
That's about the only thing I didn't think about... thanks for the answer.

To make this thread a little more useful, what if the image size is different?

Let's say you want to modify a heavily scripted room by making it larger or smaller (in a way that the initial coordinates still apply of course).

Is it possible to import all the things that were in the room or do you always have to start from scratch?


Title: Re: Keeping room properties when changing the background.
Post by: monkey0506 on Tue 21/06/2011 02:06:58
Well if the image is a different size then all of your walkable areas, walkbehinds, hotspots, and regions will be erased. Your objects and your room script will be unchanged.

AGS doesn't currently allow you to export these areas, but you can import a mask from a file. So if you had your walkable areas for the room drawn and saved in a separate file (not on the room background, draw it on a separate layer and then save it against a white background IIRC), then you could reimport the masks.
Title: Re: Keeping room properties when changing the background.
Post by: AisforAxe on Tue 21/06/2011 03:02:27
Thanks for the quick reply!