Problema cu gasirea masinile personale.
#1

Bun deci am o problema, am facut comanda vipname si problem este ca daca dai /vipname pe o masina personala spune ca nu sunt intr-una.

PHP Code:
new PlayerSlot playerVariables[playerid][VehicleSlot]; 
if(
PVeh[PlayerSlot][playerid][Vehicle] != vehicleid) return SCM(playeridCOLOR_GREY"You have to be in your personal vehicle!"); 
Nu inteleg care ar fii problema, la restrictia asta m-am luat dupa comanda /park si aia functioneaza cum trebuie...
Reply
#2

Incearca sa faci ceva de genu

PHP Code:
new PlayerSlot playerVariables[playerid][VehicleSlot];  
if(
PVeh[PlayerSlot][playerid][Vehicle] != vehicleid
{
      
codu tau
}
else
{
return 
SCM(playeridCOLOR_GREY"You have to be in your personal vehicle!");  

Reply
#3

Quote:
Originally Posted by Calinut200
View Post
Incearca sa faci ceva de genu

PHP Code:
new PlayerSlot playerVariables[playerid][VehicleSlot];  
if(
PVeh[PlayerSlot][playerid][Vehicle] != vehicleid
{
      
codu tau
}
else
{
return 
SCM(playeridCOLOR_GREY"You have to be in your personal vehicle!");  

Code:
new PlayerSlot = playerVariables[playerid][VehicleSlot];   // nu este nevoie de creat variabila daca folosesti numai odata playerVariables[playerid][VehicleSlot]
if(PVeh[PlayerSlot][playerid][Vehicle] != vehicleid)  //putem pune si aici playerVariables[playerid][VehicleSlot]
{ 
      codu tau 

} else  return SCM(playerid, COLOR_GREY, "You have to be in your personal vehicle!");
Reply
#4

E acelasi lucru cum am facut eu....
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)