0 Üye ve 1 Ziyaretçi konuyu incelemekte.
Gelen gecene yetki satmazsan sorun cözülür
ekmek parası be abi çoluğum çocuğum ac halı kemiriyo
banTable = {}count = {}hak = 5dakika = 1function oyuncuYetkilimi(thePlayer, groupName) local accName = getAccountName ( getPlayerAccount ( thePlayer ) ) local group = aclGetGroup(groupName) return group and isObjectInACLGroup ("user."..accName, group)endfunction banla(banPointer, responsibleElement) local banner = getPlayerName( responsibleElement ) or "Console" if banner ~= "Console" then if oyuncuYetkilimi(responsibleElement, "Admin") or oyuncuYetkilimi(responsibleElement, "SuperModerator") then if not count[responsibleElement] then count[responsibleElement] = getTickCount() end if banTable[responsibleElement] > hak then banPlayer(responsibleElement, true, true, true) outputChatBox(banner.." #ff0000isimli admin sunucuda darbe yapma girişiminde bulunduğundan banlandı.", root, 255, 0, 0, true ) end if count[responsibleElement] then if (tonumber(getTickCount()) - tonumber(count[responsibleElement])) >= (dakika * 60000) then banTable[responsibleElement] = 0 end end if not banTable[responsibleElement] then banTable[responsibleElement] = 1 else banTable[responsibleElement] = banTable[responsibleElement] + 1 end end endendaddEventHandler ("onPlayerBan", getRootElement(), banla)
Herhangi bir server dosyasına koyabilirsin.(test etmedim çalışmayabilir.)KodbanTable = {}count = {}hak = 5dakika = 1function oyuncuYetkilimi(thePlayer, groupName) local accName = getAccountName ( getPlayerAccount ( thePlayer ) ) local group = aclGetGroup(groupName) return group and isObjectInACLGroup ("user."..accName, group)endfunction banla(banPointer, responsibleElement) local banner = getPlayerName( responsibleElement ) or "Console" if banner ~= "Console" then if oyuncuYetkilimi(responsibleElement, "Admin") or oyuncuYetkilimi(responsibleElement, "SuperModerator") then if not count[responsibleElement] then count[responsibleElement] = getTickCount() end if banTable[responsibleElement] > hak then banPlayer(responsibleElement, true, true, true) outputChatBox(banner.." #ff0000isimli admin sunucuda darbe yapma girişiminde bulunduğundan banlandı.", root, 255, 0, 0, true ) end if count[responsibleElement] then if (tonumber(getTickCount()) - tonumber(count[responsibleElement])) >= (dakika * 60000) then banTable[responsibleElement] = 0 end end if not banTable[responsibleElement] then banTable[responsibleElement] = 1 else banTable[responsibleElement] = banTable[responsibleElement] + 1 end end endendaddEventHandler ("onPlayerBan", getRootElement(), banla)