09.01.2017, 09:20
I found a script & i don't know how to make my gates, their were several codes in it, if you can explain me for it, I'd be very thankful
First Code
The Second code for open
The code for close
Please explain me each & everything so I could use it in future
First Code
Код:
TestGate = CreateDynamicObject(980, -333.2999900, 1810.2000000, 43.8000000, 0.0000000, 0.0000000, 354.0000000);
Код:
CMD:testgateo(playerid, params[]) { #pragma unused params if(strcmp(pName(playerid), "TestName", true) == 0) { MoveDynamicObject(Jefford, -333.2999900, 1810.2000000, 38.2000000, 5); SendClientMessage(playerid, Biru, "| - Your gate now is opened! - |"); } else return SendClientMessage(playerid, red, "ERROR: Only the owner of this house (TestName) can open this gate!"); return 1; }
Код:
CMD:testgatec(playerid, params[]) { #pragma unused params if(strcmp(pName(playerid), "TestName", true) == 0) { MoveDynamicObject(Jefford, -333.2999900, 1810.2000000, 43.8000000, 5); SendClientMessage(playerid, Biru, "| - Your gate now is closed! - |"); } else return SendClientMessage(playerid, red, "ERROR: Only the owner of this house (TestName) can close this gate!"); return 1; }