struct

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(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)
Source
new(*, __pull_for_json_serializable pull : JSON::PullParser)
Source

Instance methods

columns
Source
duration_ms
Source
frame_count
Source
frame_h
Source
frame_w
Source
loop_count
Source
merged(measured : ImageAnimation) : ImageAnimation

What was measured, keeping the sprite-sheet grid the application gave.

Source