Permalink
Browse files

Added "Map Incompatible" thing

For Portal 2, CS:GO and L4D2 maps.
  • Loading branch information...
1 parent 40596e5 commit 6b3cc3864a6a573852452f90f823e4184914255e @robotboy655 robotboy655 committed Dec 7, 2014
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@@ -99,6 +99,12 @@ function ControllerNewGame( $scope, $element, $rootScope, $location )
lua.Run( 'ToggleFavourite( "' + m.Name + '" )' );
}
+ $scope.MapIcon = function ( m, cat )
+ {
+ if ( cat == "Left 4 Dead 2" || cat == "Portal 2" || cat == "CS: Global Offensive" ) { return "img/incompatible.png" }
+ return "asset://mapimage/" + m.Name
+ }
+
$scope.IsFavMap = function( m )
{
if ( m.Category == "Favourites" ) return true;
@@ -24,7 +24,7 @@
<li class="icon mapicon {{MapClass( map )}}" ng-repeat="map in category.maps | orderBy:'Name' | filter:SearchText" >
<img ng-click="FavMap( map )" class="{{FavMapClass( map )}} {{FavMapHover( map )}}" src="img/empty.png" />
- <img ng-click="ClickMap( map )" ng-src="asset://mapimage/{{map.Name}}" class="thumbnail" /><br />
+ <img ng-click="ClickMap( map )" ng-src="{{MapIcon( map, category.category )}}" class="thumbnail" /><br />
{{map.Name}}
</li>

0 comments on commit 6b3cc38

Please sign in to comment.