How do I answer a string?
#1

So right now I am working with my organization system, which is working properly. The problem is that I want another player to /accept my invitation when I invite them to the org.


Like: "A leader has invited you blablabla.. Write /accept to accept it, or /decline to decline.



Hope I explained good enough.


Btw: I dont want any big scripts to tell me how to do things, all I have to know is the function and how to use it properly.
Reply
#2

pawn Код:
// in /invite
SetPVarInt(THE_ID_YOU_INVITE, "Invite", 1);
pawn Код:
// in /accept
if(GetPVarInt(playerid, "Invite") != 0) {
    //blabla
    DeletePVar(playerid, "Invite");
    return 1;
}
pawn Код:
// in /decline
if(GetPVarInt(playerid, "Invite") != 0) {
    //blabla
    DeletePVar(playerid, "Invite");
    return 1;
}
Reply
#3

Okay, thanks!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)