planeCrash WIP

Module: vehicle_planecrashtest.lua

What it does

Simulates a plane crash near the player's position. Five vehicles (using Base.CarLightsPolice as a stand-in) are spawned in a cross pattern — one at the centre and four offset by 4 tiles in each cardinal direction. Each spawned vehicle has a random 10% chance per part of having that part destroyed. The centre vehicle's trunk is stocked with 5 axes. Immediately after spawning, 50 zombies are dispatched in waves of 5 every 240 ticks, each knocked down and then sprinting directly at the player.

Trigger type

planeCrash

Parameters

ParameterTypeDefaultValid ValuesDescription
This module takes no parameters. All values (spawn location, zombie count, wave timing) are hardcoded.
Internal ConstantValueDescription
Spawn offset±5 tiles (random)Centre crash square relative to the player.
Debris pattern+4 / −4 tiles4 additional vehicles arranged in a cross around the centre.
Total zombies50Total zombies spawned in waves.
Wave size5Zombies spawned per wave.
Wave delay240 ticksTicks between each wave.
Loot5x Base.AxePlaced in the centre vehicle's trunk.

Examples

Trigger a plane crash near the player
{ type="planeCrash" }
Use as a channel points event
{ type="planeCrash", message="!planeCrash" }
Use in a weighted random pool
{ type="planeCrash", weight=1 }