Hey how would i do this?.
#1

hey i want this to show a text draw i have made if the trailer isent attached to the vehicle but i get a error can anyone correct this? the error is on the "else" line thanks:
Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
  IsTrailerAttachedToVehicle(vehicleid);
  {
  else
  }
  TextDrawShowForPlayer(playerid, weburl);
  
  return 1;
}
Any ideas?. thanks
Reply
#2

Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
  if(IsTrailerAttachedToVehicle(vehicleid))
  {
  TextDrawShowForPlayer(playerid, weburl)
  }
  return 1;
}
Reply
#3

hey thanks but when i attach a trailer it still shows the text draw, any idea's why?
Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
  if(IsTrailerAttachedToVehicle(vehicleid))
  {
  TextDrawHideForPlayer(playerid, weburl);
  } else {
  TextDrawShowForPlayer(playerid, weburl);
  }

  return 1;
}
Reply
#4

anyone know?
Reply
#5

Nothing wrong with the code.
Try to check debug info.
Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
  printf("_%d_",IsTrailerAttachedToVehicle(vehicleid));
  if(IsTrailerAttachedToVehicle(vehicleid))
  {
  TextDrawHideForPlayer(playerid, weburl);
  } else {
  TextDrawShowForPlayer(playerid, weburl);
  }

  return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)