DexoTronic Posted April 3, 2010 Share Posted April 3, 2010 Hey i get bad arguements at this script line: destroyElement( _G["PlayerCar"..getPlayerName(source)]) ( _G["PlayerCar"..getPlayerName(source) is = createVehicle ( 475, -198.83, 1216.94, 20, 0, 0, 180 ) ) and PlayerCarID[source] = getAccountData ( account[source], "CarID" ) PlayerCarx[source] = getAccountData ( account[source], "Carx" ) PlayerCary[source] = getAccountData ( account[source], "Cary" ) PlayerCarz[source] = getAccountData ( account[source], "Carz" ) PlayerCarrx[source] = getAccountData ( account[source], "Carrx" ) PlayerCarry[source] = getAccountData ( account[source], "Carry" ) PlayerCarrz[source] = getAccountData ( account[source], "Carrz" ) setPlayerMoney ( source, PlayerMoney[source]) if PlayerCarID[source] > 0 then createVehicle ( tonumber(PlayerCarID[source]), tonumber(PlayerCarx[source]), tonumber(PlayerCary[source]), tonumber(PlayerCarz[source]), tonumber(PlayerCarrx[source]), tonumber(PlayerCarry[source]), tonumber(PlayerCarrz[source]) ) end and @createvehicle Link to comment
50p Posted April 3, 2010 Share Posted April 3, 2010 Don't declare variable with name of players! It will cause problems if player name contains other characters than numbers or letters. Just make global table and use player element as its index. Besides, the code you showed us doesn't contain any _G which is your error. Link to comment
DexoTronic Posted April 3, 2010 Author Share Posted April 3, 2010 kk i wrote it in tabels and it workd Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now