3DText does not seem to work?
#1

Hello,

I try to create a /me command, everything works with SendClientMessage, but the 3DText don't show up.

Does someone got a clue?

pawn Код:
CMD:me(playerid, params[])
{
    new str2[128];
    if(sscanf(params, "s", str2))
    {
        SendClientMessage(playerid, 0xffffffff, "Usage: /me <action>");
        return 1;
    }
    else
    {
        new Float:px, Float:py, Float:pz;
        new message[150], pname[28];
        GetPlayerName(playerid, pname, sizeof(pname));
        format(message, sizeof(message), "** %s **", str2);
        SendClientMessage(playerid, 0xffffffff, message);
        me[playerid] = Create3DTextLabel(message,0xffffffff,30.0,40.0,50.0,40.0, 0, 0);
        Attach3DTextLabelToPlayer(me[playerid], playerid, 0.0, 0.0, 0.7);
        SetTimer("mecommand", 7000, false);
    }
    return 1;
}
I used the tut on the wiki.

Thanks alot.
Reply
#2

Better use: player chat bubble.
https://sampwiki.blast.hk/wiki/SetPlayerChatBubble
Reply
#3

I tried, the code doesn't give any errors, but I can't see the text above my head.

Is it true that only other people can see it?

Thanks for the help
Reply
#4

You can use 3DTextLabel, but you need to create it before you can attach it to a player
Reply
#5

Quote:
Originally Posted by dirkblok
Посмотреть сообщение
I tried, the code doesn't give any errors, but I can't see the text above my head.

Is it true that only other people can see it?

Thanks for the help
Yes. (8char) I'll be able to confirm it for you.
Reply
#6

Don't have the server online yet, sorry.

The 3DText was already created, read the code./
Reply
#7

you can't read the 3d text that is attached to yourself (or is it just for me?)
Reply
#8

Quote:
Originally Posted by Sniperwolves
Посмотреть сообщение
you can't read the 3d text that is attached to yourself (or is it just for me?)
You can't read 3DTexts that are attached to you but others can.
Reply
#9

Alright thanks for all the help
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)