• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

OTClient GUILD ON LOOK

nicolasdasd

New Member
Joined
Feb 26, 2013
Messages
3
Reaction score
0
Hi, im looking for the info when you click on the player. Only says profession and lvl not the guild. Can u help me please?

i found this script, but i dont know how to install.. thanks

function getGuildMembersOnline(GuildId)
local players = {}
for _, pid in pairs(getPlayersOnline()) do
if getPlayerGuildId(pid) == tonumber(GuildId) then
table.insert(players, pid)
end
end
return #players > 0 and #players or 0
end

function getGuildMembers(GuildId)
local players,query = {},db.getResult("SELECT name FROM players WHERE rank_id IN (SELECT id FROM guild_ranks WHERE guild_id = " .. GuildId .. ");")
if (query:getID() ~= -1) then
repeat
table.insert(players,query:getDataString("name"))
until not query:next()
query:free()
end
return #players > 0 and #players or 0
end
Post automatically merged:

up
 
Last edited:
Top