Ir para conteúdo

Pessoal do help ta floodando - AJUDEM NO SCRIPT? - REP+

Featured Replies

Postado
1 minuto atrás, EmersonADVOGADOsp disse:

Ok, obrigado. Infelizmente não tem

Se voce quiser testar, 

cria um bloco de notas dentro da xml/channels e coloca tudo isso dentro!

Spoiler

<?xml version="1.0" encoding="UTF-8"?>
<channels>
    <!-- README:
        0 - dynamic, reserved for guilds
        1 - always acts as Party channel, only "name" tag available
        3 - always acts as Rule Violations channel
        9 - acts as Help channel- clientsided message
        65535 - DO NOT CHANGE THE ID- only "name", "enabled", "active" and "logged" tags available
     -->
    <channel id="1" name="Party"/>
    <channel id="2" name="Administracao" access="3"/>
    <channel id="3" name="Reportar Bugs" logged="yes"/>
    
    
    <channel id="6" name="Trocas" level="8" muted="60" conditionId="3" conditionMessage="Aguarde 1 minuto para enviar mensagem novamente.">
        <vocation id="1-8"/>
    </channel>
    
    <channel id="9" name="Ajuda" level="200" muted="30" conditionId="6" conditionMessage="Aguarde 30 segundos para enviar uma mensagem novamente." logged="yes"/>
</channels>

 

  • Respostas 9
  • Visualizações 704
  • Created
  • Última resposta

Top Posters In This Topic

Most Popular Posts

  • @EmersonADVOGADOsp o meu funciona perfeitamente, afinal é o que eu uso no meu derivado de Narutibia 8.60, otx 1.3. Em fim, boa noite.  Fico feliz que tenha arrumado!    xD

Postado

@mateusmoretti a versão da distro dele é 1.x por isso a diferença. 

 

@EmersonADVOGADOsp use este:

Spoiler

local CHANNEL_HELP = 2 -- id do chat do help
local tempo = 1 -- tempo em minutos que o player irá ficar sem falar no help
local delay = Condition(CONDITION_CHANNELMUTEDTICKS, CONDITIONID_DEFAULT)
delay:setParameter(CONDITION_PARAM_SUBID, CHANNEL_ADVERTISING)
delay:setParameter(CONDITION_PARAM_TICKS, tempo*60*1000)

function onSpeak(player, type, message)
	local playerAccountType = player:getAccountType()
	if player:getCondition(CONDITION_CHANNELMUTEDTICKS, CONDITIONID_DEFAULT, CHANNEL_ADVERTISING) then
	player:sendCancelMessage("Você pode falar no Help a cada 1 minuto.")
	return false
end
if playerAccountType == ACCOUNT_TYPE_NORMAL and not(player:getGroup():getId() >= 2) then
	player:addCondition(delay)
end

	if type == TALKTYPE_CHANNEL_Y then
		if playerAccountType >= ACCOUNT_TYPE_TUTOR or getPlayerFlagValue(player, PlayerFlag_TalkOrangeHelpChannel) then
			type = TALKTYPE_CHANNEL_O
		end
	elseif type == TALKTYPE_CHANNEL_O then
		if playerAccountType < ACCOUNT_TYPE_TUTOR and not getPlayerFlagValue(player, PlayerFlag_TalkOrangeHelpChannel) then
			type = TALKTYPE_CHANNEL_RD
		end
	elseif type == TALKTYPE_CHANNEL_R1 then
		if playerAccountType < ACCOUNT_TYPE_GAMEMASTER and not getPlayerFlagValue(player, PlayerFlag_CanTalkRedChannel) then
			if playerAccountType >= ACCOUNT_TYPE_TUTOR or getPlayerFlagValue(player, PlayerFlag_TalkOrangeHelpChannel) then
				type = TALKTYPE_CHANNEL_O
			else
				type = TALKTYPE_CHANNEL_Y
			end
		end
	end
	return type
end

 

A diferença é que é menor sem aqueles comandos desnecessários, fácil de configurar o time. Huahsuahs, o seu erro era que você talvez não estava com o id do chat corretamente. Afinal o script está correto. haha

 

@Tópico movido para área correta, mas atenção da próxima vez! 

                                                              ezgif-1-98aab239f3.gif.1a897c9c3225228909e7b356a5cfb8e4.gif

Postado
Agora, KotZletY disse:

@mateusmoretti a versão da distro dele é 1.x por isso a diferença. 

 

@EmersonADVOGADOsp use este:

  Mostrar conteúdo oculto


local CHANNEL_HELP = 2 -- id do chat do help
local tempo = 1 -- tempo em minutos que o player irá ficar sem falar no help
local delay = Condition(CONDITION_CHANNELMUTEDTICKS, CONDITIONID_DEFAULT)
delay:setParameter(CONDITION_PARAM_SUBID, CHANNEL_ADVERTISING)
delay:setParameter(CONDITION_PARAM_TICKS, tempo*60*1000)

function onSpeak(player, type, message)
	local playerAccountType = player:getAccountType()
	if player:getCondition(CONDITION_CHANNELMUTEDTICKS, CONDITIONID_DEFAULT, CHANNEL_ADVERTISING) then
	player:sendCancelMessage("Você pode falar no Help a cada 1 minuto.")
	return false
end
if playerAccountType == ACCOUNT_TYPE_NORMAL and not(player:getGroup():getId() >= 2) then
	player:addCondition(delay)
end

	if type == TALKTYPE_CHANNEL_Y then
		if playerAccountType >= ACCOUNT_TYPE_TUTOR or getPlayerFlagValue(player, PlayerFlag_TalkOrangeHelpChannel) then
			type = TALKTYPE_CHANNEL_O
		end
	elseif type == TALKTYPE_CHANNEL_O then
		if playerAccountType < ACCOUNT_TYPE_TUTOR and not getPlayerFlagValue(player, PlayerFlag_TalkOrangeHelpChannel) then
			type = TALKTYPE_CHANNEL_RD
		end
	elseif type == TALKTYPE_CHANNEL_R1 then
		if playerAccountType < ACCOUNT_TYPE_GAMEMASTER and not getPlayerFlagValue(player, PlayerFlag_CanTalkRedChannel) then
			if playerAccountType >= ACCOUNT_TYPE_TUTOR or getPlayerFlagValue(player, PlayerFlag_TalkOrangeHelpChannel) then
				type = TALKTYPE_CHANNEL_O
			else
				type = TALKTYPE_CHANNEL_Y
			end
		end
	end
	return type
end

 

 

@Tópico movido para área correta, mas atenção da próxima vez! 

ai sim, poxa não sabia dessa diferença porem nunca tinha reparado sempre vi pelo channel kkkk

Emerson espero que o Ket ajudará você, e cara e zica nos scripts kkkk

Postado
  • Autor
19 minutos atrás, mateusmoretti disse:

não tem uma channels? bom então ai ferrou, porque todos os ots vem com um bloco de notas chamado Channels

mais espero que o pessoal possa te ajudar então!

Ok, obrigado. Infe

 

3 minutos atrás, KotZletY disse:

@mateusmoretti a versão da distro dele é 1.x por isso a diferença. 

 

@EmersonADVOGADOsp use este:

  Ocultar conteúdo


local CHANNEL_HELP = 2 -- id do chat do help
local tempo = 1 -- tempo em minutos que o player irá ficar sem falar no help
local delay = Condition(CONDITION_CHANNELMUTEDTICKS, CONDITIONID_DEFAULT)
delay:setParameter(CONDITION_PARAM_SUBID, CHANNEL_ADVERTISING)
delay:setParameter(CONDITION_PARAM_TICKS, tempo*60*1000)

function onSpeak(player, type, message)
	local playerAccountType = player:getAccountType()
	if player:getCondition(CONDITION_CHANNELMUTEDTICKS, CONDITIONID_DEFAULT, CHANNEL_ADVERTISING) then
	player:sendCancelMessage("Você pode falar no Help a cada 1 minuto.")
	return false
end
if playerAccountType == ACCOUNT_TYPE_NORMAL and not(player:getGroup():getId() >= 2) then
	player:addCondition(delay)
end

	if type == TALKTYPE_CHANNEL_Y then
		if playerAccountType >= ACCOUNT_TYPE_TUTOR or getPlayerFlagValue(player, PlayerFlag_TalkOrangeHelpChannel) then
			type = TALKTYPE_CHANNEL_O
		end
	elseif type == TALKTYPE_CHANNEL_O then
		if playerAccountType < ACCOUNT_TYPE_TUTOR and not getPlayerFlagValue(player, PlayerFlag_TalkOrangeHelpChannel) then
			type = TALKTYPE_CHANNEL_RD
		end
	elseif type == TALKTYPE_CHANNEL_R1 then
		if playerAccountType < ACCOUNT_TYPE_GAMEMASTER and not getPlayerFlagValue(player, PlayerFlag_CanTalkRedChannel) then
			if playerAccountType >= ACCOUNT_TYPE_TUTOR or getPlayerFlagValue(player, PlayerFlag_TalkOrangeHelpChannel) then
				type = TALKTYPE_CHANNEL_O
			else
				type = TALKTYPE_CHANNEL_Y
			end
		end
	end
	return type
end

 

A diferença é que é menor sem aqueles comandos desnecessários, fácil de configurar o time. Huahsuahs, o seu erro era que você talvez não estava com o id do chat corretamente. Afinal o script está correto. haha

 

@Tópico movido para área correta, mas atenção da próxima vez! 

Vou testar um momento

Agora, EmersonADVOGADOsp disse:

Ok, obrigado. Infe

 

Vou testar um momento

<channel id="7" name="Help" public="1" 

Esta certo, id 7 na linha do xml e no script da 7 tbm

consegui arumar era so colocar uma linha de mute que faltava, obrigado. 

se alguem tiver a mesma duvida e so por a linha

 

        player:addCondition(muted)

 

 

Participe da conversa

Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.

Visitante
Responder

Quem Está Navegando 0

  • Nenhum usuário registrado visualizando esta página.

Estatísticas dos Fóruns

  • Tópicos 96.9k
  • Posts 519.7k

Informação Importante

Confirmação de Termo