Old GameSpy Query
Query old GameSpy servers, specifically, Command & Conquer: Renegade servers.
Usage
Example of querying every server.
require "old_gamespy_query"
require "pp"
@master_server = OldGameSpyQuery::MasterServer.new
@master_server.list.each do |addr|
begin
@data = OldGameSpyQuery::ServerData.new("#{addr}").get_server_data("players")
pp @data
rescue Timeout::Error
# Mask unresponsive servers
end
end
Note
Querying the master server requires 'gslist' and a modified version of gamespy_query. Also the 'gslist' executable needs to be in the same directory from where your executing your program. See http://aluigi.org/papers.htm#gslist.