Vehicle () unable to properly initialize due to script error in ()!


function Police_Car(ply)
	--Stuff for spawning Cop Car
	local newVehicle = ents.Create("prop_vehicle_jeep");
	newVehicle:SetModel("models/copcar.mdl");
	newVehicle:SetPos(Vector(-1295, 415, -140));
	newVehicle:SetAngles(Angle(0, -90, 0));
	newVehicle:Spawn();
end
concommand.Add("rp_p_c", Police_Car)

Error output.


Vehicle () unable to properly initialize due to script error in ()!

Link to the car that I’m trying to use.

I’m not sure how to resolve this error because I haven’t made a car spawning before, but I was hoping you guys do. I am able to spawn the car through the Q-Menu the way the car was intended to be used.

Anyways, I’m hoping you guys can help.

Have you got the correct vehicle script in garrysmod/scripts/vehicles ?

He never set the vehicle script.

Sorry for the late reply but I set the vehicle script and it works, I assumed it was something along those lines because there was a vehicle script file in the download.