TextDrawSetString
#5

okay this is the full code:
it shows only the "pDrugs" and "pSeeds" because it's digits (%i)
but the skill doesn't show anything because it's (%s) because i don't want it as digits.

all this topic is talking about how to make TextDrawSetString to show strings as letters not digits.
or how to make it work for (%s) ??

pawn Код:
public OnGameModeInit()
{
    InvList = TextDrawCreate(27.500000, 181.999984, " ");
    TextDrawLetterSize(InvList, 0.396874, 1.191666);
    TextDrawAlignment(InvList, 1);
    TextDrawColor(InvList, -1);
    TextDrawSetShadow(InvList, 0);
    TextDrawSetOutline(InvList, 1);
    TextDrawBackgroundColor(InvList, 51);
    TextDrawFont(InvList, 1);
    TextDrawSetProportional(InvList, 1);
    return 1;
}

CMD:inv(playerid, params[])
{
    TextDrawShowForPlayer(playerid, InvList);
    return 1;
}
   
forward UpdateInventory(playerid);
public UpdateInventory(playerid)
{
    new string[128];
    new pskill[MAX_PLAYERS char];
   
    if(PlayerInfo[playerid][pSkill] == 1)
    {
        pskill[playerid] = Rapist;
    }

    format(string, sizeof string, "Skill: %s~n~Drugs: %i~n~Seeds: %i", pskill, PlayerInfo[playerid][pDrugs], PlayerInfo[playerid][pSeeds]);
    TextDrawSetString(InvList, string);
}
Reply


Messages In This Thread
TextDrawSetString - by AnonScripter - 16.12.2013, 07:43
Re: TextDrawSetString - by Sawalha - 16.12.2013, 09:15
Re: TextDrawSetString - by ]Rafaellos[ - 16.12.2013, 09:36
Re: TextDrawSetString - by Zex Tan - 16.12.2013, 12:05
Re: TextDrawSetString - by AnonScripter - 16.12.2013, 12:45
Re: TextDrawSetString - by ]Rafaellos[ - 16.12.2013, 13:29
Re: TextDrawSetString - by AnonScripter - 16.12.2013, 13:40
Re: TextDrawSetString - by newbie scripter - 16.12.2013, 13:47
Re: TextDrawSetString - by AnonScripter - 16.12.2013, 13:58
Re: TextDrawSetString - by newbie scripter - 16.12.2013, 14:20

Forum Jump:


Users browsing this thread: 3 Guest(s)