Animations, two players, accept invation
#1

Hello ! How can I do that two players between them could say hello? Use the command /invitesup /acceptsup ?

Код:
CMD:invitesup(playerid, params[])
{

	new tarid, 
	if(sscanf(params, "u", tarid)) return SendClientMessage(playerid, -1, "> SYNTAXE: /invite [playerid]");//if the command is not typed correctly, it will show you the correct way to use the command.
	SetPVarInt(tarid, "invitefac", facid);//saves the invite, to /accept it
	SendClientMessage(tarid, -1, "You have been invited to Greeting ! /acceptinvite [playerid]");
	ApplyAnimation(playerid, "WUZI", "Wuzi_Greet_Plyr", 4.1, 1, 1, 1, 1, 1, 1);
	return 1;
}
CMD:acceptsup(playerid, params[])
{

 	new string[128];//creates a faction id and some text on the players screen
	GetPVarInt(playerid, "invitefac");//calls the saved invite from the previous command
	format(string, sizeof(string), "> You accepted invation from player %s", ReturnPlayerName(playerid));
	SendClientMessage(playerid, -1, string);
	DeletePVar(playerid, "invitefac");//deletes the saved invite
	ApplyAnimation(playerid, "WUZI", "Wuzi_Greet_Plyr", 4.1, 1, 1, 1, 1, 1, 1);
	return 1;
}
Reply
#2

You do have apply animation to the two players when "tarid" accepts invitation.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)