Jump to content

Verificar level dos membros de uma party


Th1Doose
 Share

Recommended Posts

if party.is_leader() then
	local warp = select("Teleportar","Abortar")
	if warp == 1 then
		local pids = {party.get_member_pids()}
		local notEnoughLevelMembers = {}
		local levelCheck = true
		for i, pid in next, pids, nil do
			q.begin_other_pc_block(pid)
			local canPass = false
			if pc.level < 75 then --LEVEL A MUDAR
				table.insert(notEnoughLevelMembers, pc.get_name())
				levelCheck = false
			end
			q.end_other_pc_block()
		end
		if not levelCheck then
			say("Este aqui é fraco e tem de ir upar:")
			for i, name in next, notEnoughLevelMembers, nil do
				say(color(1,1,0), "    "..name)
			end
			return
		end
		if levelCheck then
			-- Colocar código de entrar na dungeon, questflags e etc aqui
		end
	end	
end

Não mexo nisso há muito tempo por isso não testei

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...