Some players can't see streamed vehicles

help
vehicles

#1

Now I know its caused by the player not having loaded the vehicles, but I’m also not sure how to force them to load the custom vehicles. I need this because alot of new players are unable to roleplay with other players due to not being able to see them. whether it be police or civilians, they can’t be seen by people who haven’t spawned the vehicles themselves. Is there a way to maybe do something like

RequestVehicleModel("contender")
while not hasVehicleLoaded("contender") do
    Citizen.Wait(0)
end

any help would be greatly appreciated!


#2

same here, i want to find a way to sort of force load the vehicle to the client. If that sounds right lol. Not sure if its possible though, because I always though the vehicles loading in depended on the PC and if it was good enough to load a very detailed vehicle. The more I think about it I feel that a decent PC does have something to do with it, but also the connection to the server could be more of the issue. I often find that people who are closer to the server host load vehicles much faster, even when their computer is below others. A guy who is an officer in my server has a new pre-built (i know ew) and he cant see some of the custom vehicles until we give him the spawn name and he spawns it himself. Is it possible to make the streaming of vehicles a higher priority on the server. This could help upload all the files to the client, if its possible I think that could be the solution. Find a way to make the client load all of the files as if they are spawning them, but not actually spawning. Hope someone sees this even though its an old post!


#3
local hash = GetHashKey("contender")

RequestModel(hash)

while not HasModelLoaded(hash) do
	RequestModel(hash)
	Citizen.Wait(0)
end

local x, y, z = table.unpack(GetEntityCoords(GetPlayerPed(-1), false))
local vehicle = CreateVehicle(hash, x + 2, y + 2, z + 1, 0.0, true, false)

found this here


#4

So is that like a way of the server spawning the vehicle?