Posts: 108
Threads: 20
Joined: Apr 2017
Reputation:
0
Invitation, so do you mean teleporting the player invited to your position or what do you mean?
Posts: 98
Threads: 16
Joined: Jul 2017
Reputation:
0
/ Bring id, the player = id has the option to accept if he wants to be pulled or not, and if so, he is taken to the player that used the command.
Posts: 2,528
Threads: 124
Joined: Jul 2009
Reputation:
0
Well, why won't you try to write it yourself? Then if you encounter some problems ask here for help, showing your code.
Posts: 98
Threads: 16
Joined: Jul 2017
Reputation:
0
That's how I want it
trazer = pull
CMD:trazer(playerid,params[])
{
new id;
if(sscanf(params, "d", id)) return SendClientMessage(playerid, -1, "[ ERRO ] /trazer [id]");
/*
And here, it sends a dialog pro id, and the id has the option to accept or not, if it accepts, it is taken to
the player who used the command!
*/
new nome[MAX_PLAYER_NAME] GetPlayerName(playerid, nome, sizeof(nome));
new str[128];
format(str, sizeof(str), "O jogador %s estб pedindo autorizaзгo para te puxa\nVocк aceita?, nome);
ShowPlayerDialog(id, DIALOG_PULL, DIALOG_STYLE_MSGBOX, "", str, "Sim","nгo");
return 1;
}
There in the dialogue, if he press yes, he is taken to the guy who sent the invitation, if not, he stays in place!
sorry for my english,
I'm going to take a course, I have to learn the most used language
Posts: 2,528
Threads: 124
Joined: Jul 2009
Reputation:
0
I have in mind a system where everybody can invite player and then he selects from a dialog or something which ones to accept, but that'd take a lot of time so we'll do version lite. It's lite - lite as we don't have y_dialog with y_inline.
1. Create a global array for all players, say: Invites[MAX_PLAYERS] = { -1, ... }
2. On /trazer set "Invites" for target player to inviter id
3. Show player "id" a dialog
4. OnDialogResponse if accepted teleport playerid to inviter id
5. Reset Invites on accept and on cancel
Of course it can be abused, because you can spam the other user with dialogs so I would not recommend it.
Posts: 98
Threads: 16
Joined: Jul 2017
Reputation:
0
no bro.
So: you and the id, I am the playerid, I sent an invitation to you asking if you accept I came to where I am, if you accept you come, otherwise it will not come!
Posts: 172
Threads: 19
Joined: Jun 2017
Reputation:
0
Thiago, kk vocк veio pedir ajuda aqui nos gringo pф?
kkasdasdkajsd
Mano usa uma variбvel global. isso й tudo, tipo tu precisa saber manipular as variбveis