lspd gate
#1

in my rp gamemode,for lspd faction there is a garage gate,when i go there and do /gate there it says you are not near a gate,all the other gates works but the garage ones doesnt work my code is:
if(strcmp(cmdtext, "/gate", true) == 0)
{
if(IsPlayerInRangeOfPoint(playerid,9,1588.91, -1637.63, 13.44))
{ //POLICE GATE
if(!IsACop(playerid) && !IsAnAgent(playerid)) return SendClientMessage(playerid,COLOR_GREY," You are not a Cop / FBI / SAST !");
if(pdgategar==0)
{
pdgategar = 1;
MoveDynamicObject(pdgaragegateobj, 1588.6501464844, -1638.0750732422, 6.2343215942383, 0);
}
else if(pdgategar==1)
{
pdgategar = 0;
MoveDynamicObject(pdgaragegateobj, 1588.6428222656, -1638.02734375, 15.240161895752, 0);
}
}
Reply
#2

if(IsPlayerInRangeOfPoint(playerid,9,1588.91, -1637.63, 13.44))
change this to the one position where you will stand for opening gate
Reply
#3

still saying the same
Reply
#4

Can someone help me?this lspd gate is the garage"s gate,which lets you go into the lspd garage
Reply
#5

pawn Код:
if(strcmp(cmdtext, "/gate", true) == 0)
{
    if(IsPlayerInRangeOfPoint(playerid,9,1588.91, -1637.63, 13.44))
    { //POLICE GATE
        if(!IsACop(playerid) && !IsAnAgent(playerid)) return SendClientMessage(playerid,COLOR_GREY," You are not a Cop / FBI / SAST !");
        if(pdgategar==0)
        {
            pdgategar = 1;
            MoveDynamicObject(pdgaragegateobj, 1588.6501464844, -1638.0750732422, 6.2343215942383, 0);
        }
        else if(pdgategar==1)
        {
            pdgategar = 0;
            MoveDynamicObject(pdgaragegateobj, 1588.6428222656, -1638.02734375, 15.240161895752, 0);
        }
    }
    else return SendClientMessage(playerid, COLOR_GREY, "You're not near to the LSPD Gate.");
}
Replace your command with this, then try again.
Reply
#6

still doesnt work,please help me,if someone can script it for me again i'll pay him
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)