explicitly specify encoding for char lookup of monospace font renderer to avoid errors

This commit is contained in:
Florian Nücke 2013-12-08 03:37:42 +01:00
parent b0e8e40317
commit 33a45493b8

View File

@ -12,7 +12,7 @@ import scala.io.Source
object MonospaceFontRenderer {
val font = new ResourceLocation(Settings.resourceDomain, "textures/font/chars.png")
private val chars = Source.fromInputStream(MonospaceFontRenderer.getClass.getResourceAsStream("/assets/" + Settings.resourceDomain + "/textures/font/chars.txt")).mkString
private val chars = Source.fromInputStream(MonospaceFontRenderer.getClass.getResourceAsStream("/assets/" + Settings.resourceDomain + "/textures/font/chars.txt"))("UTF-8").mkString
private var instance: Option[Renderer] = None