CrazyGhost 发表于 2024-9-24 00:17:26

翻译,保留原代码


--██████╗ ██████╗█████╗ ████████╗███████╗ █████╗ ████████╗  ███████╗██╗   ██╗███████╗███╗██╗████████╗ ██████╗
--██╔══██╗██╔══██╗██╔══██╗╚══██╔══╝██╔════╝██╔══██╗╚══██╔══╝  ██╔════╝██║   ██║██╔════╝████╗ ██║╚══██╔══╝██╔════╝
--██████╔╝██████╔╝██║██║   ██║   █████╗██║╚═╝   ██║     █████╗╚██╗ ██╔╝█████╗██╔██╗██║   ██║   ╚█████╗
--██╔═══╝ ██╔══██╗██║██║   ██║   ██╔══╝██║██╗   ██║     ██╔══╝   ╚████╔╝ ██╔══╝██║╚████║   ██║    ╚═══██╗
--██║   ██║██║╚█████╔╝   ██║   ███████╗╚█████╔╝   ██║     ███████╗╚██╔╝███████╗██║ ╚███║   ██║   ██████╔╝
--╚═╝   ╚═╝╚═╝ ╚════╝    ╚═╝   ╚══════╝ ╚════╝    ╚═╝     ╚══════╝   ╚═╝   ╚══════╝╚═╝╚══╝   ╚═╝   ╚═════╝


HUNK_AC.AntiTrigger = true
HUNK_AC.AntiTriggerReaction = 'logs' -- change it to ban after u configed this part well

HUNK_AC.ExcludeResources = {
    ['rcore_casino'] = true,
}

HUNK_AC.ExcludeEvents = {
    ['playerDropped'] = true,
    ['__cfx_internal:commandFallback'] = true,
    ['baseevents:enteringVehicle'] = true,
    ['baseevents:enteredVehicle'] = true,
    ['baseevents:leftVehicle'] = true,
    ['esx:playerLoaded'] = true,
    ['_chat:messageEntered'] = true,
    ['QBCore:Server:PlayerLoaded'] = true,
    ['QBCore:Server:OnPlayerUnload'] = true,
}

-- before using installac command you need to add every encoded resource here that you did not buy from tebex
HUNK_AC.EncodedScripts = {
    --['ascript'] = true, -- just an example
}

HUNK_AC.AntiSpamEvents = true
HUNK_AC.AntiSpamEventsMaxCall = 6
HUNK_AC.AntiSpamEventsCooldown = 2000 -- ms
-- this means an event can be only called 4 times maximum in 2 sec
-- if an event is called 5 times in 2 sec then it will detect player as spammer (cheater)
HUNK_AC.AntiSpamReaction = 'logs' -- just in case, after u are sure about it u can change it to kick/ban
HUNK_AC.WhitelistedEventsForSpam = {
    ['complete_hud:Ping'] = true, -- just an example
}

HUNK_AC.IgnoreSpamEventsWhenJoining = 10 -- anti spam system will be activated after 10 seconds player joined to server

-- this part requires good knowledge of development
HUNK_AC.UsingAdvancedAntiSpam = true
HUNK_AC.AdvancedAntiSpamEvents = {
    ['InteractSound_SV:PlayOnAll'] = { -- cheaters can spam this event for spamming noises on players
      maxCall = 3,
      cooldown = 5000, -- ms
      -- if a player calls this event more than 3 times in 5 sec then that he is a cheater
      reaction = 'ban'
    },
    ['InteractSound_SV:PlayWithinDistance'] = { -- cheaters can spam this event for spamming noises on players
      maxCall = 3,
      cooldown = 5000,
      reaction = 'ban'
    },
   
}


ChatGPT 发表于 2024-9-24 00:22:46

--██████╗ ██████╗█████╗ ████████╗███████╗ █████╗ ████████╗  ███████╗██╗   ██╗███████╗███╗██╗████████╗ ██████╗
--██╔══██╗██╔══██╗██╔══██╗╚══██╔══╝██╔════╝██╔══██╗╚══██╔══╝  ██╔════╝██║   ██║██╔════╝████╗ ██║╚══██╔══╝██╔════╝
--██████╔╝██████╔╝██║██║   ██║   █████╗██║╚═╝   ██║     █████╗╚██╗ ██╔╝█████╗██╔██╗██║   ██║   ╚█████╗
--██╔═══╝ ██╔══██╗██║██║   ██║   ██╔══╝██║██╗   ██║     ██╔══╝   ╚████╔╝ ██╔══╝██║╚████║   ██║    ╚═══██╗
--██║   ██║██║╚█████╔╝   ██║   ███████╗╚█████╔╝   ██║     ███████╗╚██╔╝███████╗██║ ╚███║   ██║   ██████╔╝
--╚═╝   ╚═╝╚═╝ ╚════╝    ╚═╝   ╚══════╝ ╚════╝    ╚═╝     ╚══════╝   ╚═╝   ╚══════╝╚═╝╚══╝   ╚═╝   ╚═════╝

HUNK_AC.AntiTrigger = true
HUNK_AC.AntiTriggerReaction = 'logs' -- 配置好这一部分后,将其更改为禁用

HUNK_AC.ExcludeResources = {
    ['rcore_casino'] = true,
}

HUNK_AC.ExcludeEvents = {
    ['playerDropped'] = true,
    ['__cfx_internal:commandFallback'] = true,
    ['baseevents:enteringVehicle'] = true,
    ['baseevents:enteredVehicle'] = true,
    ['baseevents:leftVehicle'] = true,
    ['esx:playerLoaded'] = true,
    ['_chat:messageEntered'] = true,
    ['QBCore:Server:PlayerLoaded'] = true,
    ['QBCore:Server:OnPlayerUnload'] = true,
}

-- 在使用 installac 命令之前,您需要在这里添加每个未从 tebex 购买的编码资源
HUNK_AC.EncodedScripts = {
    -- = true, -- 仅为示例
}

HUNK_AC.AntiSpamEvents = true
HUNK_AC.AntiSpamEventsMaxCall = 6
HUNK_AC.AntiSpamEventsCooldown = 2000 -- 毫秒
-- 这意味着一个事件在 2 秒内最多只能调用 4 次
-- 如果一个事件在 2 秒内调用 5 次,则会将玩家检测为垃圾信息发送者(作弊者)
HUNK_AC.AntiSpamReaction = 'logs' -- 以防万一,确保后可以将其更改为踢出/禁用
HUNK_AC.WhitelistedEventsForSpam = {
    ['complete_hud:Ping'] = true, -- 仅为示例
}

HUNK_AC.IgnoreSpamEventsWhenJoining = 10 -- 玩家加入服务器后 10 秒将激活反垃圾信息系统

-- 这一部分需要良好的开发知识
HUNK_AC.UsingAdvancedAntiSpam = true
HUNK_AC.AdvancedAntiSpamEvents = {
    ['InteractSound_SV:PlayOnAll'] = { -- 作弊者可以通过此事件在玩家上发送噪音
      maxCall = 3,
      cooldown = 5000, -- 毫秒
      -- 如果玩家在 5 秒内调用此事件超过 3 次,则他是作弊者
      reaction = 'ban'
    },
    ['InteractSound_SV:PlayWithinDistance'] = { -- 作弊者可以通过此事件在玩家上发送噪音
      maxCall = 3,
      cooldown = 5000,
      reaction = 'ban'
    },
}
页: [1]
查看完整版本: 翻译,保留原代码