Jump to content

Recommended Posts

Posted

Salut. Doresc sa adaug in /id - Skin: id la skin (Raritate)

Si imi da eroare.

                format(sstring, sizeof(sstring), "(ID %d) Nume: %s | Level: %d | Factiune: Civil | Skin: %d {781111}(%s){ffffff} | FPS: %d",i,giveplayer,GetPlayerScore(i), GetSkinType(skin), FPS2[i]);

ce e gresit?

Posted

imi da eroare la getskintype ca cica undefined symbol "skin"

 

YCMD:id(playerid, params[], help) {
    new names[64], giveplayer[25], x, sstring[180];
    if(sscanf(params, "s[64]", names)) return SCM(playerid, COLOR_GREY, "Syntax: {FFFFFF}/id <playerid/name>");
    if(strlen(names) > 24) return SCM(playerid, COLOR_GREY, "Player not connected.");
    if(IsNumeric(names)) {
        if(strval(names) >= 1000) return SCM(playerid, COLOR_GREY, "Player not connected.");
    }
    if(IsNumeric(names)) {
        if(x < 10) {
            if(strval(names) < 0 || strval(names) > 999) return SCM(playerid, COLOR_GREY, "Player not connected."); 
            new i = strval(names);
            if(!IsPlayerConnected(i))
                return SCM(playerid, COLOR_GREY, "Player not connected.");
            if(IsPlayerLogged[i] == 0) return SCM(playerid, COLOR_GREY, "Player not connected.");
            GetPlayerName(i, giveplayer, sizeof(giveplayer));
            new szRankk[180];
            if(PlayerInfo[i][pMember] != 0) format(szRankk, sizeof(szRankk), " (rank %d)", PlayerInfo[i][pRank]);
            if(GetPVarInt(i, "Cover") == 1) {
                format(sstring, sizeof(sstring), "(ID %d) Nume: %s | Level: %d | Factiune: Civil | Skin: %d {781111}(%s){ffffff} | FPS: %d",i,giveplayer,GetPlayerScore(i), GetSkinType(skin), FPS2[i]);
                SCM(playerid, COLOR_WHITE, sstring);
                return true;
            }
            new name[180];
            format(name, sizeof(name), "%s", GetName(i));
            new clan = PlayerInfo[i][pClan];                    
            if(clan != 0 && PlayerInfo[i][pTag] == 0) format(name, sizeof(name), "{%s}%s{FFFFFF}%s", ClanInfo[clan][clColor], ClanInfo[clan][clTag], GetName(i));
            else if(clan != 0 && PlayerInfo[i][pTag] == 1) format(name, sizeof(name), "%s{%s}%s{FFFFFF}", GetName(i), ClanInfo[clan][clColor], ClanInfo[clan][clTag]);                                
            if(PlayerInfo[playerid][pAdmin] > 0) {
                if(PlayerInfo[i][pSleeping] == 1 || AFKSeconds[i] >= 5) format(sstring, sizeof(sstring), "(ID %d) %s | Level: %d | Factiune: {%s}%s{FFFFFF}%s | Skin: %d {781111}(%s){ffffff} | FPS: %d {FFADAD}- [AFK: %d]",i,name,PlayerInfo[i][pLevel], ColorFaction[PlayerInfo[i][pMember]], FactionName(PlayerInfo[i][pMember]), szRankk, GetSkinType(skin), FPS2[i], AFKSeconds[i]);
                else format(sstring, sizeof(sstring), "(ID %d) %s | Level: %d | Factiune: {%s}%s{FFFFFF}%s | Skin: %d {781111}(%s){ffffff} | FPS: %d",i,name,PlayerInfo[i][pLevel], ColorFaction[PlayerInfo[i][pMember]], FactionName(PlayerInfo[i][pMember]), szRankk, GetSkinType(skin), FPS2[i]);
            }
            else format(sstring, sizeof(sstring), "(ID %d) %s | Level: %d | Factiune: {%s}%s{FFFFFF}%s | Skin: %d {781111}(%s){ffffff} | FPS: %d",i,name,PlayerInfo[i][pLevel], ColorFaction[PlayerInfo[i][pMember]], FactionName(PlayerInfo[i][pMember]), szRankk, GetSkinType(skin), FPS2[i]);
            SCM(playerid, COLOR_WHITE, sstring);                
            x++;
            return true;
        }
    }    
    foreach(Player, i) {
        if(IsPlayerConnected(i) && IsPlayerLogged[i] == 1) {                    
            if(strfind(GetNameEx(i), names, true) != -1) {
                if(x < 10) {
                    if(i == INVALID_PLAYER_ID) return SCM(playerid, COLOR_GREY, "Player not connected."); 
                    GetPlayerName(i, giveplayer, sizeof(giveplayer));
                    new szRankk[180];
                    if(PlayerInfo[i][pMember] != 0) format(szRankk, sizeof(szRankk), " (Rank %d)", PlayerInfo[i][pRank]);
                    if(GetPVarInt(i, "Cover") == 1) {
                        format(sstring, sizeof(sstring), "(ID %d) Nume: %s | Level: %d | Factiune: Civil | FPS: %d",i,giveplayer,GetPlayerScore(i), FPS2[i]);
                        SCM(playerid, COLOR_WHITE, sstring);
                        return true;
                    }
                    new name[180];
                    format(name, sizeof(name), "%s", GetName(i));
                    new clan = PlayerInfo[i][pClan];
                    if(clan != 0 && PlayerInfo[i][pTag] == 0) format(name, sizeof(name), "{%s}%s{FFFFFF}%s", ClanInfo[clan][clColor], ClanInfo[clan][clTag], GetName(i));
                    else if(clan != 0 && PlayerInfo[i][pTag] == 1) format(name, sizeof(name), "%s{%s}%s{FFFFFF}", GetName(i), ClanInfo[clan][clColor], ClanInfo[clan][clTag]);                                
                    if(PlayerInfo[playerid][pAdmin] > 0) {
                        if(PlayerInfo[i][pSleeping] == 1 || AFKSeconds[i] >= 5) format(sstring, sizeof(sstring), "(ID %d) %s | Level: %d | Factiune: {%s}%s{FFFFFF}%s | FPS: %d {FFADAD}- [AFK: %d]",i,name,PlayerInfo[i][pLevel], ColorFaction[PlayerInfo[i][pMember]], FactionName(PlayerInfo[i][pMember]), szRankk, FPS2[i], AFKSeconds[i]);
                        else format(sstring, sizeof(sstring), "(ID %d) %s | Level: %d | Factiune: {%s}%s{FFFFFF}%s | FPS: %d",i,name,PlayerInfo[i][pLevel], ColorFaction[PlayerInfo[i][pMember]], FactionName(PlayerInfo[i][pMember]), szRankk, FPS2[i]);
                    }
                    else format(sstring, sizeof(sstring), "(ID %d) %s | Level: %d | Factiune: {%s}%s{FFFFFF}%s | FPS: %d",i,name,PlayerInfo[i][pLevel], ColorFaction[PlayerInfo[i][pMember]], FactionName(PlayerInfo[i][pMember]), szRankk, FPS2[i]);
                    SCM(playerid, COLOR_WHITE, sstring);    
                    x++;
                }    
            }                                            
        }
    }
    if(x == 0) return SCM(playerid, COLOR_GREY, "Player not connected.");
    if(x == 10) SCM(playerid, COLOR_WHITE, "Au fost afisate doar primele 10 rezultate.");
    return true;
}

IsNumeric(const string[]) {
    for (new i = 0, j = strlen(string); i < j; i++) {
        if (string[i] > '9' || string[i] < '0') return false;
    }
    return true;
}

Posted

incearca 

 

YCMD:id(playerid, params[], help) {
    new names[64], giveplayer[25], x, sstring[180];
    if(sscanf(params, "s[64]", names)) return SCM(playerid, COLOR_GREY, "Syntax: {FFFFFF}/id <playerid/name>");
    if(strlen(names) > 24) return SCM(playerid, COLOR_GREY, "Player not connected.");
    if(IsNumeric(names)) {
        if(strval(names) >= 1000) return SCM(playerid, COLOR_GREY, "Player not connected.");
    }
    if(IsNumeric(names)) {
        if(x < 10) {
            if(strval(names) < 0 || strval(names) > 999) return SCM(playerid, COLOR_GREY, "Player not connected."); 
            new i = strval(names);
            new skin = GetPlayerSkin(i);
            if(!IsPlayerConnected(i))
                return SCM(playerid, COLOR_GREY, "Player not connected.");
            if(IsPlayerLogged[i] == 0) return SCM(playerid, COLOR_GREY, "Player not connected.");
            GetPlayerName( , giveplayer, sizeof(giveplayer));
            new szRankk[180];
            if(PlayerInfo[i][pMember] != 0) format(szRankk, sizeof(szRankk), " (rank %d)", PlayerInfo[i][pRank]);
            if(GetPVarInt(i, "Cover") == 1) {
                format(sstring, sizeof(sstring), "(ID %d) Nume: %s | Level: %d | Factiune: Civil | Skin: %d {781111}(%s){ffffff} | FPS: %d",i,giveplayer,GetPlayerScore(i), GetSkinType(skin), FPS2[i]);
                SCM(playerid, COLOR_WHITE, sstring);
                return true;
            }
            new name[180];
            format(name, sizeof(name), "%s", GetName(i));
            new clan = PlayerInfo[i][pClan];                    
            if(clan != 0 && PlayerInfo[i][pTag] == 0) format(name, sizeof(name), "{%s}%s{FFFFFF}%s", ClanInfo[clan][clColor], ClanInfo[clan][clTag], GetName(i));
            else if(clan != 0 && PlayerInfo[i][pTag] == 1) format(name, sizeof(name), "%s{%s}%s{FFFFFF}", GetName(i), ClanInfo[clan][clColor], ClanInfo[clan][clTag]);                                
            if(PlayerInfo[playerid][pAdmin] > 0) {
                if(PlayerInfo[i][pSleeping] == 1 || AFKSeconds[i] >= 5) format(sstring, sizeof(sstring), "(ID %d) %s | Level: %d | Factiune: {%s}%s{FFFFFF}%s | Skin: %d {781111}(%s){ffffff} | FPS: %d {FFADAD}- [AFK: %d]",i,name,PlayerInfo[i][pLevel], ColorFaction[PlayerInfo[i][pMember]], FactionName(PlayerInfo[i][pMember]), szRankk, GetSkinType(skin), FPS2[i], AFKSeconds[i]);
                else format(sstring, sizeof(sstring), "(ID %d) %s | Level: %d | Factiune: {%s}%s{FFFFFF}%s | Skin: %d {781111}(%s){ffffff} | FPS: %d",i,name,PlayerInfo[i][pLevel], ColorFaction[PlayerInfo[i][pMember]], FactionName(PlayerInfo[i][pMember]), szRankk, GetSkinType(skin), FPS2[i]);
            }
            else format(sstring, sizeof(sstring), "(ID %d) %s | Level: %d | Factiune: {%s}%s{FFFFFF}%s | Skin: %d {781111}(%s){ffffff} | FPS: %d",i,name,PlayerInfo[i][pLevel], ColorFaction[PlayerInfo[i][pMember]], FactionName(PlayerInfo[i][pMember]), szRankk, GetSkinType(skin), FPS2[i]);
            SCM(playerid, COLOR_WHITE, sstring);                
            x++;
            return true;
        }
    }    
    foreach(Player, i) {
        if(IsPlayerConnected(i) && IsPlayerLogged[i] == 1) {                    
            if(strfind(GetNameEx(i), names, true) != -1) {
                if(x < 10) {
                    if(i == INVALID_PLAYER_ID) return SCM(playerid, COLOR_GREY, "Player not connected."); 
                    GetPlayerName(i, giveplayer, sizeof(giveplayer));
                    new szRankk[180];
                    if(PlayerInfo[i][pMember] != 0) format(szRankk, sizeof(szRankk), " (Rank %d)", PlayerInfo[i][pRank]);
                    if(GetPVarInt(i, "Cover") == 1) {
                        format(sstring, sizeof(sstring), "(ID %d) Nume: %s | Level: %d | Factiune: Civil | FPS: %d",i,giveplayer,GetPlayerScore(i), FPS2[i]);
                        SCM(playerid, COLOR_WHITE, sstring);
                        return true;
                    }
                    new name[180];
                    format(name, sizeof(name), "%s", GetName(i));
                    new clan = PlayerInfo[i][pClan];
                    if(clan != 0 && PlayerInfo[i][pTag] == 0) format(name, sizeof(name), "{%s}%s{FFFFFF}%s", ClanInfo[clan][clColor], ClanInfo[clan][clTag], GetName(i));
                    else if(clan != 0 && PlayerInfo[i][pTag] == 1) format(name, sizeof(name), "%s{%s}%s{FFFFFF}", GetName(i), ClanInfo[clan][clColor], ClanInfo[clan][clTag]);                                
                    if(PlayerInfo[playerid][pAdmin] > 0) {
                        if(PlayerInfo[i][pSleeping] == 1 || AFKSeconds[i] >= 5) format(sstring, sizeof(sstring), "(ID %d) %s | Level: %d | Factiune: {%s}%s{FFFFFF}%s | FPS: %d {FFADAD}- [AFK: %d]",i,name,PlayerInfo[i][pLevel], ColorFaction[PlayerInfo[i][pMember]], FactionName(PlayerInfo[i][pMember]), szRankk, FPS2[i], AFKSeconds[i]);
                        else format(sstring, sizeof(sstring), "(ID %d) %s | Level: %d | Factiune: {%s}%s{FFFFFF}%s | FPS: %d",i,name,PlayerInfo[i][pLevel], ColorFaction[PlayerInfo[i][pMember]], FactionName(PlayerInfo[i][pMember]), szRankk, FPS2[i]);
                    }
                    else format(sstring, sizeof(sstring), "(ID %d) %s | Level: %d | Factiune: {%s}%s{FFFFFF}%s | FPS: %d",i,name,PlayerInfo[i][pLevel], ColorFaction[PlayerInfo[i][pMember]], FactionName(PlayerInfo[i][pMember]), szRankk, FPS2[i]);
                    SCM(playerid, COLOR_WHITE, sstring);    
                    x++;
                }    
            }                                            
        }
    }
    if(x == 0) return SCM(playerid, COLOR_GREY, "Player not connected.");
    if(x == 10) SCM(playerid, COLOR_WHITE, "Au fost afisate doar primele 10 rezultate.");
    return true;
}

IsNumeric(const string[]) {
    for (new i = 0, j = strlen(string); i < j; i++) {
        if (string[i] > '9' || string[i] < '0') return false;
    }
    return true;
}

Posted

C:\Users\Desktop\gm\gamemodes\EV.pwn(18801) : error 029: invalid expression, assumed zero
C:\Users\Desktop\gm\gamemodes\EV.pwn(18801) : warning 215: expression has no effect
C:\Users\Desktop\gm\gamemodes\EV.pwn(18801) : warning 215: expression has no effect
C:\Users\Desktop\gm\gamemodes\EV.pwn(18801) : error 001: expected token: ";", but found ")"
C:\Users\Desktop\gm\gamemodes\EV.pwn(18801) : error 029: invalid expression, assumed zero
C:\Users\Desktop\gm\gamemodes\EV.pwn(18801) : fatal error 107: too many error messages on one line

Compilation aborted.

Pawn compiler 3.10.8              Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.
 

Posted

Daca poate sa ma ajute cineva, ca nu prea le am cu scripting-ul. Si chiar vreau sa bag skin in /id. Multumesc!

Posted

Gata. Acum apare asa

(18801) : error 035: argument type mismatch (argument 1)
(18801) : error 035: argument type mismatch (argument 2)
Pawn compiler 3.10.8              Copyright (c) 1997-2006, ITB CompuPhase


2 Errors.
 

Posted
Just now, Daa said:

Gata. Acum apare asa

(18801) : error 035: argument type mismatch (argument 1)
(18801) : error 035: argument type mismatch (argument 2)
Pawn compiler 3.10.8              Copyright (c) 1997-2006, ITB CompuPhase


2 Errors.
 

a, scuze

GetPlayerName(i, giveplayer, sizeof(giveplayer));

Posted

Merge, doar ca acu nu apare raritatea skin-ului.

Cum pot modifica acest lucru?

167, 170, 188, 159, 260: "Rare";
228, 248, 264, 189, 185, 146: "Epic";
0, 104, 116, 164, 149, 293, 285, 289, 294: "Legendary";
93, 108, 171, 177, 217, 271: "Transcendent";
124, 187, 181, 241, 242, 292, 309: "Unique";

Acestea sunt skinurile.

image.png

Posted

format(sstring, sizeof(sstring), "(ID %d) %s | Level: %d | Factiune: {%s}%s{FFFFFF}%s | Skin: %d {781111}(%s){ffffff} | FPS: %d",i,name,PlayerInfo[i][pLevel], ColorFaction[PlayerInfo[i][pMember]], FactionName(PlayerInfo[i][pMember]), szRankk, skin, GetSkinType(skin), FPS2[i]);

  • 2 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.