CenterBurstEffect
CenterBurstEffect is designed for intentional burst actions controlled by explode(id).
Characteristics
- Produces
explodeOnFirstImpact = false. - Uses
ShardColliderShape.Circleby default. - Keeps shard grid square-ish when
squareShards = true.
Typical use
Button( onClick = { sceneState.explode("center") }, modifier = Modifier.physicsBody( id = "center", effect = CenterBurstEffect( shardsRows = 6, shardsCols = 6, impulseMin = 0.18f, impulseMax = 0.42f, ), ),) { Text("Explode Center")}Good tuning targets
- Use zero gravity for clean radial burst visuals.
- Increase
shardsRows/shardsColsfor finer fragment density. - Lower
impulseMaxfor tighter, less chaotic bursts.