Is this possible?
#6

Quote:
Originally Posted by Ducati
Посмотреть сообщение
You could use this if you're trying to send the command for individual players
Код:
COMMAND:fakecommand(playerid,params[])
{
   		new TargetID, command[64];
		
	    if(sscanf(params, "us[64]", TargetID, command))
        {
        SendClientMessage(playerid, COLOR_ERROR, "Usage: /fakecommand [PlayerID] [Command]") &&
		SendClientMessage(playerid, COLOR_ERROR, "Function: Will send a false Command used per Specified player");
		return 1;
		}
		
        if(IsPlayerConnected(TargetID) && TargetID != INVALID_PLAYER_ID)
		{
	         CallRemoteFunction("OnPlayerCommandText", "us", TargetID, command); 
	    }
		else SendClientMessage(playerid,COLOR_ERROR,"That Player is Not Connected");
	return 1;
}
Touching on this, what this actually does is directly call OnPlayerCommandText. This is then handled by the script accordingly from there, either inline or forwarded to something such as zmcd. Natively, SA-MP does not (for good reason) allow interaction with client side commands and nothing is sent to the server when you type them (bar /quit). You can check for FPS and enforce players using a certain /fpslimit or face kick/freeze, but can't force it on them.

For checking FPS, see this. Is there a specific reason you wish to limit it?
Reply


Messages In This Thread
Is this possible? - by DusanInfinity - 01.03.2018, 19:06
Re: Is this possible? - by MarioKamani - 01.03.2018, 19:09
Re: Is this possible? - by RogueDrifter - 01.03.2018, 19:10
Re: Is this possible? - by Ducati - 01.03.2018, 19:44
Re: Is this possible? - by RogueDrifter - 01.03.2018, 19:47
Re: Is this possible? - by Abagail - 02.03.2018, 04:27
Re: Is this possible? - by DusanInfinity - 05.03.2018, 09:21

Forum Jump:


Users browsing this thread: 1 Guest(s)