quest gm_painel begin
state start begin
when letter with pc.is_gm() begin
send_letter("GM")
end
when button or info begin
local senha_secreta = "12345"
say_title("GM")
say("Seleciona uma Opção:")
local principal = select("Eventos", "Bloqueamentos", "Fechar")
if principal == 1 then
say_title("Eventos")
say("Seleciona uma Opção:")
local eventos = select("Evento OX", "Fechar")
if eventos == 1 then
set_quest_state("ox_event","ox")
else
return
end
elseif principal == 2 then
say_title("Bloqueamentos")
say("Seleciona uma Opção:")
local opcao_ban = select("Bloquear Contas")
if opcao_ban == 1 then
say_title("Bloquear Contas")
say("Introduz o nome do jogador:")
local nome = input()
local encontrar_jogador = mysql_query("SELECT COUNT(*) FROM player.player WHERE name = '"..nome"'")
say_title("Bloquear Contas")
if nome = "" then
say("Introduz um nome.")
return
elseif nome == pc.get_name() then
say("Não podes fazer isso.")
return
elseif encontrar_jogador[1][1] == "0" then
say("O jogador "..nome.." não existe")
return
end
say_reward("Queres bloquear a conta do jogador "..nome.." ?")
if select("Sim","Não") == 2 then return end
say_title("Senha de Segurança")
say("Descrição")
local senha = input()
if senha == senha_secreta then
local encontrar_jogador_id = mysql_query("SELECT account_id FROM player.player WHERE name = '"..nome.."'")
local jogador_id = encontrar_jogador_id[1][1]
local verificar_ban = mysql_query("SELECT status FROM account.account WHERE id = '"..jogador_id.."'")
if verificar_ban[1][1] == "BLOCK" then
say_title("Bloquear Contas")
say("A conta do jogador "..nome.." já está bloqueada")
return
end
mysql_query("UPDATE account.account SET status = 'BLOCK' WHERE id = '"..jogador_id.."' LIMIT 1")
say_title("Bloquear Contas")
say_reward("A conta do jogador "..nome.." foi bloqueada.")
else
say_title("Senha Secreta")
say("A senha de segurança está incorreta.")
return
end
end
elseif principal == 3 then
return
end
end
end
end
Boas Pessoal.
Estou a ter um seguinte erro na quest
Porém, acho que tenho as coisas bem fechadas e não estou a conseguir ver onde está o problema..
Pastebin: http://pastebin.com/GRiLacW7
Código sem ser pastebin:
Spoiler (see edit history)
Share this post
Link to post
Share on other sites