• Unfortunately, we have experienced significant hard drive damage that requires urgent maintenance and rebuilding. The forum will be a state of read only until we install our new drives and rebuild all the configurations needed. Please follow our Facebook page for updates, we will be back up shortly! (The forum could go offline at any given time due to the nature of the failed drives whilst awaiting the upgrades.) When you see an Incapsula error, you know we are in the process of migration.

||Arsenic [ars]Save-system error||

Newbie Spellweaver
Joined
Aug 24, 2017
Messages
16
Reaction score
0
hi i have a error saving the cars in my server
Error:
[23:24:03] ERROR: [ars]save-system\vehicle_save.lua:77: attempt to concatenate a nil value

Any ideas??
 
Newbie Spellweaver
Joined
Aug 24, 2017
Messages
16
Reaction score
0
local colorQuery = nil
if ( not color1 ) and ( not color2 ) then
colorQuery = "color1='0', color2='0', custom_colors='".. sql:escape_string(colors) .."'"
else
colorQuery = "color1=".. sql:escape_string(color1) ..", color2=".. sql:escape_string(color2) ..", custom_colors=''"
end

local update = sql:query("UPDATE vehicles SET currx=".. sql:escape_string(x) ..", curry=".. sql:escape_string(y) ..", currz=".. sql:escape_string(z) ..", currrotx=".. sql:escape_string(rotx) ..", currroty=".. sql:escape_string(roty) ..", currrotz=".. sql:escape_string(rotz) ..", currdimension=".. sql:escape_string(dim) ..", currinterior=".. sql:escape_string(int) ..", fuel=".. sql:escape_string(fuel) ..", lights=".. sql:escape_string(lights) ..", engine=".. sql:escape_string(engine) ..", enginebroke=".. sql:escape_string(enginebroke) ..", handbrake=".. sql:escape_string(handbrake) ..", ".. colorQuery ..", `upgrades`='".. sql:escape_string( upgrades ) .."', health=".. sql:escape_string(health) ..", Impounded=".. sql:escape_string(impounded) .." WHERE id=".. sql:escape_string(dbid) .."")
if not (update) then
outputDebugString("MySQL Error: Vehicle saving failed!", 1)
end

sql:free_result(update)
end
addEventHandler("onVehicleExit", getRootElement(), saveVehicle)
addEvent("saveVehicle", true)
addEventHandler("saveVehicle", getRootElement(), saveVehicle)
 
Back
Top