How do I simulate a stuck pedal? My scenario will be a runaway car, no brakes and stuck pedal, how do I get the game to make the drive pedal stuck?
You might need to mod in your own vehicle for this, although there is probably some way to accomplish it with a script, but you would need to do some research on this. As for a custom vehicle I think adjusting the torque curve, idle RPM and braking coefficient might do what you want. Try setting the torque curve to a constant, setting the idle RPM to whatever the constant you want in the torque curve is, and setting brakingCoefRPS to 0. There is a large chance this won't work, but it might send you in the right direction. You probably want help from someone with experience scripting events into scenarios for a proper setup without a separate vehicle just for the scenario.
By overriding the player's input commands. Something like this should do the trick: Code: local M = {} local player local function onRaceStart() player = scenetree.findObject("scenario_player0") end local function onRaceTick(raceTickTime) if player then player:queueLuaCommand('input.event("axisy0", math.huge)') -- Throttle player:queueLuaCommand('input.event("axisy1", -math.huge)') -- Brake player:queueLuaCommand('input.event("axisy2", -math.huge)') -- Parking brake end end M.onRaceStart = onRaceStart M.onRaceTick = onRaceTick return M The math.huge is used to ensure that the player input is overwritten completely: as far as I can tell the applied input is calculated by adding the input values for each device, this seems to ensure that the resulting value will always max out.