Fix nanoui maps (#12231)

* Fix nanoui

Makes nanoui map size independent.

I hope you guys realize I spent like several hours on this. All because some shitter decided he would use hardcoded variables for map size.

* Send the map assets
This commit is contained in:
clusterfack
2016-10-16 20:23:34 -05:00
committed by GitHub
parent ef504323a2
commit 8455e57862
4 changed files with 25 additions and 2 deletions

View File

@@ -88,8 +88,16 @@ NanoBaseCallbacks = function ()
});
});
$('#uiMapImage').attr('src', 'minimap_' + updateData['config']['mapZLevel'] + '.png');
$('#uiMapImage').attr('src', updateData['config']['mapName'] + updateData['config']['mapZLevel'] + '.png');
$('#uiMapImage').css('width', updateData['config']['worldmaxx']);
$('#uiMapImage').css('height', updateData['config']['worldmaxy']);
$('#uiMap').css('width', updateData['config']['worldmaxx']);
$('#uiMap').css('height', updateData['config']['worldmaxy']);
$('#uiMapContent').css('width', updateData['config']['worldmaxx']);
$('#uiMapContent').css('height', updateData['config']['worldmaxy']);
return updateData;
}
};