Checkpoint set problem -
enzulikeS - 09.02.2018
if(TakingLesson[playerid] == 1) { }
else {
SetPlayerCheckpoint(playerid, 1219.0502,-1812.7823,16.5938,5.0);
SendClientMessage(playerid,COLOR_YELLOW, "A checkpoint has been set to the driving school.");
SendClientMessage(playerid,COLOR_GREY, "You don't have a driving license.");
RemovePlayerFromVehicle(playerid);
TogglePlayerControllable(playerid, 1);
SetTimerEx("UnFreezeStation", 500, 0, "i", playerid);
why this doesn't set a checkpoint to the DMV and return the message to the player after pressing F to a car without driving license?
****
Re: Checkpoint set problem -
Mugala - 10.02.2018
where is this code placed?
Re: Checkpoint set problem -
PepsiCola23 - 10.02.2018
what do you use TakingLesson for?
Re: Checkpoint set problem -
enzulikeS - 10.02.2018
Quote:
Originally Posted by Mugalito
where is this code placed?
|
public OnPlayerStateChange(playerid, newstate, oldstate)
Re: Checkpoint set problem -
Mugala - 10.02.2018
well I dont understand what u need help with but, I think this code is badly-writed
PHP код:
if(TakingLesson[playerid] == 1)
{
SetPlayerCheckpoint(playerid, 1219.0502,-1812.7823,16.5938,5.0);
SendClientMessage(playerid,COLOR_YELLOW, "A checkpoint has been set to the driving school.");
}
else
{
SendClientMessage(playerid,COLOR_GREY, "You don't have a driving license.");
RemovePlayerFromVehicle(playerid);
TogglePlayerControllable(playerid, 1);
SetTimerEx("UnFreezeStation", 500, 0, "i", playerid);
}
I think this must be your code.
Re: Checkpoint set problem -
enzulikeS - 10.02.2018
https://pastebin.com/1zAykfh1
Line 11826 is giving a error, that line is: (D:\server\gamemodes\ExtremeGame.pwn(11826) : error 029: invalid expression, assumed zero
)
I need help with this, let me explain what. When a player without a driving license press F to a car, it will show up the message "You don't have a driving license." and set a checkpoint for the respective player to the DMV, showing up the message ""A checkpoint has been set to the driving school."
Re: Checkpoint set problem -
enzulikeS - 10.02.2018
Fixed the error which i showed up there, but it still doesn't work.
It does not set a checkpoint to the DMV and doesn't return the message with "A checkpoint has been set.."
Re: Checkpoint set problem -
PepsiCola23 - 10.02.2018
show me how you use
PHP код:
TakingLesson[playerid]
Re: Checkpoint set problem -
enzulikeS - 10.02.2018
if(TakingLesson[playerid] == 1)
{
PlayerTextDrawHide(playerid, DMVexam[playerid]);
PlayerTextDrawHide(playerid, DMVcheck[playerid]);
DestroyVehicle(examcar[playerid]);
DisableRemoteVehicleCollisions(playerid, 0);
examcar[playerid] = -1;
TakingLesson[playerid] = 0;
DisablePlayerRaceCheckpoint(playerid);
}
I noticed the location where I edited bugged /exam. The checkpoint and the message is showing only when typing /exam, it get me out from the car.. i don't know where i should edit for doing what i said up there
Re: Checkpoint set problem -
JasonRiggs - 10.02.2018
Okay so, show me the whole code now, tell me what do you want to do using it, tell me the current bug please, So I can fix this for you.