# IProjectile interface

> A projectile in flight, as its behaviour and the weapon that launched it see it. It never hits its owner. A number or vector it's given that isn't finite, or is past a float's range, throws ArgumentOutOfRangeException naming it, and so does an orientation of all zeros.

Namespace `EvilEngine.Api.Weapons`, assembly `EvilEngine.Api`. Engine commit 4ff877b1.

```csharp
public interface IProjectile
```

A projectile in flight, as its [behaviour](/docs/api/iprojectilebehaviour) and the weapon that launched it see it. It never hits its owner. A number or vector it's given that isn't finite, or is past a float's range, throws `ArgumentOutOfRangeException` naming it, and so does an orientation of all zeros.

## Members

### Model (property)

```csharp
ContentId Model { get; set; }
```

The model it draws as, which can change, like a missile's motor lighting.

### Position (property)

```csharp
MapVector Position { get; set; }
```

Where it is.

### Velocity (property)

```csharp
MapVector Velocity { get; set; }
```

How fast it's moving, in meters a second. Setting it steers a traced projectile or sets a physics body's speed.

### Orientation (property)

```csharp
Orientation Orientation { get; set; }
```

How it's turned.

### Age (property)

```csharp
double Age { get; }
```

Seconds since it was launched.

### Time (property)

```csharp
double Time { get; }
```

The session's clock in seconds.

### Interval (property)

```csharp
double Interval { get; }
```

The tick's length in seconds.

### Alive (property)

```csharp
bool Alive { get; }
```

Whether it's still in the world.

### Stuck (property)

```csharp
bool Stuck { get; }
```

Whether it has stuck in something.

### Body (property)

```csharp
IPhysicsBody? Body { get; }
```

Its physics body when it's [physical](/docs/api/weaponprojectile#physical), or `null`.

### Glow (property)

```csharp
ProjectileGlow? Glow { get; set; }
```

Its glowing sprite, which it can change, like a grenade blinking faster.

### Trail (property)

```csharp
ProjectileTrail? Trail { get; set; }
```

Its trail, which it can start or stop.

### Trace (method)

```csharp
WeaponTrace Trace(MapVector from, MapVector to)
```

A line through the world, its props and its people, leaving out its owner.

### Sound (method)

```csharp
void Sound(ContentId sound)
```

Plays a sound record where it is.

### Strike (method)

```csharp
void Strike(double damage, MapVector impulse, DamageKind kind = DamageKind.Generic)
```

Hurts the person it just touched by the damage, of the [kind](/docs/api/damagekind) given, or pushes the prop it just touched by the impulse in kg·m/s.

### Explode (method)

```csharp
void Explode(WeaponBlast blast)
```

Removes it and sets off a [blast](/docs/api/weaponblast) where it is, lifted a unit off the surface it hit.

### Stick (method)

```csharp
void Stick(double seconds)
```

Stops it where it is for so many seconds, at most 60, then removes it.

### Remove (method)

```csharp
void Remove()
```

Takes it out of the world.
