Factorio.com|Forums|Wiki|Mod Portal|API Docs Prototype|Runtime|Auxiliary

# Factorio Prototype Docs Version 2.0.7

## AnimationVariations :: struct or Animation or array[Animation] Example code

## Properties

- default
- sorted

sheet optional | :: AnimationSheet | The variations are arranged vertically in the file, one row for each variation.
The variations are arranged vertically in the file, one row for each variation.
sheets optional | :: array[AnimationSheet] | Only loaded if `sheet` is not defined.
Only loaded if `sheet` is not defined.

sheet optional | :: AnimationSheet | The variations are arranged vertically in the file, one row for each variation.
The variations are arranged vertically in the file, one row for each variation.
sheets optional | :: array[AnimationSheet] | Only loaded if `sheet` is not defined.
Only loaded if `sheet` is not defined.

## Properties

### sheet :: AnimationSheet optional

The variations are arranged vertically in the file, one row for each variation.

### sheets :: array[AnimationSheet] optional

Only loaded if `sheet` is not defined.

## Examples

    -- array of animations
    animations =
    {
      {
        filename = "__base__/graphics/entity/explosion-gunshot/explosion-gunshot.png",
        draw_as_glow = true,
        priority = "extra-high",
        width = 34,
        height = 38,
        frame_count = 2,
        animation_speed = 1.5,
        shift = {0, 0}
      },
      {
        filename = "__base__/graphics/entity/explosion-gunshot/explosion-gunshot.png",
        draw_as_glow = true,
        priority = "extra-high",
        width = 34,
        height = 38,
        x = 34 * 2,
        frame_count = 2,
        animation_speed = 1.5,
        shift = {0, 0}
      },
      -- [...]
    }

    -- animation sheet using "sheet"
    pictures =
    {
      sheet =
      {
        filename = "__base__/graphics/entity/character/footprints.png",
        line_length = 2,
        frame_count = 2,
        width = 30,
        height = 22,
        shift = util.by_pixel(0.25, 0.25),
        scale = 0.5,
        variation_count = 8
      }
    }

Type used in

- ArtilleryFlarePrototype::pictures
- ArtilleryFlarePrototype::shadows
- BeamAnimationSet::body
- CharacterCorpsePrototype::pictures
- ConstructionRobotPrototype::sparks
- CorpsePrototype::splash
- CorpsePrototype::ground_patch
- CorpsePrototype::ground_patch_higher
- CorpsePrototype::ground_patch_decay
- EnemySpawnerGraphicsSet::animations
- EnemySpawnerGraphicsSet::underwater_animations
- EnemySpawnerGraphicsSet::water_effect_map_animations
- ExplosionPrototype::animations
- FireFlamePrototype::small_tree_fire_pictures
- FireFlamePrototype::pictures
- FireFlamePrototype::smoke_source_pictures
- FireFlamePrototype::secondary_pictures
- LightningGraphicsSet::explosion
- ParticlePrototype::pictures
- ParticlePrototype::shadows
- ResourceEntityPrototype::stages
- ResourceEntityPrototype::stages_effect
- SimpleEntityPrototype::animations
- SimpleEntityWithOwnerPrototype::animations
- StatelessVisualisation::animation
- StatelessVisualisation::shadow
- TransportBeltConnectorFrame::frame_main
- TransportBeltConnectorFrame::frame_shadow