DataDungeon::ImageAnimation
Inherits JSON::Serializable < Struct < Value < Object
An animated picture's frames: how many, how long all of them last, how many times it plays (0: forever), and for a sprite sheet the grid its frames sit in. One row of image_animation; a still picture has none.
Constructors
new(pull : JSON::PullParser)
Sourcenew(frame_count : Int32 | Nil = nil, duration_ms : Int32 | Nil = nil, loop_count : Int32 | Nil = nil, frame_w : Int32 | Nil = nil, frame_h : Int32 | Nil = nil, columns : Int32 | Nil = nil)
Sourcenew(*, __pull_for_json_serializable pull : JSON::PullParser)
SourceInstance methods
columns
Sourceduration_ms
Sourceframe_count
Sourceframe_h
Sourceframe_w
Sourceloop_count
Sourcemerged(measured : ImageAnimation) : ImageAnimation
What was measured, keeping the sprite-sheet grid the application gave.