I can't find it from API site.
I can't find it anyone asking about that on this forum.
What event fires when player explode cliff?
What event fires when player explode cliff?
English is not my native language. Sorry for bad English.
My mods :
Lua API global Variable Viewer (mod portal)
Lua API Event Trace (mod portal)
My tools :
Locale String Editor (github.io webapp)
My mods :
Lua API global Variable Viewer (mod portal)
Lua API Event Trace (mod portal)
My tools :
Locale String Editor (github.io webapp)
- eradicator
- Smart Inserter
- Posts: 5206
- Joined: Tue Jul 12, 2016 9:03 am
- Contact:
Re: What event fires when player explode cliff?
When i'm unsure what events are firing i just have them printed to console:
Code: Select all
/c
local rev = function(a,b) for k,v in pairs(a) do b[v]=k end return b end
local del = function(a,b) for _,k in pairs(a) do b[k]=nil end return b end
local nam = rev(del({'on_tick','on_chunk_generated'},defines.events),{})
script.on_event(rev(nam,{}),function(e) game.print(e.tick..': '..nam[e.name]) end)
Looks like there is no event for cliffs exploding.
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Re: What event fires when player explode cliff?
thanks! this code is so useful, but unfortunately i couldn't found any events but only on_player_used_capsule fires.eradicator wrote: ↑Mon Aug 03, 2020 3:23 pmWhen i'm unsure what events are firing i just have them printed to console:Code: Select all
/c local rev = function(a,b) for k,v in pairs(a) do b[v]=k end return b end local del = function(a,b) for _,k in pairs(a) do b[k]=nil end return b end local nam = rev(del({'on_tick','on_chunk_generated'},defines.events),{}) script.on_event(rev(nam,{}),function(e) game.print(e.tick..': '..nam[e.name]) end)
Looks like there is no event for cliffs exploding.
may be cliffs affected by throwing can be determined by combining some informations...
English is not my native language. Sorry for bad English.
My mods :
Lua API global Variable Viewer (mod portal)
Lua API Event Trace (mod portal)
My tools :
Locale String Editor (github.io webapp)
My mods :
Lua API global Variable Viewer (mod portal)
Lua API Event Trace (mod portal)
My tools :
Locale String Editor (github.io webapp)
- ickputzdirwech
- Filter Inserter
- Posts: 768
- Joined: Sun May 07, 2017 10:16 am
- Contact:
Re: What event fires when player explode cliff?
Keep in mind that robots can blow up cliffs as well.
I once tried to give the player an item if they blow up a cliff. In the end I implemented a entity similar to item on ground and expanded the following table to create one of it:
Code: Select all
data.raw.capsule[„cliff-explosives“].robot_action.action_delivery.target_effects = ...
Code: Select all
data.raw.projectile[„cliff-explosives“].action.action_delivery.target_effects = ...
Mods: Shortcuts for 1.1, ick's Sea Block, ick's vanilla tweaks
Tools: Atom language pack
Text quickly seems cold and unfriendly. Be careful how you write and interpret what others have written.
- A reminder for me and all who read what I write
Tools: Atom language pack
Text quickly seems cold and unfriendly. Be careful how you write and interpret what others have written.
- A reminder for me and all who read what I write