Particle Triggers
Posted: Mon Aug 01, 2016 11:15 pm
Ok, this one is a little weird. Here's the code for explosion remnant particles. This is the debris left over by an explosion.
See the little bit there at the end called " ended_in_water_trigger_effect ="? Is there a way to find out if the particle ended on land? Basically I want to create a specific entity when the particle ends on land, just like it creates a specific entity when the particle ends in water.
Code: Select all
{
type = "particle",
name = "explosion-remnants-particle",
flags = {"not-on-map"},
life_time = 60 * 15,
pictures =
{
sheet =
{
filename = "__base__/graphics/entity/explosion-particle/explosion-particle.png",
priority = "extra-high",
width = 38,
height = 38,
frame_count = 10,
animation_speed = 0.5,
variation_count = 40
}
},
shadows =
{
sheet =
{
filename = "__base__/graphics/entity/explosion-particle/explosion-particle-shadow.png",
priority = "extra-high",
width = 48,
height = 38,
frame_count = 10,
animation_speed = 0.5,
variation_count = 40,
shift = {0.0625, 0}
}
},
regular_trigger_effect =
{
type = "create-smoke",
entity_name = "smoke-explosion-particle",
starting_frame_deviation = 5,
starting_frame_speed_deviation = 5,
offset_deviation = {{-0.06, -0.06}, {0.06, 0.06}},
speed_from_center = 0.007
},
regular_trigger_effect_frequency = 1,
ended_in_water_trigger_effect =
{
type = "create-entity",
entity_name = "water-splash"
}
},