Headtext over the Head
#1

How can i scripting this, that Players can make /headtext with different Colors we Blue, Yellow, Green, White, Red, Cyan?
Reply
#2

I Can Make For You ..
Reply
#3

Then give me the Command, it were be nice, because i dont have Idea how to make that i know with 3d text label but not other.
Reply
#4

pawn Код:
#define FILTERSCRIPT
#include <a_samp>
#include <zcmd>
#include <sscanf2>

new Text3D:MyLabel[MAX_PLAYERS];

stock AttachHeadColor(playerid, color, text[])
{
    new Float:x, Float:y, Float:z;
    GetPlayerPos(playerid, x, y, z);
    MyLabel[playerid] = Create3DTextLabel(text, color, x, y, z + 1.0, 10.0, 0);
    Attach3DTextLabelToPlayer(MyLabel[playerid], playerid, 0.0, 0.0, 1.0);
    return 1;
}
 
CMD:headtext(playerid, params[])
{
    new color[12], text[128];
    if (sscanf(params, "s[12]s[128]", color, text))
    {
        SendClientMessage(playerid, 0xAFAFAFFF, "USAGE: /headtext [color] [text]");
        return 1;
    }
    if (strcmp(color, "blue", true) == 0) AttachHeadColor(playerid, 0x0000FFFF, text);
    if (strcmp(color, "yellow", true) == 0) AttachHeadColor(playerid, 0xFFFF00FF, text);
    if (strcmp(color, "green", true) == 0) AttachHeadColor(playerid, 0x00FF00FF, text);
    if (strcmp(color, "white", true) == 0) AttachHeadColor(playerid, 0xFFFFFFFF, text);
    if (strcmp(color, "red", true) == 0) AttachHeadColor(playerid, 0xFF0000FF, text);
    if (strcmp(color, "cyan", true) == 0) AttachHeadColor(playerid, 0x33CCFFFF, text);
    SendClientMessage(playerid, 0xFFFF00FF, "Text attached to head (type /removetext to remove it).");
    return 1;
}

CMD:removetext(playerid, params[])
{
    Delete3DTextLabel(MyLabel[playerid]);
    SendClientMessage(playerid, 0xFFFF00FF, "Text removed.");
    return 1;
}
Reply
#5

What Text Should Attach in The Top Of The Head ??
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)