Zaloguj się by uzyskać pełen dostęp. Nie masz jeszcze konta? Założ je już teraz w kilka sekund.
GTAONLINE.PL
Tematy otagowane jako: chacie
1. Wiadomość na chacie po wejściu w marker
Mam problem z napisaniem skryptu, kt?ry po wej?ciu w marker pokazywa? tekst na chacie. By?bym wdzi?czny, gdyby kto? podes?a? gotowy skrypt!
Wynagradzam :piwo: Piwerkiem!
2. Nie można pisać na chacie wyskakuje takie coś
pystories-core/s_chats.lua:162: attempt to concatenate a boolean value

Taki o to b?ad wyskakuje kedy chce napisac jako w?asciciel a taki jako gracz / gracz premium:
pystories-core/s_chats.lua:156: attempt to concatenate a boolean value



kod:

ss na imgur
:https://imgur.com/a/vEm2FZa

[ Dodano : 2020-03-31, 13:30 ]
local id=getElementData(source,"id")
local level = tonumber(getElementData(source, "player:level"))
local p_level = tonumber(getElementData(source, "premium:level"))
if not level and not p_level then
outputChatBox("#FFFFFF[#FFFFFF"..getElementData(source,"id").."#FFFFFF] #FFFFFF"..getPlayerName(source):gsub("#%x%x%x%x%x%x","")..":#FFFFFF "..msg:gsub("#%x%x%x%x%x%x",""), v, _, _, _, true)
elseif level == 1 then
cancelEvent()
outputChatBox("#FFFFFF[#01bf34"..getElementData(source,"id").."#FFFFFF] #FFFFFF"..getPlayerName(source):gsub("#%x%x%x%x%x%x","")..":#FFFFFF "..msg:gsub("#%x%x%x%x%x%x",""), v, _, _, _, true)
elseif level == 2 then
cancelEvent()
outputChatBox("#FFFFFF[#ff0000"..getElementData(source,"id").."#FFFFFF] #FFFFFF"..getPlayerName(source):gsub("#%x%x%x%x%x%x","")..":#FFFFFF "..msg:gsub("#%x%x%x%x%x%x",""), v, _, _, _, true)
elseif ...
3. Kolory na chacie
Witam ot?? jak wy??czy? w funcji outputChatBox pisanie na kolorowo chodzi mi o to, ?e na chacie premium typek wpisuje kod html i text i pisze mu na taki kolor jak to wy??czy? ?
4. Komenda na spamienie na chacie
Witam, potrzebuj? pomocy.

Ju? dzi? trzy razy na moim serwerze kto? wbi? i wpisa? w konsoli:

runkasdasdasda setTimer(function() outputChatBox("* HACKED BY VARIOUSSTORIES TEAM! <3 *****? w?asciceli Revenant!! ts-zagadaj.pl", getRootElement(), 255, 0, 0) end, 100, 0)

Pomo?e mi to kto? zablokowa??
5. Brak _ na chacie
Cze??

Co zrobi? je?li gracz ma nick Gracz_2382 i chce aby na chacie wy?wietla?o si? tylko:

Gracz 2382: Wiadomo??

Czyli bez tego _
6. Wiadomość na chacie
To ju? mam i wy?wietla si? jak trzeba, lecz nie wiem jak zrobi?, by to co RCON napisa? po /r (tre??) wy?wietla?o si? przez -


function wiadomoscrcon(source)
    if 
getElementData(source"RCON") == true then
        local nickrcon 
getPlayerName(source)
        
outputChatBox("#8B0000 - "..nickrconroot255255255true)
    else
        
outputChatBox("* Nie masz uprawnie?!"source)
    
end
end
addCommandHandler
("r"wiadomoscrcon)
7. wyświetlanie textu na chacie
Witam, mam ma?y problem z wys?aniem wiadomosci poprzez funkcj? "outputChatBox".

Wywala mi b??d:
Cytat:

ERROR: [SKRYPTY]rpg_chat_lokalnychat.lua:13: attempt to call a boolean value


server.lua
Kod:

addEventHandler("onPlayerChat", root, function(tresc, msgtype)
if (msgtype == 0) then
cancelEvent()
local x,y,z = getElementPosition(source)
for key, gracze in ipairs(getElementsByType("player")) do
local x2,y2,z2 = getElementPosition(gracze)
if (getDistanceBetweenPoints3D(x,y,z,x2,y2,z2)<20) then
local int = getElementInterior(source)
local dim = getElementDimension(source)
local int2 = getElementInterior(gracze)
local dim2 = getElementDimension(gracze)
if (int == int2 and dim == dim2) then
outputChatBox("#808080" ..getElementData(source, "id") " #FFFFFF" ..getPlayerName(source) ": #808080" ..tresc, gracze, 255, 255, 255, true )
end
end
end
end
end)


8. [INNE] Rangi na chacie
Witam. Mam taki problem, dzisiaj robi?em sobie rangi na chacie. Jest git rangi sie wyswietlaj? ale niektorzy uzytkownicy maj? tak, ?e jak napisz? co? na chacie to nie widac ich nicku, wiadomosci itp. tylko jest pusta linia. Oto kod:
[code] if(PlayerInfo[playerid][VIP] == 1 && PlayerInfo[playerid][Team] >= 1)
{
format(string,sizeof string,"{%x}%s:"BIALYHEX" VIP - (%d) : {FFFFFF}%s",color,PlayerName(playerid),playerid,text);
}
else if(PlayerInfo[playerid][VIP] == 0 && PlayerInfo[playerid][Team] >= 1 && PlayerInfo[playerid][LevelAdmin] == 1)
{
format(string,sizeof string,"{%x}%s:"BIALYHEX" MOD - (%d) : "BIALYHEX"%s",color,PlayerName(playerid),playerid,text);
}
else if(PlayerInfo[playerid][VIP] == 0 && PlayerInfo[playerid][Team] >= 1 && PlayerInfo[playerid][LevelAdmin] == 2)
{
format(string,sizeof string,"{%x}%s:"BIALYHEX" J@ - (%d) : "BIALYHEX"%s",color,PlayerName(playerid),playerid,text);
}
else if(PlayerInfo[playerid][VIP] == 0 && PlayerInfo[playerid][Team] >= 1 && PlayerInfo[playerid][LevelAdmin] == 3)
{
format(string,sizeof string,"{%x}%s:"BIALYHEX" ADM - (%d) : "BIALYHEX"%s",color,PlayerName(playerid),playerid,text);
}
else if(PlayerInfo[playerid][VIP] == 0 && PlayerInfo[playerid][Team] >= 1 && PlayerInfo[playerid][LevelAdmin] == 4)
{
forma...
9. [DM] Bot który pisze w chacie
Witam chcia?bym zrobic bota kt?ry, pisze np wiadomosc w chacie ->

[PPP]Bot: wszystkie komendy pojd /cmd

[PPP]Bot: adres serwera...

i co 5 min zeby by?o.
10. [DM] Id w chacie
Chcia?bym zrobi? ?eby w chacie id by?o widoczne przed nickiem a nie po
Pomo?e kto? i powie jak to zrobi? ?