Instead of having their own individual animation timers, animated blocks are all bound to the same one, making the addition of extra frames impossible with conventional methods.
There is a way, but it requires a bit of coding effort.
The idea in this method is to make the block itself invisible and draw the graphic you want to use over it using Lua. There are Block Offset values for the bonking effect, making the recreation of the vanilla block animation possible.
Here's a short piece of code from one of my levels which draws a still image over blocks of a certain ID:
Code: Select all
local overlayIcon = Graphics.loadImage("overlayIcon.png")
function onDraw()
for k,v in pairs(Block.get(176)) do
local offset = v:mem(0x52, FIELD_WORD) + v:mem(0x54, FIELD_WORD)
Graphics.drawImageToSceneWP(overlayIcon, v.x, v.y - offset, -65)
end
end
You can use a different drawImageToSceneWP overload and add a timer in order to properly draw an animated image.