Currently having a problem.
#1

Hello, I have a problem with this one.
Код:
dcmd_m(playerid, params[])
{
if(IsPlayerInAnyVehicle(playerid))
{
new Vehicleid;
Vehicleid = GetPlayerVehicleID(playerid);
if(Vehicleid == police2)
{





new
output[128],
pName[MAX_PLAYER_NAME],
str[157];
if(sscanf(params, "m", output)) SendClientMessage(playerid, COLOR_RED, "Usage: /m [message]");
else
{
GetPlayerName(playerid, pName, sizeof(pName));
format(str, sizeof(str), " MEGAPHONE: Police Officer %s: %s!!!", pName, output);
ProxDetector(100.0, playerid, str, COLOR_YELLOW, COLOR_YELLOW, COLOR_YELLOW, COLOR_YELLOW, COLOR_YELLOW);

}
}
else
{
SendClientMessage(playerid, COLOR_RED, "This vehicle is not equiped with a megaphone.");
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "You are currently not in any vehicle.");
}

return 1;
}
But for me it shows "MEGAPHONE: Police Officer %s: %s!!!" only.
Please help.
Reply
#2

Sorry for bumping this thread but it seems like no one sees it.
Reply
#3

so your saying it only shows for you? and not for everyone? just change it to GameTextForAll or w/e
Reply
#4

No, I mean this shows for everyone but the thing im writing after /m doesn't show up. Like if I write /m stop it only says
"MEGAPHONE: Police Officer Richard_Wright:!!!"
Reply
#5

pawn Код:
if(sscanf(params, "m", output))
change it to

pawn Код:
if(sscanf(params, "s", output))
Reply
#6

Does not work.
Reply
#7

Eh, what is proxydetector? :O
Reply
#8

It makes it ranged, but that's not the problem. I want it to show MEGAPHONE: Police officer Richard Wright: stop!!! when typing /m stop
Reply
#9

Bump.
Reply
#10

Where is your actual sendclientmessage command, it doesn't appear to be in there, you just run proxdetector then end.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)