Page 1 of 1

[1.1.45] Objects rendered by LuaRendering will draw above objects with higher y axis

Posted: Tue Nov 02, 2021 2:10 am
by evildogbot100
Graphics rendered by LuaRendering::DrawAnimation always drawn on top of all other non-scripted graphics even which have the same render_layer. For example, let's say there is an assembler at {0, 0}, if LuaRendering draw another animation at {0, -2} with render_layer="object", the newly created graphics will be drawn on top of the assembler. Normal entities is not drawn that way and adhere to y-axis order, only LuaRendering gets priority.

Re: [1.1.45] Objects rendered by LuaRendering will draw above objects with higher y axis

Posted: Tue Nov 02, 2021 7:30 am
by posila
LuaRendering objects are drawn in order in which they were created and on top of the render layer already drawn by the game. LuaRendering API is intended for short-lived local overlay visualizations and doesn't seem to be suitable for whatever you want to do.

Re: [1.1.45] Objects rendered by LuaRendering will draw above objects with higher y axis

Posted: Tue Nov 02, 2021 7:23 pm
by evildogbot100
My use case was like this,

I wanted the archon blue flame aura to keep animating even when the archon is not moving, however, there is no way to make it look normal. For the video I done it using LuaRendering to give the archon its aura animation. If I give the aura animation lower render order, it will render below the walls. Otherwise, on "object" render order, it will animate above the wall and potentially above the archon body itself if I didn't give the body even higher render order. Is this kind of mod possible on factorio engine?