SetPlayerChatBubble
#1

Hello, how can i make that only the player who shot a other player see the damage bubble and not all players when they stand near this person?

Код:
    new string[128];
  	format(string,sizeof(string),"-%.0f",amount);
	SetPlayerChatBubble(playerid, string, 0xFF0000FF, 100.0, 1500);
Reply
#2

Possibly under :-

Код:
public OnPlayerGiveDamage(playerid, damagedid, Float: amount, weaponid, bodypart)
{
Reply
#3

can you give me the code, i cant figure it out now. also that i only saw the bubble if i shot a player and not that other players see it when they stand near the player.
Reply
#4

First of all, why the fuck are you using "SetPlayerChatBubble" to display health/armour information?


You should use Create3DTextLabel instead.
Reply
#5

@Sgt. He's using it to show it for a breif amount of time, not permanently and using that function is more convenient than Create3DTextLabel.

@Blackzeur:
pawn Код:
public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid, bodypart)
{
    if(!IsPlayerConnected(playerid)) return 1;
    new string[128];
    format(string,sizeof(string),"-%.0f",amount);
    SetPlayerChatBubble(playerid, string, 0xFF0000FF, 100.0, 1500);
    return 1;
}
Reply
#6

@Sgt.TheDarkness and why the fuck ur are posting here if u don't know anything?
Reply
#7

I am not sure if it will works but test it
pawn Код:
public OnPlayerGiveDamage(playerid, damagedid, Float:amount, weaponid,bodypart)
{
        if(IsPlayerConnected(playerid))
        {
                New Float:X , Float:Y , Float:Z;
                string[128];
                GetPlayerPos(damagedid,X,Y,Z);
                format(string,sizeof(string),"-%.0f",amount);
                CreatePlayer3DTextLabel(playerid,string,COLOR_RED,X,Y,0.7,40.0);
            return 1;
        }
}
Reply
#8

Quote:
Originally Posted by Dubya
Посмотреть сообщение
@Sgt. He's using it to show it for a breif amount of time, not permanently and using that function is more convenient than Create3DTextLabel.

@Blackzeur:
pawn Код:
public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid, bodypart)
{
    if(!IsPlayerConnected(playerid)) return 1;
    new string[128];
    format(string,sizeof(string),"-%.0f",amount);
    SetPlayerChatBubble(playerid, string, 0xFF0000FF, 100.0, 1500);
    return 1;
}
Will that works if i want that when i shot the player i see the damage above hes head but nobody other player can see it?
Reply
#9

Quote:
Originally Posted by Blackazur
Посмотреть сообщение
Will that works if i want that when i shot the player i see the damage above hes head but nobody other player can see it?
All can see i guess.
Reply
#10

But how can i make that it cant see everyone? Just me?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)