Skip to content

Commit b747b20

Browse files
committed
🚧 Disable font manager debug output
1 parent c70e4a8 commit b747b20

File tree

1 file changed

+35
-35
lines changed

1 file changed

+35
-35
lines changed

src/systems/minecraft/fontManager.ts

Lines changed: 35 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -376,41 +376,41 @@ export class MinecraftFont {
376376
const { lines, backgroundWidth } = await computeTextWrapping(words, maxLineWidth)
377377
const width = backgroundWidth + 1
378378
const height = lines.length * 10 + 1
379-
// Debug output
380-
const wordWidths = words.map(word => this.getWordWidth(word))
381-
for (const word of words) {
382-
console.log(
383-
`${words.indexOf(word)} '${word.text.toString()}' width: ${
384-
wordWidths[words.indexOf(word)]
385-
}`
386-
)
387-
for (const span of word.styles) {
388-
console.log(
389-
`'${word.text.slice(span.start, span.end).toString()}' ${span.start}-${
390-
span.end
391-
} = `,
392-
span.style
393-
)
394-
}
395-
}
396-
console.log('Lines:', lines, 'CanvasWidth:', maxLineWidth)
397-
for (const line of lines) {
398-
console.log('Line', lines.indexOf(line), line.width)
399-
for (const word of line.words) {
400-
console.log(
401-
'Word',
402-
line.words.indexOf(word),
403-
`'${word.text.toString()}'`,
404-
word.styles.map(span => span.style),
405-
word.styles.map(
406-
span =>
407-
`${span.start}-${span.end} '${word.text
408-
.slice(span.start, span.end)
409-
.toString()}'`
410-
)
411-
)
412-
}
413-
}
379+
// // Debug output
380+
// const wordWidths = words.map(word => this.getWordWidth(word))
381+
// for (const word of words) {
382+
// console.log(
383+
// `${words.indexOf(word)} '${word.text.toString()}' width: ${
384+
// wordWidths[words.indexOf(word)]
385+
// }`
386+
// )
387+
// for (const span of word.styles) {
388+
// console.log(
389+
// `'${word.text.slice(span.start, span.end).toString()}' ${span.start}-${
390+
// span.end
391+
// } = `,
392+
// span.style
393+
// )
394+
// }
395+
// }
396+
// console.log('Lines:', lines, 'CanvasWidth:', maxLineWidth)
397+
// for (const line of lines) {
398+
// console.log('Line', lines.indexOf(line), line.width)
399+
// for (const word of line.words) {
400+
// console.log(
401+
// 'Word',
402+
// line.words.indexOf(word),
403+
// `'${word.text.toString()}'`,
404+
// word.styles.map(span => span.style),
405+
// word.styles.map(
406+
// span =>
407+
// `${span.start}-${span.end} '${word.text
408+
// .slice(span.start, span.end)
409+
// .toString()}'`
410+
// )
411+
// )
412+
// }
413+
// }
414414

415415
const backgroundGeo = new THREE.PlaneBufferGeometry(width, height)
416416
const backgroundMesh = new THREE.Mesh(

0 commit comments

Comments
 (0)