Search found 3 matches

by Forty-Bot
Mon Nov 26, 2018 12:19 am
Forum: Not a bug
Topic: [0.16.51] trigger_created_entity has wrong force
Replies: 5
Views: 1605

Re: [0.16.51] trigger_created_entity has wrong force

create-trivial-smoke trigger effect is not subtype of create-entity trigger effect.
It says it is on the wiki
Inherits all properties from Types/TriggerEffectItem.
by Forty-Bot
Sun Nov 25, 2018 1:40 am
Forum: Not a bug
Topic: [0.16.51] trigger_created_entity has wrong force
Replies: 5
Views: 1605

Re: [0.16.51] trigger_created_entity has wrong force

It is that explosion has no force, so it always reads and acts as 'neutral'.

So can we change that? It's created by something with a force (the projectile). I'm using it to create other effects at run-time which are force-dependent, so I would like some way to get the original force from this ...
by Forty-Bot
Sat Nov 24, 2018 9:17 pm
Forum: Not a bug
Topic: [0.16.51] trigger_created_entity has wrong force
Replies: 5
Views: 1605

[0.16.51] trigger_created_entity has wrong force

In data.lua:

data.raw.projectile["atomic-rocket"].action.action_delivery.target_effects[2].trigger_created_entity = true

In control.lua:

script.on_event(defines.events.on_trigger_created_entity, function (e)
game.print(e.entity.name .. " " .. e.entity.force.name)
end)


When firing the ...

Go to advanced search