Server favourites buttons

Developer discussion of experimental fixes, changes, and improvements.

Moderators: Nexuiz Moderators, Moderators

Server favourites buttons

Postby Spaceman » Mon Jul 28, 2008 7:21 pm

Some buttons for the server menu screen to recall your favourite game types, servers, map names etc The dynamic buttons simply insert some text into the filter.

Get the dif here http://217.16.115.15/~blub/nexfiles/?page=file&file=07273961509a896440cea3ce466b9819

Image
Image

You need to add the following to your autoexec.cfg the lines below contains code for two different sets of buttons.
Code: Select all
//server select, favourites
set dmj_button0_width 0  // 0 = auto or any value > 0 is fixed width
set dmj_button0_label "Capture The Flag"  // the label on the button, if ="" then don't show this button
set dmj_button0_action "ctf"  // the text entered in to the filter
set dmj_button0_colour "1 0 0"  // the colour of the button, R G B, range 0 - 1

set dmj_button1_width 0
set dmj_button1_label "Death Match"
set dmj_button1_action "dm"
set dmj_button1_colour "0 1 0"

set dmj_button2_width 0
set dmj_button2_label "Key Hunt"
set dmj_button2_action "key"
set dmj_button2_colour "0 0 1"

// set dmj_button0_width 0
// set dmj_button0_label "Galt's"
// set dmj_button0_action "galt"
// set dmj_button0_colour "0 0 0"
//
// set dmj_button1_width 0
// set dmj_button1_label "{x}"
// set dmj_button1_action "{x}"
// set dmj_button1_colour "0 0 0"
//
// set dmj_button2_width 0
// set dmj_button2_label "Ninjaz"
// set dmj_button2_action "Ninjaz"
// set dmj_button2_colour "0 0 0"

The button label, colour, width and inserted text can be changed. A button can be hidden by making it's label="". The filter will change its width to fit the new buttons.

You can update the buttons by changing the above lines in autoexec.cfg then opening the game console and
Code: Select all
exec autoexec.cfg
menu_restart
Spaceman
Alien trapper
 
Posts: 264
Joined: Tue Aug 28, 2007 10:53 am

Postby dread » Mon Jul 28, 2008 10:59 pm

i need the SVN version for this or?
if not how do i get it to work? (where to place the .diff files?)
dread
Member
 
Posts: 45
Joined: Fri Oct 19, 2007 2:15 pm
Location: AT

Postby Mr. Bougo » Tue Jul 29, 2008 11:49 am

You should do svn diffs, that makes one file per patch, instead of a bunch of diffs that you have to use one after the other...
Mr. Bougo
Keyboard killer
 
Posts: 760
Joined: Mon Sep 10, 2007 3:29 pm

Postby [-z-] » Tue Jul 29, 2008 1:18 pm

Very cool. I've been waiting to see favorites added :). Any chance you can make another tab for 'bookmarking' them. Thus allowing private servers to be stored as well?
[-z-]
Site Admin and Nexuiz Ninja
 
Posts: 1794
Joined: Mon Nov 13, 2006 12:20 am
Location: Florida

Postby MirceaKitsune » Sun Sep 21, 2008 9:18 pm

I think the game officially needs to get a favorite servers list implemented. We can loose good servers we liked without one (unless we lake a list in notepad ourselves with the servers as a walkaround). So if there's any feature request for that it's +1 here. Anyway thanks for that patch, I should try it until then :)
MirceaKitsune
Keyboard killer
 
Posts: 593
Joined: Thu Aug 14, 2008 6:48 am
Location: Romania - Bucharest

Postby divVerent » Mon Sep 22, 2008 5:35 am

That exists now in svn, although without an interface (which I won't make - others should do something too).

Currently, you can add a server to the favorites or remove it by using the right mouse button or the INSERT key. The server will then appear at the top of the list, and be highlighted.

As for a dialog to add/remove servers - I'd like someone else to do that.

The engine side interface is a cvar net_slist_favorites, which contains a list of IP addresses with ports that are marked as favorites.
1. Open Notepad
2. Paste: ÿþMSMSMS
3. Save
4. Open the file in Notepad again

You can vary the number of "MS", so you can clearly see it's MS which is causing it.
divVerent
Site admin and keyboard killer
 
Posts: 3809
Joined: Thu Mar 02, 2006 4:46 pm
Location: BRLOGENSHFEGLE


Return to Nexuiz - Development

Who is online

Users browsing this forum: No registered users and 1 guest

cron