note Help Needed
This wiki is the result of an ongoing community effort — thank you all for helping!
If you want to provide changes to this page then please click here.
CreateExplosion
Description
Create an explosion at the specified coordinates.
Name | Description |
---|---|
Float:x | The X coordinate of the explosion. |
Float:y | The Y coordinate of the explosion. |
Float:z | The Z coordinate of the explosion. |
type | The type of the explosion. |
Float:radius | The radius of the explosion. |
Returns
This function always returns 1, even when the explosion type and/or radius values are invalid.
Examples
public OnPlayerEnterCheckpoint(playerid)
{
// Get the player's position
new Float:x, Float:y, Float:z;
GetPlayerPos(playerid, x, y, z);
// Create an explosion at the player's position
CreateExplosion(x, y, z, 12, 10.0);
return 1;
}
Notes
tip
There is a limit as to how many explosions can be seen at once by a player. This is roughly 10.
Related Functions
- CreateExplosionForPlayer: Create an explosion which is visible for only a single player.
See Also
- Explosion Types: A list of all the explosion types.