File tree Expand file tree Collapse file tree 3 files changed +5
-14
lines changed
common/src/main/kotlin/com/lambda
graphics/renderer/gui/font/glyph Expand file tree Collapse file tree 3 files changed +5
-14
lines changed Original file line number Diff line number Diff line change @@ -45,14 +45,7 @@ object Loader {
4545 LOG .info(" Initializing ${Lambda .MOD_NAME } ${Lambda .VERSION } " )
4646
4747 val initTime = measureTimeMillis {
48- loadables.forEach { loadable ->
49- val info: String
50- val phaseTime = measureTimeMillis {
51- info = loadable.load()
52- }
53-
54- LOG .info(" $info in ${phaseTime} ms" )
55- }
48+ loadables.forEach { LOG .info(it.load()) }
5649 }
5750
5851 LOG .info(" ${Lambda .MOD_NAME } ${Lambda .VERSION } was successfully initialized (${initTime} ms)" )
Original file line number Diff line number Diff line change @@ -16,7 +16,6 @@ import javax.imageio.ImageIO
1616import kotlin.math.ceil
1717import kotlin.math.log2
1818import kotlin.math.sqrt
19- import kotlin.system.measureTimeMillis
2019import kotlin.time.Duration.Companion.days
2120
2221class EmojiGlyphs (zipUrl : String ) {
@@ -28,8 +27,8 @@ class EmojiGlyphs(zipUrl: String) {
2827
2928 init {
3029 runCatching {
31- val time = measureTimeMillis { downloadAndProcessZip(zipUrl) }
32- LOG .info(" Loaded ${emojiMap.size} emojis in $time ms " )
30+ downloadAndProcessZip(zipUrl)
31+ LOG .info(" Loaded ${emojiMap.size} emojis" )
3332 }.onFailure {
3433 LOG .error(" Failed to load emojis: ${it.message} " , it)
3534 fontTexture = MipmapTexture (BufferedImage (1024 , 1024 , BufferedImage .TYPE_INT_ARGB ))
Original file line number Diff line number Diff line change @@ -11,7 +11,6 @@ import java.awt.Font
1111import java.awt.Graphics2D
1212import java.awt.image.BufferedImage
1313import kotlin.math.max
14- import kotlin.system.measureTimeMillis
1514
1615class FontGlyphs (
1716 private val font : Font
@@ -23,8 +22,8 @@ class FontGlyphs(
2322
2423 init {
2524 runCatching {
26- val time = measureTimeMillis { processGlyphs() }
27- LOG .info(" Font ${font.fontName} loaded with ${charMap.size} characters in $time ms " )
25+ processGlyphs()
26+ LOG .info(" Font ${font.fontName} loaded with ${charMap.size} characters" )
2827 }.onFailure {
2928 LOG .error(" Failed to load font glyphs: ${it.message} " , it)
3029 fontTexture = MipmapTexture (BufferedImage (1024 , 1024 , BufferedImage .TYPE_INT_ARGB ))
You can’t perform that action at this time.
0 commit comments