Bubble "Administrator"
#1

hello,

I want to add my server, that there is a Bubble over my head,
that is written Administrator.

How can I do that? But it only should be over my head.
Reply
#2

Код:
public OnPlayerUpdate(playerid)
{
	SetPlayerChatBubble(playerid,"Administrator", Color, 25, 10000)
 	return 1;
}
Reply
#3

thanks,

an how did i make that it only stay over my character?
Reply
#4

Код:
on the top of your gamemode

new Admin,

and this in onplayercommandtext

if(strcmp("/admin", cmdtextm, true, 10) == 0)
{
	if (IsPlayerAdmin(playerid) == 1) // for the Rcon admin
	{
		if (Admin == 0) return Admin = 1, SetTimer("OnPlayerUpdate", 10, 0); //starts the Admin Bubble
	}
	return 1;
}

and in OnPlayerUpdate

public OnPlayerUpdate(playerid)
{
	if (Admin == 1)
	{
		SetPlayerChatBubble(playerid,"Administrator", Color, 25, 10000)
	}
 	return 1;
}
i donґt tested it but i think it will work
Reply
#5

lol onplayerupdate is called thousands in a second.
Reply
#6

Neo.
Its possible to adjust it for my own admin sys too right-o?
Reply
#7

I tried to do this but Cant seem to work
Reply
#8

Quote:
Originally Posted by [ĦŁ₣
ЉǾǖŦĦЗŁΛẄ ]
Just create the label then use Attach3DTextLabelToPlayer, no need for OnPlayerUpdate

Edit: for your other question, just add the script into the admin system you are using and put the admin level variable in there, could be tricky if you are using a complex admin system but try and work it out :P
I made my own register+login+rank system+admin system
Isnt rly complex just kinda alot of codes
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)