[POMOC]Iznad glave da pise[admin]

Započeo Dragan_Kesic, Februar 15, 2014, 08:55:47 PRE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Skripta koju koristim:edit UP-a
Detaljan opis problema:zanima me kako da pise [admin] iznad glave admina znam da ide setplayerchatbubble ali kako detaljnije mi objasnite? gde sta trebam da ubacim...
Dio skripte:dacu ako bude potrebno
Neke slike/video za lakse dobivanje pomoci(neobavezno):isto ko i za skriptu
Poslednja Izmena: Februar 15, 2014, 09:44:15 PRE PODNE od Dragan_Kesic

Ako te dobro razumem hoces da napravis kad je admin na duty da mu pise to sto zelis

U tom slucaju u komandu /aduty ili kako god ubaci
    SetPlayerChatBubble ( playerid, text, 0xFF0000FF, 100.0 , 10000 ) ;

I prilagodi tekst

[FS] Bank Sistem
[TuT] Array Sistem (Napredna)


"Pa krenite na mene i provesce te se super ko kapetan Kuka kada levom brise dupe"

www.denis-lapi.com

ne samo kad je na duty nego uopsteno celi vreme...

Napravi public (nazovi kako hoces) napravi forward i u public ubaci if sa uslovom i ako igrac zadovoljava onda da mu se pojavi chatbubble

[FS] Bank Sistem
[TuT] Array Sistem (Napredna)


"Pa krenite na mene i provesce te se super ko kapetan Kuka kada levom brise dupe"

www.denis-lapi.com

aj mi ti napravi ja cu ubaciti samo if tj proveru zato sto neznam bas oko pawna mnogo...

forward stavi kod drugih forwarda ne odmah iznad publica

forward AdminIme(playerid);
public AdminIme(playerid);
{
new string[265];
format(string, sizeof(string), "[ADMIN]\n");
SetPlayerChatBubble(playerid, string, 0xFF0000FF, 100.0, 1000000) ;
}

Pod publica


OnGameModeInit
{
AdminIme();
}


Citat: Horst:3 poslato Februar 15, 2014, 10:28:57 PRE PODNE
forward stavi kod drugih forwarda ne odmah iznad publica

forward AdminIme(playerid);
public AdminIme(playerid);
{
new string[265];
format(string, sizeof(string), "[ADMIN]\n");
SetPlayerChatBubble(playerid, string, 0xFF0000FF, 100.0, 1000000) ;
}

Pod publica


OnGameModeInit
{
AdminIme();
}


Malo si pogresio ne treba da stavi u "public OnGameModeInit" nego kod "public OnPlayerSpawn" :)


Kod forwarda:
forward ChatDouble();
Kod tajmera:
SetTimer("ChatDouble",3000,1);
Pri kraju skripte:
public ChatDouble()
{
foreach (Player, i)
{
if(AfkCheck[i] == 1)
{
SetPlayerChatBubble(i, "[ KORISTI ESCAPE MENI ]", COLOR_LIGHTGREEN, 40.0,4000);
}
if(PlayerInfo[i][pPromoter] == 1)
{
SetPlayerChatBubble(i, "[ S.G. PROMOTER ]", COLOR_YELLOW, 30.0,60000);
}
if(PlayerInfo[i][pAdmin] == 1)
{
SetPlayerChatBubble(i, "[ OSC ]", COLOR_BLACK, 30.0,60000);
}
else if(PlayerInfo[i][pGm] == 1)
{
SetPlayerChatBubble(i, "[ HELPER ]", SVETLOPLAVAA, 30.0,60000);
}
else if(PlayerInfo[i][pGm] == 2)
{
SetPlayerChatBubble(i, "[ HELPER ]", SVETLOPLAVAA, 30.0,60000);
}
else if(PlayerInfo[i][pGm] == 3)
{
SetPlayerChatBubble(i, "[ ZAMENIK V.HELPERA ]", SVETLOPLAVAA, 30.0,60000);
}
else if(PlayerInfo[i][pGm] == 4)
{
SetPlayerChatBubble(i, "[ VODJA HELPERA ]", SVETLOPLAVAA, 30.0,60000);
}
else if(PlayerInfo[i][pAdmin] == 2)
{
SetPlayerChatBubble(i, "[ OSC ]", COLOR_BLACK, 30.0,60000);
}
else if(PlayerInfo[i][pAdmin] == 3)
{
SetPlayerChatBubble(i, "[ OSC ]", COLOR_BLACK, 30.0,60000);
}
else if(PlayerInfo[i][pAdmin] == 4)
{
SetPlayerChatBubble(i, "[ OSC ]", COLOR_BLACK, 30.0,60000);
}
else if(PlayerInfo[i][pAdmin] == 5)
{
SetPlayerChatBubble(i, "[ OSC ]", COLOR_BLACK, 30.0,60000);
}
else if(PlayerInfo[i][pAdmin] == 6)
{
SetPlayerChatBubble(i, "[ OSC ]", COLOR_BLACK, 30.0,60000);
}
else if(PlayerInfo[i][pAdmin] == 1337)
{
SetPlayerChatBubble(i, "[ HEAD OSC ]", COLOR_BLACK, 30.0,60000);
}
else if(PlayerInfo[i][pAdmin] == 1338)
{
SetPlayerChatBubble(i, "[ DIREKTOR ]", COLOR_BLACK, 30.0,60000);
}
else if(PlayerInfo[i][pAdmin] == 1339)
{
SetPlayerChatBubble(i, "[ SUVLASNIK ]", COLOR_BLACK, 30.0,60000);
}
else if(PlayerInfo[i][pAdmin] == 1340)
{
SetPlayerChatBubble(i, "[ CO - VLASNIK ]", COLOR_BLACK, 30.0,60000);
}
else if(PlayerInfo[i][pAdmin] == 1341)
{
SetPlayerChatBubble(i, "[ VLASNIK ]", COLOR_BLACK, 30.0,60000);
}
else if(PlayerInfo[i][pVip] >= 1)
{
SetPlayerChatBubble(i, "[ DONATORSKI VIP ]", COLOR_RED, 30.0,60000);
}
else if(PlayerInfo[i][pLevel] == 3)
{
SetPlayerChatBubble(i, "[ Turista ]", COLOR_RED, 30.0,60000);
}
else if(PlayerInfo[i][pLevel] >= 40)
{
SetPlayerChatBubble(i, "[ Penzioner ]", COLOR_RED, 30.0,60000);
}
else if(PlayerInfo[i][pKazna] == 1)
{
SetPlayerChatBubble(i, "[ JA SAM KAZNJEN ]", COLOR_RED, 30.0,60000);
}
else if(PlayerInfo[i][pKazna] == 2)
{
SetPlayerChatBubble(i, "[ JA SAM KAZNJEN ]", COLOR_RED, 30.0,60000);
}
else if(GetPVarInt(i,"ESCTajmer") == 1)
{
SetPlayerChatBubble(i, "[ KORISTI ESCCAPE MENI ]", COLOR_LIGHTGREEN, 30.0,60000);
}
}
return 1;
}

if(PlayerInfo[playerid][pAdmin] >= 1)
ovako mi ide provera na moj mod
kad sam ubacio izbacilo mi neke erore da nije mozda zbog provere?

if(PlayerInfo[i][pAdmin] > 0)
{
SetPlayerChatBubble(i, "[ admin ]", -1, 30.0,60000);
}
stavi ovo pod OnPlayerUpdate

   /////////////////////////////////////////////////////////////////////////////////////
   if(PlayerInfo[playerid][pAdmin] > 1)
   {
    SetPlayerChatBubble(playerid, "[ ADMIN ]", -1, 30.0,60000);
    }
    ////////////////////////////////////////////////////////////////////////////////////////
    if(PlayerInfo[playerid][pAdmin] > 2)
   {
    SetPlayerChatBubble(playerid, "[ ADMIN ]", -1, 30.0,60000);
    }
    ////////////////////////////////////////////////////////////////////////////////////////
    if(PlayerInfo[playerid][pAdmin] > 3)
   {
    SetPlayerChatBubble(playerid, "[ ADMIN ]", -1, 30.0,60000);
    }
   /////////////////////////////////////////////////////////////////////////////////////////
    if(PlayerInfo[playerid][pAdmin] > 4)
   {
    SetPlayerChatBubble(playerid, "[ ADMIN ]", -1, 30.0,60000);
    }
    //////////////////////////////////////////////////////////////////////////////////////////
    if(PlayerInfo[playerid][pAdmin] > 5)
   {
    SetPlayerChatBubble(playerid, "[ SUVLASNIK ]", -1, 30.0,60000);
    }
    ///////////////////////////////////////////////////////////////////////////////////////////
    if(PlayerInfo[playerid][pAdmin] > 6)
   {
    SetPlayerChatBubble(playerid, "[ VLASNIK ]", -1, 30.0,60000);
    }
    ///////////////////////////////////////////////////////////////////////////////////////////
    if(PlayerInfo[playerid][pAdmin] > 7)
   {
    SetPlayerChatBubble(playerid, "[ SKRIPTER ]", -1, 30.0,60000);
    }
   ///////////////////////////////////////////////////////////////////////////////////////////
stavio sam ovo pod onplayerupdate,ali kad naprimer dam igracu admin lvl 1 pise suvlasnik dali neko zna sta bih trebao da uradim?
Poslednja Izmena: Februar 15, 2014, 12:22:23 POSLE PODNE od Dragan_Kesic

Na vrh moda stavi ovo:
//////////////////////////////////////////////////////////
#define COLOR_RED       0xFF0000
////////////////////////////////////////////////////////
Pod OnGameModeInit stavi ovo:
///////////////////////////////////////////////////////
SetTimer("ChatDouble",3000,1);
////////////////////////////////////////////////////
A na dnu moda stavi ovo:
//////////////////////////////////////////////////
public ChatDouble()
{
foreach(Player,i)
{
if(PlayerInfo[pAdmin] == 1)
{
SetPlayerChatBubble(i, "[Admin level 1]", COLOR_RED, 30.0,60000);
}
if(PlayerInfo[pAdmin] == 2)
{
SetPlayerChatBubble(i, "[Admin level 2]", COLOR_RED, 30.0,60000);
}
else if(PlayerInfo[pAdmin] == 3)
{
SetPlayerChatBubble(i, "[Head Admin]", COLOR_RED, 30.0,60000);
}
else if(PlayerInfo[pAdmin] == 4)
{
SetPlayerChatBubble(i, "[Direktor]", COLOR_RED, 30.0,60000);
}
else if(PlayerInfo[pAdmin] == 5)
{
SetPlayerChatBubble(i, "[Suvlasnik]", COLOR_RED, 30.0,60000);
}
else if(PlayerInfo[pAdmin] == 6)
{
SetPlayerChatBubble(i, "[Vlasnik]", COLOR_RED, 30.0,60000);
}
else if(PlayerInfo[pAdmin] == 7)
{
SetPlayerChatBubble(i, "[Skripter]", COLOR_RED, 30.0,60000);
}
else if(PlayerInfo[pGM] == 1)
{
SetPlayerChatBubble(i, "[GameMaster level 1]", COLOR_RED, 30.0,60000);
}
else if(PlayerInfo[pGM] == 2)
{
SetPlayerChatBubble(i, "[Head GameMaster]", COLOR_RED, 30.0,60000);
}
}
return 1;
}
///////////////////////////////////////////////////////////////////////////////////

To prilagodi svom modu :D
Trazim mapera :D

Ovako kad mu vec ne mozete pomoc nemojte mu ni odmagat, covjek trazi jednu stvar vi njemu dajete tonu stvari koje on ustvari ne trazi -.-

U neki tajmer (Ili koristi tajmer koji vec postoji - OnPlayerUpdate)
SetPlayerChatBubble(playerid, "[ADMIN]", -1, 30.0, 1000);

Edit: Blakes ti je vec dao.
Poslednja Izmena: Februar 15, 2014, 13:47:14 POSLE PODNE od Ermin.