GM & FS
#1

this script is in my GM:

pawn Код:
CMD:kill( playerid, params[ ] )
{
if (InAFK[playerid] == 1)
{
    SendClientMessage(playerid, COLOR_RED, "You are Now in AFK/BRB Mode! Try /back to use this cmd!");
    return 1;
}
else
{
    if (InDM[playerid] == 0)
    {
        SetPlayerHealth(playerid, 0);
        GameTextForPlayer(playerid,"~r~~n~~n~~n~~n~~n~~n~Wasted Life!",3000,3);
    }
    else
    {
        SendClientMessage(playerid, 0xFF0000FF, "You cannot use this command while in DM. Use /leave to quit DM!");
    }
}
return 1;
}
And this in a FS:

pawn Код:
CMD:healme( playerid, params[ ] )
{
if (InAFK[playerid] == 1)
{
    SendClientMessage(playerid, COLOR_RED, "You are Now in AFK/BRB Mode! Try /back to use this cmd!");
    return 1;
}
else
{
    if(InDM[playerid] == 1)
        {
        SendClientMessage(playerid, 0xFF0000FF, "You cannot use this command while in DM. Use /leave to quit DM!");
        }
    else if(GetPlayerMoney(playerid) >= 1500)
        {
        SetPlayerHealth(playerid, 100);
        SetPlayerArmour(playerid, 100);
        GivePlayerMoney(playerid, -1500);
        SendClientMessage(playerid, 0xFFFF00FF, "You have just Bought Health & Armour with $1500!");
        }
    else
        {
        SendClientMessage(playerid, 0xFF0000FF, "You Dont have Enough cash $1500 to buy Health & Armour!");
        }
}
    return 1;
}
i want to know how to make InAFK & InDm work in both in GM and FS.....i only set InDM number in GM only but not in FS but i want to make it work in both.

How??
Reply
#2

by making your script ( inAFK & InDm ) in an include so after use it as native
Reply
#3

Well create a command for it in your FS too thats simple. I will give you an example in case of joining a dm.
pawn Код:
CMD:joindm(playerid, params[])
{
   if(InDM[playerid]) return SendClientMessage(playerid, -1, "You are already in DM");
   {
      InDM[playerid] = 1;
      // bla bla code you wanna add
    }
    return 1;
}
Hope you understood.
Reply
#4

Quote:
Originally Posted by Lacamora
Посмотреть сообщение
by making your script ( inAFK & InDm ) in an include so after use it as native
i dont know how to do that...

any tutorials are some thing..


please explain
Reply
#5

Just add the /healme command in your gamemode.
Reply
#6

Quote:
Originally Posted by Rittik
Посмотреть сообщение
Just add the /healme command in your gamemode.
i dont want to add it in GM..
Reply
#7

Then, add it to your FS if thats the thing you want. I gave you the example, see my prev post.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)