Jump to content

► Anonymous ◄

Uživatel
  • Příspěvků

    15
  • Registrován

  • Aktivní

Příspěvky posted by ► Anonymous ◄

  1.  

    Musíš to prohnat timerem nebo využít OnPlayerTake nebo GiveDamage což bude uspornější a text aktualizovat jinak máš ten kod celkově špatně pojatý když chvilku vydržíš napíšu ti zhruba jak na to

    new Text:TextDraw0[MAX_PLAYERS];
    public OnPlayerConnect( playerid ) { TextDrawShowForPlayer( playerid , Textdraw0[playerid] );
    public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid, bodypart)
    {
        new playerhp[41],
    	GetPlayerHealth(playerid,Float:HP);
    	format(playerhp,sizeof(playerhp),"%.1f %%",HP);
    	TextDrawSetString(Textdraw0[playerid], playerhp);
    	return 1;
    }
    // Plus si musíš přidat vytvoření textdrawu a upravit ho Textdraw0 přepsat na Textdraw[playerid] a vytvoření přesunout do connectu
    

    Ewwe nemohl bys mi to udělat ty ? ja nejsem až tak dobrej pawner jako ty.

    #include <a_samp>
    
    
    new Text:Textdraw0;
    new string[500];
    new Float:HP;
    
    
    
    
    public OnPlayerConnect(playerid)
    {
    Textdraw0 = TextDrawCreate(563.000000, 66.000000, "100.0 %%");
    TextDrawBackgroundColor(Textdraw0, 255);
    TextDrawFont(Textdraw0, 2);
    TextDrawLetterSize(Textdraw0, 0.300000, 1.000000);
    TextDrawColor(Textdraw0, -16776961);
    TextDrawSetOutline(Textdraw0, 1);
    TextDrawSetProportional(Textdraw0, 1);
    TextDrawSetString(Textdraw0,string);
    
    
    return 1;
    }
    
    
    public OnPlayerSpawn(playerid)
    {
    new playerhp[41],
    GetPlayerHealth(playerid,Float:HP);
    format(playerhp,sizeof(playerhp),"%.1f %%",HP);
    TextDrawSetString(Textdraw0, playerhp);   
    TextDrawShowForPlayer(playerid, Textdraw0);
    return 1;
    }
    

    Zkus, netestoval jsem to

     

    Error : D:\Documents and Settings\InSaNe_25_IcOn\Plocha\hp.pwn(30) : warning 219: local variable "GetPlayerHealth" shadows a variable at a preceding level

    D:\Documents and Settings\InSaNe_25_IcOn\Plocha\hp.pwn(30) : error 001: expected token: ";", but found "("
    D:\Documents and Settings\InSaNe_25_IcOn\Plocha\hp.pwn(30) : warning 215: expression has no effect
    D:\Documents and Settings\InSaNe_25_IcOn\Plocha\hp.pwn(30) : warning 203: symbol is never used: "GetPlayerHealth"
    Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
     
     
    1 Error.

    Prepáčte za spam ale nemá to byť takto ?

     

    #include <a_samp>
    #pragma tabsize 0
    new string[500];
    new HP;
    new Text:Textdraw0[MAX_PLAYERS];
     
    public OnPlayerConnect(playerid)
    {
    Textdraw0[playerid] = TextDrawCreate(563.000000, 66.000000, "100.0 %%");
    TextDrawBackgroundColor(Textdraw0[playerid], 255);
    TextDrawFont(Textdraw0[playerid], 2);
    TextDrawLetterSize(Textdraw0[playerid], 0.300000, 1.000000);
    TextDrawColor(Textdraw0[playerid], -16776961);
    TextDrawSetOutline(Textdraw0[playerid], 1);
    TextDrawSetProportional(Textdraw0[playerid], 1);
    TextDrawSetString(Textdraw0[playerid],string);
    return 1;
    }
     
     
    public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid, bodypart)
    {
        new playerhp[41];
    GetPlayerHealth(playerid,Float:HP);
    format(playerhp,sizeof(playerhp),"%.1f %%",HP);
    TextDrawSetString(Textdraw0[playerid], playerhp);
    return 1;
    }

     

     

     
  2. 
    #include <a_samp>
    
    
    new Text:Textdraw0;
    new string[500];
    new Float:HP;
    
    
    
    
    public OnPlayerConnect(playerid)
    {
    
    
    GetPlayerHealth(playerid,Float:HP);
    format(string,sizeof(string),"%.1f %%",HP);
    Textdraw0 = TextDrawCreate(563.000000, 66.000000, string);
    TextDrawBackgroundColor(Textdraw0, 255);
    TextDrawFont(Textdraw0, 2);
    TextDrawLetterSize(Textdraw0, 0.300000, 1.000000);
    TextDrawColor(Textdraw0, -16776961);
    TextDrawSetOutline(Textdraw0, 1);
    TextDrawSetProportional(Textdraw0, 1);
    TextDrawSetString(Textdraw0,string);
    
    
    return 1;
    }
    
    
    public OnPlayerSpawn(playerid)
    {
    TextDrawShowForPlayer(playerid, Textdraw0);
    return 1;
    }

    Prosím help .. jak sa spawnem tak mi spravy toto : 

     

    sa-mp-194.png

  3. Dúfam že funguje :)

     

     

     

    static Float:pP[3];
    static PortState[MAX_PLAYERS];
    
    public OnPlayerCommandText(playerid, cmdtext[])
    {
        if (strcmp("/ulozport", cmdtext, true, 10) == 0)
        {
            GetPlayerPos(playerid, pP[0], pP[1], pP[2]);
            return 1;
        }
        if (strcmp("/aport", cmdtext, true, 10) == 0)
        {
            if(PortState == 0) retunr SendClientMessage(playerid, -1, "Admin Port je vypnut");
        SetPlayerPos(playerid,pP[0],pP[1],pP[2]);
        return 1;
        }
        if (strcmp("/aporton", cmdtext, true, 10) == 0)
        {
            PortState[playerid] = 1;
        GetPlayerPos(playerid, pP[0], pP[1], pP[2]);
            return 1;
        }
        if (strcmp("/aportoff", cmdtext, true, 10) == 0)
        {
            PortState[playerid] = 0;
            return 1;
        }
        return 0;
    }

     

     

  4. Potrebuju pomoc s: RZE 7.4 Fake By QWER

    Dal sem si to na server a když napíšu /admins nebo hocijaký příkaž tak mi píše Server Unknown Command přidal sem tam jen Warpy a pár príkazu je to bez errorú.

    Prosím vás o pomoc

  5. //======================== Bonus príkazy ============================//

     

    Bonus Príkazy

    Obsahuje:

     

    Zivoty

    Balicek zbraní

    SetSkin

    Port k hráči

    JetPack

    WTF

    OMG

    LoL

    Hudba

    Nitro

    Dpč

    Jzs

     

    //==========================================================//

     

     

                                    Download : KLIK

     

    Download bude přidan po schválení :)

     

    Ja sem koko*

    prominte néé pomoc ale FilesCript ..

×
×
  • Create New...