Donut Team is a labor of love, built and maintained by a small group of passionate developers. We invest our own time and resources to offer our tools, mods, and web services completely free of charge.

We don't run ads, and we will never sell your data - period.

If you've enjoyed anything we've created, please consider supporting our work with a one-time or monthly donation via our Ko-fi page . Every contribution helps us continue building great experiences for the community.

Dismiss
  • Games
  • Radical Entertainment
  • The Simpsons: Hit & Run
  • Scripting
  • Console Commands
  • MFK Commands
  • Mission Initialisation

SetForcedCar

Sets a mission to require a forced car.

This will disable phonebooths for the duration of the mission.

Scope

This command should be called between calls to SelectMission and CloseMission in a mission's initialisation script.

Syntax

MFK
Lua
SetForcedCar();
Game.SetForcedCar()

Examples

MFK
Lua
SelectMission("m6");
	// ...
	InitLevelPlayerVehicle("marge_v", "m6_canyonero_start", "OTHER");

	SetForcedCar();

	AddStage();
		// ...
	CloseStage();
CloseMission();
Game.SelectMission("m6")
	-- ...
	Game.InitLevelPlayerVehicle("marge_v", "m6_canyonero_start", "OTHER")

	Game.SetForcedCar()

	Game.AddStage()
		-- ...
	Game.CloseStage()
Game.CloseMission()

Notes

This command must be used in conjunction with InitLevelPlayerVehicle to add a player car to the OTHER slot for the mission. The game will crash if there is no OTHER vehicle.