Now I just need to know how to query the master server.
send (to master.tremulous.net:30710)
\xff\xff\xff\xffgetservers <protocol> [keywords]
\xff\xff\xff\xffgetserversExt <gamename> [keywords]
protocol is 69 for old, 70 for new
keywords is optionally "empty" and/or "full" (and/or "ipv6")
receive
\xff\xff\xff\xffgetserversResponse\\addrport...EOT\0\0\0
\xff\xff\xff\xffgetserversExtResponse/addrport...EOT\0\0\0
addr is packed (4 (or 16) bytes), port is packed (2 bytes) -- in php, you should able to use inet_ntop(addr), unpack("n",port)
packet ends with EOT\0\0\0, more packets may follow
(the master doesn't currently support IPv6 and when it does, there's no guarantee that the Ext forms will work as mentioned)
e.g.,
c->s \xff\xff\xff\xffgetservers 70 full empty
s->c \xff\xff\xff\xffgetserversResponse\x5cT\x9dc\x85x\x00\x5cb\xc1\xe5\xc4x\x00\x5cEOT\x00\x00\x00