Rotatable dummy for an animation

Place to get help with not working mods / modding interface.
Post Reply
User avatar
ownlyme
Filter Inserter
Filter Inserter
Posts: 400
Joined: Thu Dec 21, 2017 8:02 am
Contact:

Rotatable dummy for an animation

Post by ownlyme »

Is there any kind of entity i can spawn to display a procedurally rotated graphic?
I tried the projectile prototype but it's shaking like wild.
Any idea?

Code: Select all

{
    type = "projectile",
    name = "explosion-1",
    flags = {"not-on-map","placeable-off-grid"},
    --collision_box = {{-0.05, -0.25}, {0.05, 0.25}},
    acceleration = 0,
    direction_only = true, -- tire nao persegue -- tiro reto
	rotatable = true,
    action =
    {
      type = "direct",
      action_delivery =
      {
        type = "instant",
        target_effects =
        {
          {
            type = "damage",
            damage = {amount = 50 , type = "electric"}
          }
        }
      }
    },
	animation =
	  {
        filename = "__explosions__/graphics/1.png",

        width = 409,
        height = 343,
        frame_count = 25,
        line_length = 5,
        animation_speed = 0.4,
		scale = 1.2,
      },
	light = {intensity = 0.6, size = 10,color=blue},
	speed = 0
  }
Attachments
shaking.gif
shaking.gif (2.42 MiB) Viewed 533 times
mods.factorio.com/user/ownlyme
My requests: uiAbove||Grenade arc||Blueprint allies||Creeps forget command/ don't get removed||Player Modifiers||textbox::selection||Better Heat IF||Singleplayer RCON||tank bug w/ min_range >= projectile_creation_distance

Bilka
Factorio Staff
Factorio Staff
Posts: 3133
Joined: Sat Aug 13, 2016 9:20 am
Contact:

Re: Rotatable dummy for an animation

Post by Bilka »

How about just using the script rendering? https://lua-api.factorio.com/latest/Lua ... _animation allows you to draw animation prototypes that you defined in the data stage (https://wiki.factorio.com/Prototype/Animation).
I'm an admin over at https://wiki.factorio.com. Feel free to contact me if there's anything wrong (or right) with it.

User avatar
ownlyme
Filter Inserter
Filter Inserter
Posts: 400
Joined: Thu Dec 21, 2017 8:02 am
Contact:

Re: Rotatable dummy for an animation

Post by ownlyme »

Hmm thats for 0.17 :(
mods.factorio.com/user/ownlyme
My requests: uiAbove||Grenade arc||Blueprint allies||Creeps forget command/ don't get removed||Player Modifiers||textbox::selection||Better Heat IF||Singleplayer RCON||tank bug w/ min_range >= projectile_creation_distance

User avatar
darkfrei
Smart Inserter
Smart Inserter
Posts: 2903
Joined: Thu Nov 20, 2014 11:11 pm
Contact:

Re: Rotatable dummy for an animation

Post by darkfrei »

ownlyme wrote:
Sat Mar 16, 2019 10:20 am
Hmm thats for 0.17 :(
Do you want to make mods for old game version?

User avatar
ownlyme
Filter Inserter
Filter Inserter
Posts: 400
Joined: Thu Dec 21, 2017 8:02 am
Contact:

Re: Rotatable dummy for an animation

Post by ownlyme »

Yes because 0.17 is garbage ;)
mods.factorio.com/user/ownlyme
My requests: uiAbove||Grenade arc||Blueprint allies||Creeps forget command/ don't get removed||Player Modifiers||textbox::selection||Better Heat IF||Singleplayer RCON||tank bug w/ min_range >= projectile_creation_distance

Post Reply

Return to “Modding help”