Wysłany: 2016-01-17, 00:22
iWanted
Wiek: 30 Na forum: 4268 dni Posty: 26
Nick w MP: .QUENNY
Piwa : 366
Og?lnie to m?j pierwszy skrypt.
Jak zrobi?, aby komenda mc, ac by?a na wi?cej grup ni? jedna czyli.
mc nie tylko na moderatora, ale te? na admina i rcona?
addCommandHandler ( "mc" , function( plr , cmd , ...)
if isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( plr )), aclGetGroup ( "Moderator" )) then
if ... then
local msg = table . concat ({...}, " " )
for k , v in ipairs ( getElementsByType ( "player" )) do
if isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( v )), aclGetGroup ( "Moderator" )) then
outputChatBox ( "#006600M> #006600" .. getPlayerName ( plr ).. "#FFFFFF: " .. msg , v , 255 , 255 , 255 , true )
end
end
end
end
end )
addCommandHandler ( "ac" , function( plr , cmd , ...)
if isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( plr )), aclGetGroup ( "Admin" )) then
if ... then
local msg = table . concat ({...}, " " )
for k , v in ipairs ( getElementsByType ( "player" )) do
if isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( v )), aclGetGroup ( "Admin" )) then
outputChatBox ( "#FF0000A> #FF0000" .. getPlayerName ( plr ).. "#FFFFFF: " .. msg , v , 255 , 255 , 255 , true )
end
end
end
end
end )
addCommandHandler ( "rc" , function( plr , cmd , ...)
if isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( plr )), aclGetGroup ( "RCON" )) then
if ... then
local msg = table . concat ({...}, " " )
for k , v in ipairs ( getElementsByType ( "player" )) do
if isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( v )), aclGetGroup ( "RCON" )) then
outputChatBox ( "#660000R> #660000" .. getPlayerName ( plr ).. "#FFFFFF: " .. msg , v , 255 , 255 , 255 , true )
end
end
end
end
end )
Podpis
Wszystko ma swój początek i koniec
Więcej szczegółów
Wystawiono 1 piw(a):LELIK
Wysłany: 2016-01-17, 11:17
Emm
***** ***
Wiek: 32 Na forum: 3880 dni Posty: 3191
Nick w MP: Emm
Piwa : 6162
Administrator: Admin ma zawsze rację | REGULAMIN FORUM | REKLAMA/VIP | .
addCommandHandler ( "mc" , function( plr , cmd , ...)
if isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( plr )), aclGetGroup ( "Moderator" )) or isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( plr )), aclGetGroup ( "Admin" )) or isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( plr )), aclGetGroup ( "RCON" )) then
if ... then
local msg = table . concat ({...}, " " )
for k , v in ipairs ( getElementsByType ( "player" )) do
if isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( v )), aclGetGroup ( "Moderator" )) or isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( plr )), aclGetGroup ( "Admin" )) or isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( plr )), aclGetGroup ( "RCON" )) then
outputChatBox ( "#006600M> #006600" .. getPlayerName ( plr ).. "#FFFFFF: " .. msg , v , 255 , 255 , 255 , true )
end
end
end
end
end )
addCommandHandler ( "ac" , function( plr , cmd , ...)
if isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( plr )), aclGetGroup ( "Admin" )) or isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( plr )), aclGetGroup ( "RCON" )) then
if ... then
local msg = table . concat ({...}, " " )
for k , v in ipairs ( getElementsByType ( "player" )) do
if isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( v )), aclGetGroup ( "Admin" )) or isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( plr )), aclGetGroup ( "RCON" )) then
outputChatBox ( "#FF0000A> #FF0000" .. getPlayerName ( plr ).. "#FFFFFF: " .. msg , v , 255 , 255 , 255 , true )
end
end
end
end
end )
addCommandHandler ( "rc" , function( plr , cmd , ...)
if isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( plr )), aclGetGroup ( "RCON" )) then
if ... then
local msg = table . concat ({...}, " " )
for k , v in ipairs ( getElementsByType ( "player" )) do
if isObjectInACLGroup ( "user." .. getAccountName ( getPlayerAccount ( v )), aclGetGroup ( "RCON" )) then
outputChatBox ( "#660000R> #660000" .. getPlayerName ( plr ).. "#FFFFFF: " .. msg , v , 255 , 255 , 255 , true )
end
end
end
end
end )
Podpis
Użytkownik : 20.10.2015r
GTAO Member : 06.03.2016r
Support-Team : 20.01.2016r
Moderator : 30.03.2016r
Mod-Team : 08.10.2016r
Vice Admin : 04.05.2018r
Administrator : 03.05.2022r
[you]
! Koniecznie zapoznaj się z
regulaminem forum .
Pamiętaj, aby zawsze go przestrzegać, nie mniej ważne są również
regulaminy działów , w których się wypowiadasz!
Zamiast zakładać temat po kilka razy, bo jest usuwany przez
Administrację , przejrzyj regulamin i napisz poprawnie temat!
Sprawy z administracją możesz załatwiać anonimowo w
tym dziale .
Najważniejsze informacje od
Administracji możesz przeczytać
tutaj oraz
tutaj .
Wysłany: 2016-01-17, 14:13
iWanted
Wiek: 30 Na forum: 4268 dni Posty: 26
Nick w MP: .QUENNY
Piwa : 366
Podpis
Wszystko ma swój początek i koniec
Tagi: admin :: chat.
Anonymous
Na forum: 245 dni
Posty: 1
Anonymous Koniecznie zajrzyj na: