[Ajuda] Cores { }
#1

Gente como eu posso adcionar cor no meu label?

PHP код:
COMMAND:criarlabel3(playeridparams[])
{
SendAdminText(playerid"/criarlabel3"params);
        if (
APlayerData[playerid][PlayerLevel] >= 3)
            {
           new 
Float:PosX,
               
Float:PosY,
               
Float:PosZ;
           new 
texto[256];
           new 
string[256];
                {
                   if(
sscanf(params"s[256]"texto)) return SendClientMessage(playerid0xFF0000FF"Use: /criarlabel3 [Texto]");
                   
GetPlayerPos(playeridPosXPosYPosZ);
                   
format(stringsizeof(string), "%s"texto);
                   
Create3DTextLabel(string0x00ff00ffPosXPosYPosZ40,0);
                   
format(stringsizeof(string), "Vocк criou um TextLabel com a mensagem: %s"texto);
                   
SendClientMessage(playerid0x00FF00FFstring);
               }    }
           return 
true;

Por exemplo eu digitar: /criarlabel3 {FFFF00}Alo
Reply
#2

Usando Hex code
PHP код:
{FFFFFF}Texto 
Reply
#3

Sim mais queria como eu disse, {FFFF99}Texto, eu poder adicionar varias cores..
Reply
#4

Sei que nгo vou estar te ajudando, mas tambйm tenho essa dъvida. A propуsito, nгo precisa usar o format nesse script, pois o sscanf jб irб guadar a string que vocк digitar dentro da variбvel texto.
Reply
#5

Ajudm ae galera?
Reply
#6

Quote:
Originally Posted by LuisFerreira
Посмотреть сообщение
Sim mais queria como eu disse, {FFFF99}Texto, eu poder adicionar varias cores..
Pode fazer isso tambйm {FFFF99}Texto{FFFFFF}Qualquer{00000}Aqui
Reply
#7

Vocкs nao entenderam vei.. tipo й pra criar label in-game, ae eu queria digitar assim la /criarlabel3 {COR}TEXTO, e no comando que citei nao da... ALGUEM?
Reply
#8

Espero ter ajudado.
PHP код:
#include <a_samp>
#include <sscanf2>
#include <zcmd>

#define DIALOG_LABEL 1 
PHP код:
public OnDialogResponse(playeriddialogidresponselistiteminputtext[])
{
    if(
dialogid == DIALOG_LABEL)
    {
        if(
response)
        {
            new 
Float:Pos[3];
            
GetPlayerPos(playeridPos[0], Pos[1], Pos[2]);
            
Create3DTextLabel(inputtext,-1Pos[0], Pos[1], Pos[2], 40.000);
            
SendClientMessage(playerid0x00FF80AA"Label Criado!");
        }
    }
    return 
1;

PHP код:
CMD:label(playerid)
{
    
ShowPlayerDialog(playerid,DIALOG_LABELDIALOG_STYLE_INPUT"Criacao de Label""Digite abaixo o texto e cores do seu Label""Criar""Cancelar");
    return 
1;

Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)