SA-MP Forums Archive
The second action doesn't work - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: The second action doesn't work (/showthread.php?tid=214243)



The second action doesn't work - Roma555 - 20.01.2011

Why the second action doesn't work 2

Код:
if (!strcmp("/1", cmdtext, true))
    {
        if(GetPlayerState(playerid) == 1 && PlayerToPoint(3.0, playerid,-2792.7700,-10.3369,7.0391)) //
        {
        if(provfire == 0)
        {
        CreateObject(18690, 280.996704, 1876.698120, 14.849337, 90.2407954, -2.57831008, 1.71887339);
        CreateObject(18690, -2794.0922851563, -12.043877601624, 9.0996828079224, 0, 0, 270.67565917969);
        SendClientMessage(playerid, COLOR_RED, "action 1");
        provfire = 1;
        }
//The second action
        else if(PlayerToPoint(3.0, playerid,-2794.9434,216.4308,7.1875)) //
        {
        if(provfire2 == 0)
        {
        CreateObject(18690, -2791.4255371094, 214.50006103516, 9.2241134643555, 0, 0, 0);
        CreateObject(18690, -2791.2272949219, 214.4561920166, 12.408718109131, 0, 0, 0);
        SendClientMessage(playerid, COLOR_RED, "action 2");
        provfire2 = 1;
        }
        }
        else
        {
        SendClientMessage(playerid, COLOR_RED, "This house already burns");
		}
		}
        else
        {
        SendClientMessage(playerid, COLOR_RED, "Rise on a pickup");
		}
        return 1;
    }