💣 Grenade
Grenades are Pickables which Characters can grab and throw. It explodes after X seconds after thrown, causing damage around.
💂Authority
This class can only be spawned on 🟦 Server side.
👪Inheritance
🧑💻API Source
This page is auto-generated! The Functions, Properties and Events described here are defined in our GitHub's API Repository! Feel free to commit suggestions and changes to the source .json API files!
🎒 Examples
local new_grenade = Grenade(
Vector(-900, 185, 215),
Rotator(0, 90, 90),
"nanos-world::SM_Grenade_G67",
"nanos-world::P_Grenade_Special",
"nanos-world::A_Explosion_Large"
)
🛠 Constructors
Default Constructor
local my_grenade = Grenade(location, rotation, static_mesh_asset?, explosion_particles?, explosion_sound?, collision_type?, gravity_enabled?)
Type | Name | Default | Description |
---|---|---|---|
Vector | location | Required parameter | No description provided |
Rotator | rotation | Required parameter | No description provided |
StaticMesh Reference | static_mesh_asset | nanos-world::SM_Grenade_G67 | No description provided |
Particle Reference | explosion_particles | nanos-world::P_Grenade_Special | No description provided |
Sound Reference | explosion_sound | nanos-world::A_Explosion_Large | No description provided |
CollisionType | collision_type | CollisionType.Auto | No description provided |
boolean | gravity_enabled | true | No description provided |
tip
nanos world provides a special Particle* called nanos-world::P_Grenade_Special
which spawns different particles depending on the surface it explodes, and also if is underwater.
*This "Particle" is just a special identifier which can only be used on Grenades!