API ReferenceGE Extensionsflowgraphnodesgameplaytraffic
Setup Pursuit Gameplay
**File:** `flowgraph/nodes/gameplay/traffic/setupPursuitGameplay.lua`
File: flowgraph/nodes/gameplay/traffic/setupPursuitGameplay.lua
Description: Uses the traffic system to create pursuit gameplay, with a suspect and police vehicles.
Category: once_instant Tags: police, cops, pursuit, chase, traffic, ai
Input Pins
| Name | Type | Description |
|---|---|---|
suspectId | number | Suspect vehicle id. |
mainPoliceId | number | (Optional) Use this to provide one police vehicle id. |
policeIds | table | Array of police vehicle ids; if none given, attempts to use existing police vehicles. |
pursuitMode | number | Initial pursuit mode (from 1 to 3) |
preventAutoStart | bool | Set this to true if you want to manually control the pursuit activation. |
Output Pins
| Name | Type | Description |
|---|---|---|
success | flow | Flows if setup was successful. |
fail | flow | Flows if setup failed for some reason. |
Methods
C:workOnce()
See Also
- Add Vehicle (Traffic) - Related reference
- Traffic Driving Stats - Related reference
- File Vehicle Group - Related reference
- FlowGraph Guide - Guide