AddStaticVehicle Problem
#1

Hi!
I'm working at a filterscript - car ownership, and I'm confrunting with a big problem.
My algorithm for create a vehicle is:


- The player are introducing the values in some dialogs ( like modelid, colors )
- After that, I extract this values from database ( cache r7 ), and with that, I create by AddStaticVehicle, a vehicle. But, here is the problem .. the vehicle doesn't appear . I don't know the source of this problem and I asked you, probably you're knowing. The log of mysql is 'successful'.

Thanks.
Reply
#2

I think AddStaticVehicle I used only OnFilterScriptInit.

Use CreateVehicle
Reply
#3

OnFilterScriptInit and or OnGameModeInit
Reply
#4

pawn Код:
CreateVehicle(modelid, Float:x, Float:y, Float:z, Float:angle, color1, color2, respawn_delay)
Is used to create vehicles after the gamemode/filterscript has been initiated.

https://sampwiki.blast.hk/wiki/CreateVehicle
Reply
#5

Ok, so AddStaticVehicle is only for OnGame/FilterscriptInit, and CreateVehicle is for any part of the script?
Reply
#6

AddStaticVehicle = This function can only create vehicles in the OnGameModeInit and the OnFilterScriptInit callback.
CreateVehicle = Creates a vehicle in the world.

https://sampwiki.blast.hk/wiki/AddStaticVehicle
https://sampwiki.blast.hk/wiki/CreateVehicle
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)