avatar
Untitled

Guest 73 14th Apr, 2024

MARKUP 0.95 KB
                                           
                         --[[
    Script Name: 		Stop Bot on Player
    Description: 		Stop bot when player out of friends list is on screen else enable.
    Author: 			Ascer - example
]]

local FRIENDS = {"Dennis Rodman", "Wnz Wargod"}      -- friends nicks to avoid
local PAUSE_LUA_SCRIPTS = false             -- disable lua scripts too !WARRING script don't restore bot again, you will need to manually press Ctrl+P

-- DONT'T EDIT BELOW THIS LINE 

local list = table.lower(FRIENDS)

Module.New("Stop Bot on Player", function ()
	local players = Creature.iPlayers(7, false) -- get players on screen only
    for i = 1, #players do
        local player = players[i]
        if not table.find(list, string.lower(player.name)) then
            return Rifbot.setEnabled(false, PAUSE_LUA_SCRIPTS) -- disable player when player on screen.
        end
    end
    Rifbot.setEnabled(true) -- enable bot not players found
end)
                      
                                       
To share this paste please copy this url and send to your friends
RAW Paste Data
Recent Pastes
Ta strona używa plików cookie w celu usprawnienia i ułatwienia dostępu do serwisu oraz prowadzenia danych statystycznych. Dalsze korzystanie z tej witryny oznacza akceptację tego stanu rzeczy.
Wykorzystywanie plików Cookie
Jak wyłączyć cookies?
ROZUMIEM