> ## Documentation Index
> Fetch the complete documentation index at: https://docs.nmentities.net/llms.txt
> Use this file to discover all available pages before exploring further.

# World & Visuals

> Lightning, explosions, particle shapes, time and weather.

Mechanics that affect the world around the mob: strikes, explosions, particles, time and weather.

## lightning

A real lightning strike at each target: damage, fire, the works. No attributes.

```yaml theme={null}
- lightning #onDeath @self
```

## fakelightning

The flash and sound of lightning with none of the damage. No attributes.

```yaml theme={null}
- fakelightning #onSpawn @self
```

## explosion

An explosion at each target.

**Alias:** `explode`

| Attribute     | Alias   | Description                     |
| ------------- | ------- | ------------------------------- |
| `yield`       | `power` | Explosion strength. TNT is `4`. |
| `fire`        |         | Whether it starts fires.        |
| `blockdamage` |         | Whether it breaks blocks.       |

```yaml theme={null}
- explosion{yield=3;fire=false;blockdamage=false} #onDeath @self
```

## particle

Spawns particles at each target.

**Aliases:** `effect:particles`, `e:p`

| Attribute  | Alias  | Description                                   |
| ---------- | ------ | --------------------------------------------- |
| `particle` | `type` | Particle id, e.g. `flame`, `end_rod`, `dust`. |
| `amount`   |        | How many.                                     |
| `spread`   |        | Random spread around the point.               |
| `speed`    |        | Particle speed.                               |

```yaml theme={null}
- particle{particle=flame;amount=30;spread=0.5} #onHurt @self
```

## particlering

A horizontal ring of particles around each target.

**Alias:** `particlecircle`

| Attribute  | Description                      |
| ---------- | -------------------------------- |
| `particle` | Particle id.                     |
| `radius`   | Ring radius in blocks.           |
| `points`   | Number of particles in the ring. |

```yaml theme={null}
- particlering{particle=flame;radius=5;points=48} @self
```

## particlesphere

A sphere of particles around each target.

| Attribute  | Description          |
| ---------- | -------------------- |
| `particle` | Particle id.         |
| `radius`   | Sphere radius.       |
| `points`   | Number of particles. |

```yaml theme={null}
- particlesphere{particle=soul_fire_flame;radius=3;points=100} @self
```

## particleline

A beam of particles from the mob to each target.

| Attribute  | Description               |
| ---------- | ------------------------- |
| `particle` | Particle id.              |
| `points`   | Particles along the beam. |

```yaml theme={null}
- particleline{particle=electric_spark;points=30} @target
```

## particlehelix

A rising helix of particles at each target.

| Attribute  | Description          |
| ---------- | -------------------- |
| `particle` | Particle id.         |
| `radius`   | Helix radius.        |
| `height`   | How high it rises.   |
| `points`   | Total particles.     |
| `turns`    | Number of rotations. |

```yaml theme={null}
- particlehelix{particle=end_rod;radius=1;height=3;points=60;turns=3} @self
```

For fully custom animated shapes from math formulas, see [Particle Equations](particle-equations).

## time

Sets the time in the mob's world.

| Attribute | Alias  | Description                                          |
| --------- | ------ | ---------------------------------------------------- |
| `amount`  | `time` | World time in ticks. `0` = sunrise, `13000` = night. |

```yaml theme={null}
- time{amount=13000} #onSpawn @self
```

## weather

Sets the weather in the mob's world.

| Attribute  | Description                   |
| ---------- | ----------------------------- |
| `type`     | `clear`, `rain` or `thunder`. |
| `duration` | How long. Accepts time units. |

```yaml theme={null}
- weather{type=thunder;duration=2m} #onSpawn @self
```
