|luk3yx d798443c7c||7 months ago|
|LICENSE.md||7 months ago|
|README.md||7 months ago|
|init.lua||7 months ago|
|mod.conf||7 months ago|
|sscsm.lua||7 months ago|
A mod library that enables animated formspecs on Minetest 5.0.0+.
animated_imagetags to be parsed.
This mod adds a new formspec element:
animated_image. This is compatible
with usage described on the similar but different
https://github.com/minetest/minetest/pull/9032, however with more features:
animated_image[<X>,<Y>;<W>,<H>;<texture name>:<frame count>,<frame duration>;<oneshot>]
<texture name>is the name of the texture to use. If this contains a single
%swill be replaced by the current frame, otherwise
_<current frame>.pngwill be appended to the base texture name. Both
,are allowed in this field. Note that frame numbers start from
<frame count>is the number of frames to display.
<frame duration>is the duration each frame will be displayed for in milliseconds.
true, prevents the animation from looping (returning to the first frame) when it has reached the last frame. If this parameter is omitted, it is assumed to be
animated_imageelements requires the usage of
minetest.show_formspec(). Formspecs are passed through
formspec_ast.interpret(), and custom elements such as
formspec_ast:centered_labelshould also work.
list) will not work nicely while animations are being displayed and will be “reset” each time a new animation frame is drawn.
sscsmCSM isn't installed on clients, only the first frame (or last frame for one-shot animations) of the animation will be displayed.
/formspec_anim command can be used to show an animated image, and
/formspec_anim oneshot can be used to display a one-shot animation.