Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

script isn't creating an explosion effect?

I'm making a game where you do missions, basically, I just create separate games that are called missions.

I scripted this without tutorials or wikis since I couldn't find any. The script creates an explosion by instance.new but it isn't working. Did I do it incorrectly? if so, please explain. Thank you!

script:

wait(1)
Instance.new("Explosion", script.Parent)
Explosion.BlastPressure = 100000
Explosion.BlastRadius = 100
end

I am of course a newbie at this so please explain what's wrong with it.

1 comment

0

I changed the 'wait()' part to test if it was working to 1.

1 answer

✓ Accepted answer

Hello, there's 2 problems with your code. First of all, you haven't defined a function of any sorts so you'd have to eliminate the end. Second of all, you have to locate where the Explosion is.

Here's what a finished example would be

wait(1)
local Explosion = Instance.new("Explosion", script.Parent)
Explosion.BlastPressure = 100000
Explosion.BlastRadius = 100

If this hasn't answered your question, please feel free to respond to me, please don't just automatically down vote me. Thanks :)

3 comments

0

Thanks!

0

but I do still have a problem with the positioning, I added Explosion.Position = -2.6, 4.3, -117.9 and it ain't working, the explosion is still inside the part but explodes in the middle of the baseplate? any help?

0

Sorry for the late delay, make the parent equal to workspace (same as game.Workspace), reply if you need any more help :)

This discussion is preserved as it was. New answers, comments, and votes are closed.