SA-MP Forums Archive
i have a problem with my pawno - 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)
+--- Thread: i have a problem with my pawno (/showthread.php?tid=324995)



i have a problem with my pawno - jw_peeters - 11.03.2012

Hey guys,
I tried to make a moveable gate with these lines:

if (strcmp(cmd, "/opengate, true == 0) {
MoveObject(lvaenterg1, 96.699996948242, 1920.5999755859, 13.60000038147, 1);
//To move the gate
SendClientMessage(playerid, COLOR_BLUE, "The Entergate is opened.");
return 1;
}


if (strcmp(cmd, "/closegate, true == 0) {
MoveObject(lvaenterg1, 996.699996948242, 1920.5999755859, 17.700000762939, 1);
//To move the gate
SendClientMessage(playerid, COLOR_BLUE, "The Entergate is closed.");
return 1;
}

But after i added those lines and i tried to compile it, my pawno just crashes and it doesn't compile.
(I also get an .amx file with 0 bytes).

Can someone please help me out.
jw


Re: i have a problem with my pawno - CmZxC - 11.03.2012

Did you add it in OnPlayerCommandText(playerid, cmdtext[])?
Did you define "cmd" ?
Do you have variable lvaenterg defined to an object using CreateObject?


Re: i have a problem with my pawno - jw_peeters - 11.03.2012

-yeah i did
-i don't know (but if i search #define and keep pressing the search button i don't see #define cmd)
-yeah i have