sm.projectile.shapeFire
Creates and fires a projectile from a Shape.
Kind: Function
Environments: Game
Game
Overload 1
sm.projectile.shapeFire( shape, name, position, velocity, delay )
Availability: Server only
Deprecated: Name is deprecated, use uuid instead
Parameters:
| Name | Type | Description |
|---|---|---|
shape |
Shape | The shape. |
name |
string | The projectile's name. |
position |
Vec3 | The start position. |
velocity |
Vec3 | The direction and velocity. |
delay (optional) |
integer | The number of ticks before firing. (Defaults to 0) |
Overload 2
sm.projectile.shapeFire(
shape,
uuid,
position,
velocity,
delay,
projectileAmount
)
Availability: Server only
Parameters:
| Name | Type | Description |
|---|---|---|
shape |
Shape | The shape. |
uuid |
Uuid | The projectile's uuid. |
position |
Vec3 | The start position. |
velocity |
Vec3 | The direction and velocity. |
delay (optional) |
integer | The number of ticks before firing. (Defaults to 0) |
projectileAmount (optional) |
integer | The amount of shots that will be fired. Uses projectile amount from json if not set (Optional, range of 0-255) |