This command creates a traffic group that can be populated with subsequent calls to AddTrafficModel.
Context
This command should be called in a level's initialisation script (leveli.mfk).
Additionally, this should be followed by at least one call to AddTrafficModel and a call to CloseTrafficGroup.
Syntax
CreateTrafficGroup( index );
Game.CreateTrafficGroup( index )
- index: The index of the traffic group.
Examples
CreateTrafficGroup(0);
AddTrafficModel("pizza", 5);
CloseTrafficGroup();
Game.CreateTrafficGroup(0)
Game.AddTrafficModel("pizza", 5)
Game.CloseTrafficGroup()
Notes
By default, the game only supports a single traffic group with an index of 0.
Mods can use the Mod Launcher's Custom Traffic Support hack to create more than one.