MatH16 Posted April 11, 2023 Share Posted April 11, 2023 local function onburnt(inst) inst.SoundEmitter:PlaySound("phonograph/end") inst.SoundEmitter:KillSound("phonograph/play") DefaultBurntStructureFn(inst) inst:AddTag("burnt") inst:PushEvent("turnedoff") end How do I make it so I get the normal effects of a burnt structure (coal drops etc.) but I can do extra stuff when onburnt happens? I tried with this as well, but did not get it working either way local function OnBurntPhonograph(inst) inst:PushEvent("turnedoff") inst.SoundEmitter:PlaySound("phonograph/end") inst.SoundEmitter:KillSound("phonograph/play") end inst.ListenForEvent("onburnt", OnBurntPhonograph) I'm happy about any help - thanks in advance!! Link to comment https://forums.kleientertainment.com/forums/topic/147098-custom-onburnt-listening-to-onburnt-extra-functions/ Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now