Modding Tools > Lucas' Simpsons Hit & Run Mod Launcher > Hacks > Mod Requirable Hacks > Additional Script Functionality > MFK Commands > Missions > SetParkedCarsEnabled

SetParkedCarsEnabled

Set whether or not parked cars are enabled for the mission.

Context

This command should be called between calls to SelectMission and CloseMission.

Syntax

SetParkedCarsEnabled( parked_cars_enabled );

Game.SetParkedCarsEnabled( parked_cars_enabled )

  • parked_cars_enabled: Whether or not parked cars are enabled.

Examples

SelectMission("m1");

	...

    StreetRacePropsLoad("l4_m1p.p3d;");
	StreetRacePropsUnload("l4_m1p.p3d:");
    
    // Enable parked cars even though Street Race Props are in use.
	SetParkedCarsEnabled(1);

	AddStage();
    	...
	CloseStage();
CloseMission();

Game.SelectMission("m1")

	...

    Game.StreetRacePropsLoad("l4_m1p.p3d;")
	Game.StreetRacePropsUnload("l4_m1p.p3d:")
    
    -- Enable parked cars even though Street Race Props are in use.
	Game.SetParkedCarsEnabled(1)

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

Notes

This command can be helpful for enabling parked cars in a mission where the "Street Race Props" would not interfere with the parked car locators (the original game's L1M7 could've used something like this).

Version History

1.21

Removed the "!m_bStart" assert (previously on line 3336) related to using this command.

1.20

Added this command.

Donut Team © 2024 · v4.0