-- Set the interval at which the top group should be checked (in milliseconds)local check_interval = 43200000 -- 12 hours-- Set the initial value of the top group to an empty stringlocal top_group = ""-- Create a timer to check the top group every 12 hourssetTimer(function() -- Connect to the server and retrieve a list of groups local groups = getGroupsFromServer() -- Sort the groups by member count in descending order table.sort(groups, function(a, b) return a > b end) -- Get the current top group local current_top_group = next(groups) -- If the top group has changed, display a notification to all players if current_top_group ~= top_group then top_group = current_top_group outputChatBox("Top group: " .. top_group, 0, 255, 0) -- green text endend, check_interval, 0)-- Display the top group to all players at the end of the daysetTimer(function() outputChatBox("Top group: " .. top_group, 255, 255, 255) -- white textend, 86400000, 0) -- 1 day