Help needed.
#1

I got a small issue, my administrators on duty got a red ShowPlayerMarker which I don't want to exist, could you please tell me how to remove it etc. + Sometimes when they go off duty they recieve the CJ skin - Possible to fix aswell?
pawn Код:
if(!strcmp(cmdtext, "/adminduty", true) || !strcmp(cmdtext, "/aduty", true)) // Original by LordMan, Modded 99% By CuervO_NegrO
    {
        if(IsPlayerConnected(playerid))
        {
            if(gPlayerLogged[playerid] == 0)
            {
                SendClientMessage(playerid, COLOR_GREY, "   You need to login first !");
                return 1;
            }
            if(PlayerInfo[playerid][pAdmin] >= 1)
            {
                if(PlayerInfo[playerid][pAdminDuty] == 0)
                {
                    PlayerInfo[playerid][pAdminDuty] = 1;
                    SetPlayerColor(playerid,0xFF000099);
                    format(string, sizeof(string),"AdmCmd: %s is now on Admin Duty", sendername);
                    ABroadCast(COLOR_LIGHTRED, string, 1);
                    SendMessage(COLOR_LIGHTRED, string, 1);
                    DutyLabel[playerid] = Create3DTextLabel("Admin On Duty \n Do NOT Attack",0xFF000099,0,0,0,50,-1,1);
                    Attach3DTextLabelToPlayer(DutyLabel[playerid], playerid, 0,0,0);
                    if(PlayerInfo[playerid][pAdmin] >= 5)
                    {
                        for(new i = 0; i < sizeof(CarInfo); i++)
                        {
                            SetVehicleParamsForPlayer(i,playerid,0,0);
                        }
                    }

                    if(PlayerInfo[playerid][pAdmin] >= 3)
                    {
                        SetPlayerColor(playerid,0xFF000099); // Administrator Duty Color.
                        SetPlayerSkin(playerid, 240);
                        new Float:AX,Float:AY,Float:AZ;
                        GetPlayerPos(playerid, AX,AY,AZ);
                        SafeSetPlayerPos(playerid, AX,AY,AZ+1);
                        UpdatePlayerPosition(playerid);
                        SetPlayerHealth(playerid, 99999);
                        SetPlayerArmour(playerid, 99999);
                    }
                    if(PlayerInfo[playerid][pAdmin] >= 6)
                    {
                        SaveGuns(playerid);
                        SafeResetPlayerWeapons(playerid);
                        SafeGivePlayerWeapon(playerid, 24, 10000);
                    }
                    return 1;
                }
                else if(PlayerInfo[playerid][pAdminDuty] == 1)
                {
                    if(PlayerInfo[playerid][pAdmin] >= 6)
                    {
                        if(Spectate[playerid] == 255)
                        {
                            SafeResetPlayerWeapons(playerid);
                            SetPlayerWeapons(playerid);
                        }
                        SetPlayerSkills(playerid);
                        SetPlayerHealth(playerid, PlayerInfo[playerid][pHealth]);
                        SetPlayerArmour(playerid, PlayerInfo[playerid][pArmour]);
                    }
                    Delete3DTextLabel(DutyLabel[playerid]);
                    PlayerInfo[playerid][pAdminDuty] = 0;
                    new originalskin = PlayerInfo[playerid][pChar];
                    SetPlayerSkin(playerid, originalskin);
                    new Float:X,Float:Y,Float:Z;
                    GetPlayerPos(playerid, X,Y,Z);
                    SafeSetPlayerPos(playerid, X,Y,Z+1);
                    SetPlayerToTeamColor(playerid);
                    format(string, sizeof(string),"AdmCmd: %s is now off Admin Duty", sendername);
                    ABroadCast(COLOR_LIGHTRED, string, 1);
                    SendMessage(COLOR_LIGHTED, string, 1);
                    new y, m, d;
                    new h,mi,s;
                    getdate(y,m,d);
                    gettime(h,mi,s);
                    format(string,sizeof(string), "(%d/%d/%d)[%d:%d:%d] %s [CMD] -> /adminduty",d,m,y,h,mi,s,sendername);
                    AdminLog(string);
                    return 1;
                }
            }
            else
            {
                SendClientMessage(playerid, COLOR_GREY, "** You're not an admin !");
                return 1;
            }
        }
        return 1;
    }
pawn Код:
public OnGameModeInit() // Do not add vehicles Above the next lines. - CuervO
{
    ShowPlayerMarkers(2);
The only ShowPlayerMarker I could find in the whole gamemode.
Reply
#2

SetPlayerColor(playerid,0x00000000);
Reply
#3

They gotta have a aduty color but I want the red dot on the map / minimap gone only.
Reply
#4

Anyone know?
Reply
#5

Bump
Reply
#6

pawn Код:
SetPlayerColor(playerid,0xFF000000);
Reply
#7

That will remove the players administration color aswell right? From what I am aware SetPlayerColor is used to set the nametag color.. I only want the code how I can remove the marker on the minimap / map
Reply
#8

Quote:
Originally Posted by HighPitchedVoice
Посмотреть сообщение
That will remove the players administration color aswell right? From what I am aware SetPlayerColor is used to set the nametag color.. I only want the code how I can remove the marker on the minimap / map
Wrong, it will do exactly what you wanted. Just try it out.
Reply
#9

What will set the players nametag then? Thanks for the help by the way.
Reply
#10

Check this for more info

https://sampwiki.blast.hk/wiki/Colors#Ch...d_player_color
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)