Write :
if(strcmp(cmd, \"/write\", true) == 0)
{
if(AccInfo[playerid][Level] >= 2)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, red, \"Használat: /write [szín] [szöveg]\");
SendClientMessage(playerid, orange, \"Szinek:
- Fekete, [1]Fehér, [2]Piros, [3]Narancs, [4]Sárga, [5]Zöld, [6]Kék, [7]Lila, [8]Barna, [9]Rózsaszin\");
return SendClientMessage(playerid, orange, \"Funkció: Üzenet Küldése Egy Kiválasztott Színnel\");
}
new Colour;
Colour = strval(tmp);
if(Colour > 9 )
{
SendClientMessage(playerid, red, \"Használat: /write [szín] [szöveg]\");
SendClientMessage(playerid, orange, \"Szinek:
- Fekete, [1]Fehér, [2]Piros, [3]Narancs, [4]Sárga, [5]Zöld, [6]Kék, [7]Lila, [8]Barna, [9]Rózsaszin\");
return SendClientMessage(playerid, orange, \"Funkció: Üzenet Küldése Egy Kiválasztott Színnel\");
}
tmp = strtok(cmdtext, idx);
if(Colour == 0) { format(string,sizeof(string),\"%s\",cmdtext[9]); SendClientMessageToAll(black,string);return 1;}
else if(Colour == 1) {
format(string,sizeof(string),\"%s\",cmdtext[9]);SendClientMessageToAll(COLOR_WHITE,string); return 1;}
else if(Colour == 2) {
format(string,sizeof(string),\"%s\",cmdtext[9]);SendClientMessageToAll(red,string); return 1;}
else if(Colour == 3) {
format(string,sizeof(string),\"%s\",cmdtext[9]);SendClientMessageToAll(orange,string); return 1;}
else if(Colour == 4) {
format(string,sizeof(string),\"%s\",cmdtext[9]);SendClientMessageToAll(yellow,string); return 1;}
else if(Colour == 5) {
format(string,sizeof(string),\"%s\",cmdtext[9]);SendClientMessageToAll(COLOR_GREEN1,string); return 1;}
else if(Colour == 6) {
format(string,sizeof(string),\"%s\",cmdtext[9]);SendClientMessageToAll(COLOR_BLUE,string); return 1;}
else if(Colour == 7) {
format(string,sizeof(string),\"%s\",cmdtext[9]);SendClientMessageToAll(COLOR_PURPLE,string); return 1;}
else if(Colour ==
{
format(string,sizeof(string),\"%s\",cmdtext[9]);SendClientMessageToAll(COLOR_BROWN,string); return 1;}
else if(Colour == 9) {
format(string,sizeof(string),\"%s\",cmdtext[9]);SendClientMessageToAll(COLOR_PINK,string); return 1;}
return 1;
}
else return ErrorMessages(playerid,
;
}
return 0;
Kocsis Cucc:
dcmd_car(playerid,params[])
{
if(AccInfo[playerid][Level] >= 3)
{
new Index;
new tmp[256]; tmp = strtok(params,Index);
new tmp2[256]; tmp2 = strtok(params,Index);
new tmp3[256]; tmp3 = strtok(params,Index);
if(!strlen(tmp)) return
SendClientMessage(playerid, red, \"Használat: /car [Modell ID/Név] [szin1] [szin2]\") &&
SendClientMessage(playerid, orange, \"Funkciók: Jármûvet Kérhetsz Le\");
new car;
new string[128];
new colour1, colour2;
if(!IsNumeric(tmp))
car = GetVehicleModelIDFromName(tmp);
else car = strval(tmp);
if(car < 400 || car > 611) return SendClientMessage(playerid, red, \"Hiba: Nincs Ilyen Jármû ID\");
if(!strlen(tmp2)) colour1 = random(126); else colour1 = strval(tmp2);
if(!strlen(tmp3)) colour2 = random(126); else colour2 = strval(tmp3);
if(AccInfo[playerid][pCar] != -1 && !IsPlayerAdmin(playerid))
EraseVeh(AccInfo[playerid][pCar]);
new LVehicleID;
new Float:X,Float:Y,Float:Z;
new Float:Angle,int1;
GetPlayerPos(playerid, X,Y,Z);
GetPlayerFacingAngle(playerid,Angle);
int1 = GetPlayerInterior(playerid);
LVehicleID = CreateVehicle(car, X+3,Y,Z, Angle, colour1, colour2, -1);
LinkVehicleToInterior(LVehicleID,int1);
AccInfo[playerid][pCar] = LVehicleID;
SendCommandToAdmins(playerid,\"Car\");
PutPlayerInVehicle(playerid,car,0);
format(string, sizeof(string), \"%s Le Spawnoltad \\\"%s\\\" (Model:%d) Színek (%d, %d), Pos: X:%0.2f, Y:%0.2f, Z:%0.2f\", pName(playerid), VehicleNames[car-400], car, colour1, colour2, X, Y, Z);
SaveIn(\"CarSpawns\",string);
format(string, sizeof(string), \"|- Le Spawnoltad \\\"%s\\\" (Model: %d) Színe: %d,%d -|\", VehicleNames[car-400], car, colour1, colour2);
return SendClientMessage(playerid,LIGHTBLUE, string);
}
else return ErrorMessages(playerid, 6);
}