Vice City: Multiplayer

Server Development => Scripting and Server Management => Topic started by: Cool on Oct 23, 2015, 06:39 PM

Title: what i put
Post by: Cool on Oct 23, 2015, 06:39 PM
what i put to its write 1 to 201 ids numbers automatic i try numbers but not works
QuerySQL( db, "INSERT INTO cars ( ID, Cost, Owner, Shared) VALUES ( '1', '600000', 'Vice-City', 'None')" );
Title: Re: what i put
Post by: MacTavish on Oct 23, 2015, 06:45 PM
Try Edited
else if(cmd =="insert")
{
local Max_Veh = GetVehicleCount()+1;
for(local i=1; i < Max_Veh; ++i)
{
QuerySQL( db, "INSERT INTO cars ( ID, Cost, Owner, Shared) VALUES ( '"+i.tointeger()+"', '600000', 'Vice-City', 'None')" );
print("Done ID: "+i.tointeger());
}
}
Title: Re: what i put
Post by: Cool on Oct 23, 2015, 07:54 PM
Thanx Works Perfect As usual your everything works perfect