// Fixed Car System
for(new i = 0; i < MAX_PLAYERS; i ++)
{
if(IsPlayerConnected(i))
{
if(PlayerInfo[i][pPcarkey] == vehid || PlayerInfo[i][pPcarkey2] == vehid)
{
if(PlayerInfo[i][pPcarkey] == vehid) PlayerInfo[i][pPcarkey] = 9999;
else if(PlayerInfo[i][pPcarkey2] == vehid) PlayerInfo[i][pPcarkey2] = 9999;
SafeGivePlayerMoney(i, GetVehiclePrice(vehid) / 2);
}
else
{
format(string, sizeof(string),"LARP/Users/%s.ini",CarInfo[vehid][cOwner]);
new totalcash = dini_Int(string,"Money") + GetVehiclePrice(vehid);
dini_IntSet(string,"Money",totalcash);
if(dini_Int(string,"Car") == vehid)
{
dini_IntSet(string,"Car",9999);
strmid(PlayerInfo[i][pPcarkey], "9999", 0, strlen("9999"), 9999);
}
else if(dini_Int(string,"Car2") == vehid)
{
dini_IntSet(string,"Car2",9999);
strmid(PlayerInfo[i][pPcarkey], "9999", 0, strlen("9999"), 9999);
}
}
}
}
// End Of Fix for the Car-Sell system //
|
Editing Raven's Role-Play is a pain in ass and the worse thing you can try... Plus it's all about old scripting, which people don't know almost anything now-a-days..
|