Page 1 of 1

How to control building animations

Posted: Wed Nov 19, 2025 10:10 am
by Xeon257
Hello. I’m looking for a way to turn a building’s animation on and off through scripting.

For example, I would like the entity to remain in an idle (non-animated) state normally, and then start playing its animation when the player “turns on the power” through a dialogue interaction.

I don’t have much knowledge about 2D graphics, and I haven’t experimented much with entity prototypes yet, so I’m not sure how I should approach this.
Could I ask for some advice?

Re: How to control building animations

Posted: Wed Nov 19, 2025 10:17 am
by Xeon257
To clarify my question a bit—what I’m really trying to understand is whether there is any API that allows enabling or disabling an entity’s animation directly, or if there are other commonly used methods to control animations in practice.

At the moment, the only idea I have is to base the entity on an assembling machine and register a recipe that produces nothing, so that I can control the animation by starting or stopping the crafting process. But I’m not sure if this is the proper or recommended approach.

Re: How to control building animations

Posted: Wed Nov 19, 2025 5:05 pm
by Silari
Does the disabled_by_script property not work for that? Far as I know it disables animations too.