Permalink
Browse files

Fixed servers jumping around in server browser

  • Loading branch information...
1 parent 98c894d commit 3380a9ed52723d0f49d1e211e83e842229f7f44d @robotboy655 robotboy655 committed Sep 28, 2014
Showing with 5 additions and 3 deletions.
  1. +5 −3 garrysmod/html/js/menu/control.Servers.js
@@ -75,13 +75,14 @@ function ControllerServers( $scope, $element, $rootScope, $location )
$scope.ChangeOrder = function( gm, order )
{
- if ( gm.OrderBy == order )
+ if ( gm.OrderByMain == order )
{
gm.OrderReverse = !gm.OrderReverse;
return;
}
- gm.OrderBy = order;
+ gm.OrderByMain = order;
+ gm.OrderBy = [order, 'recommended', 'ping', 'address'];
gm.OrderReverse = false;
}
@@ -167,7 +168,8 @@ function GetGamemode( name, type )
servers: [],
num_servers: 0,
num_players: 0,
- OrderBy: 'recommended',
+ OrderByMain: 'recommended',
+ OrderBy: ['recommended', 'ping', 'address'],
info: GetGamemodeInfo( name )
};

0 comments on commit 3380a9e

Please sign in to comment.