View Full Version : How do you give Buildings animation?????


Killamike718
May 30, 2006, 03:49 PM
I was just wondering, Can you give buildings animation like a wheel spinning, or lights blinking/flashing when in use? How?

Thanks in advance

The Great Apple
May 30, 2006, 04:38 PM
I'm pretty sure it's possible. There is a <bAnimated> flag in the building art defines, and some of the default buildings have it enabled.

Having said that, I have no idea how you would go about doing it.

Killamike718
May 30, 2006, 07:09 PM
Yea your right it is possible but is there any way to set up the animation order like if something is used, how to allow it to play the animations when something is happening?

Padmewan
May 31, 2006, 08:50 AM
What buildings already have animation? Can you work backwards from there?

I've found a lot of interesting tidbits in the LPlot (sp?) XML files for terrain and city layout. (For example, that's where the many states of wineries -- unimproved/unworked, unimproved/worked, improved/unworked, improved/worked). I suggest start by looking there.

What happens if you put a structure that you KNOW is animated (e.g., the oil well) in as a city building?

Chalid
May 31, 2006, 09:57 AM
The question is do you want to use it as city building or as improvement.
For city buildings you do of course not have an trigger when it is used, but the improvements are animated like units. with eventcodes and all this.

Killamike718
May 31, 2006, 02:50 PM
So like Padmewan asked, Can you make game improvements as city buildings?
I was thinking of makeing Improvements and then have them in the city, and lets say play it animation when its bieng used.

Lets say you need an archery range to build an archer and you built an archery range, but your in the process of building an archer, I want some form of animation to happen when its building the archer.

Edit: How do i give the building its setup for animation. do i use the MD? What code (ec_1000) do i use?

Chalid
May 31, 2006, 03:14 PM
I am pretty sure that you cannot switch animations for city buildings based on what you are doing in the city, unfortunateley, as they are placed by that strage LSystem things. But of course i would like to be proven wrong.

the animation sequences available for improvements are:
default: ec_0
off: ec_1
notworked: ec_2
on: ec_3

and yes you use the MD as for units.

Killamike718
May 31, 2006, 03:25 PM
WOW thanks big help!!!!! I was checking through the art buildings XML and it said it can load a kmf file. Doesnt a kmf file contain animation info?

Chalid
May 31, 2006, 03:35 PM
yep kfm has the animation info. Hmm is there any building that does actually load a kfm? i would like to take a look if there is.

The Great Apple
May 31, 2006, 04:39 PM
The forge has the bAnimated flag in it's art defines directory, so I would assume it does.

Killamike718
May 31, 2006, 06:22 PM
so there is a possible chance for animation? Can we create like a water fountain?