Helló!
Tessék ittvan a kapu.
Remélem jó,nem teszteltem !
// Mod elejére
new rkapu;
// OnGamemodeInit alá
rkapu = CreateDynamicObject(980, -44.20000, 2323.10010, 25.80000, 0.00000, 0.00000, 330.00000)
// OnPlayerCommandText alá
//------------------------------[Rendor kapu]-------------------------------//
if(!strcmp(cmdtext, \"/bkapu-nyit\", true || strcmp(cmd, \"/bkapu-nyit\", true) == 0))
{
if(Admin(playerid, 1) || PlayerInfo[playerid][pLeader] == 7) || PlayerInfo[playerid][pMember] == 7))
{
if (PlayerToPoint(10, playerid,-44.20000, 2323.10010, 25.80000))
{
MoveDynamicObject(rkapu, -44.20000, 2323.10010, 19.46800, 3, 0.00000, 0.00000, 330.00000);
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), \"* %s kinyitja a kaput a távirányítóval.\", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
}
else { SendClientMessage(playerid, COLOR_GREY,\"Túl messze vagy a kaputól.\"); }
}
else return SendClientMessage(playerid, COLOR_GREY,\"Nem vagy Rendõr/Admin!\");
return 1;
}
if(!strcmp(cmdtext, \"/bkapu-zár\", true || strcmp(cmd, \"/bkapu-zar\", true) == 0))
{
if(Admin(playerid, 1) || PlayerInfo[playerid][pLeader] == 7) || PlayerInfo[playerid][pMember] == 7))
{
if (PlayerToPoint(10, playerid,-44.20000, 2323.10010, 25.80000))
{
MoveDynamicObject(rkapu, -44.20000, 2323.10010, 25.80000, 3, 0.00000, 0.00000, 330.00000);
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), \"* %s bezárja a kaput a távirányítóval\", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
}
else { SendClientMessage(playerid, COLOR_GREY,\"Túl messze vagy a kaputól.\"); }
}
else return SendClientMessage(playerid, COLOR_GREY,\"Nem vagy Rendõr/Admin!\");
return 1;
}