13.07.2012, 18:11
Im newbie in SA-MP programming but trying to figure out the code.
When i buy a car i store car details to MySQL like that :
ID, CARID, OWNER, X, Y, Z, COLOR1, COLOR2, HEALTH
ID(mysql generates unique ID by auto increment
CARDID - GetPlayerVehicleID (if i buy infernus it shows 70 when i go with another nickname and buy infernus it shows 70 aswell).
Owner (who bought the car)
X, Y,Z bought car position (save when player exit the car, and when player disconnect).
COLOR1, COLOR2 (don't know how to get vehicle colors)
Health (car health).
Question is how to know when i bought a car (infernus) and my friend bought(infernus) which oh these infernus is mine? Couse i want to make lock system but until i don't know how to see difference between two same cars i cant make that system. Becouse when i lock 1 infernus lock's all or not mine.
Thanks for help guys and sorry from my bad english.
When i buy a car i store car details to MySQL like that :
ID, CARID, OWNER, X, Y, Z, COLOR1, COLOR2, HEALTH
ID(mysql generates unique ID by auto increment
CARDID - GetPlayerVehicleID (if i buy infernus it shows 70 when i go with another nickname and buy infernus it shows 70 aswell).
Owner (who bought the car)
X, Y,Z bought car position (save when player exit the car, and when player disconnect).
COLOR1, COLOR2 (don't know how to get vehicle colors)
Health (car health).
Question is how to know when i bought a car (infernus) and my friend bought(infernus) which oh these infernus is mine? Couse i want to make lock system but until i don't know how to see difference between two same cars i cant make that system. Becouse when i lock 1 infernus lock's all or not mine.
Thanks for help guys and sorry from my bad english.