mtasa-blue
mtasa-blue copied to clipboard
Add spawnFlyingComponent & breakGlass arguments for setVehiclePanelState
This PR adds the spawnFlyingComponent argument (defaulting to true) to setVehiclePanelState, similar to what is available in setVehicleDoorState. Additionally, the PR introduces the feature to shatter the windscreen if windscreen_panel is set to 3; currently, the windscreen simply disappears.
Added breakGlass argument.
bool setVehiclePanelState(vehicle theVehicle, int panelID, int state [ , bool spawnFlyingComponent = true, bool breakGlass = false ] )
https://streamable.com/uxpph6
This PR helps avoid frustrating situations, such as when managing a garage of vehicles and changing their models.
Closes #2122