Explosions shouldn't break player joints/welds

Explosion objects are outdated. The properties are limited and force developers to create their own systems for a large number of use cases.

We need properties that don’t combine outcomes of the explosion object. Right now, BlastPressure is a combination property of killing players and moving unanchored parts since explosions destroy player joints/welds, killing them instantly.

Separating these properties into BlastDamage and BlastPressure would make it much easier to work with. A bool property that enables/disables breaking player joints/welds would also fix this, although it still wouldn’t allow an instant way to damage players instead of killing them.

Note: I know this can be achieved by using the Explosion.Hit method, this is simply an ease-of-use suggestion.

13 Likes

Is your use case not resolved by DestroyJointRadiusPercent?

6 Likes

BlastDamage would need some sort of probability to determine what gets unanchored inside the blast radius. Like a feature set that adds extra functionality to Materials (Roblox Creator Hub), adding or subtracting the “health” of materials based on part size, volumetrics, and material type. A new Object Property (Roblox Creator Hub) for BaseParts could be a damage multiplier that offsets what explosions can do to them!

3 Likes

I need to destroy joints, just not player joints.

5 Likes

Couldn’t this be solved with a sphere cast, and a DestroyJointRadiusPercent of 0?

keep player joints, break everything else

The explosion class is not outdated. Could it be improved? Definitely. There’s a number of options available to you for explosions.

DestroyJointRadiusPercent which someone already linked to, is the percentage of the BlastRadius, from Position, where joints are destroyed. BlastPressure determines how hard an explosion is. So if you have a blast pressure of 1,000,000, parts are going to fly, maybe even off the map.

If you want custom damage, then you can avail yourself of the Explosion.Hit event which gives you the part that was hit and the distance from the center of the explosion. Only parts inside the radius will be hit. Inside the event, you can damage players based on distance (Roblox has example code for this), you can unanchor parts so they fly, you can just simply destroy parts.

One thing that I do is create a neon sphere of an orange or yellow color and parent a PointLight to it. So when the explosion happens, I tween the sphere size from Vector3.new(0.1, 0.1, 0.1) to the blast radius and the transparency from 0 to 1 with a time of one seconds. The sphere is anchored and the collisions are off. It gives a nice expanding fireball effect.

You are given a basic explosion class. It’s up to your imagination as to what you want to do with it.

With that being said, a player damage property based on radius would be nice, but I don’t think they will do that since they have given example code in the documentation.

2 Likes

Why not? It makes total sense that an explosion can rip of arms without killing the humanoid.

It is very possible in real life too that explosions can rip of arms but leave a person alive.