I want to make a terminal similar to Liko-12 or other fantasy consoles.
please tell me how to do pixel terminal emulator
Or at least tell me how to make a matrix of characters, thanks!
How to make terminal in love2d
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
Re: How to make terminal in love2d
Already trying this for a roguelike so i give an advice...
If i print a buffer of characters 30x20 character with love.graphics.rectangle for filling the background color and love.graphics.print for printing the character with foreground color i see a drop down of FPS from 60 to 20. Must be because of the ttf font used i quessed and abandoned this solution.
Then i made a small tile of 16x16 pixels for background as empty white picture and foreground for a character that will be drawn over the background tile. The result again drops down to around 20 FPS.. what the heck right?
So i split the drawing and first i draw the 30x20 tiles for background. Then 30x20 tiles for foreground. FPS stays at 60 with vsync on. Without vsync it goes to around 265.
EDIT: Ok, got it fixed even for ttf font. I did the split of drawing the background first 30x20 and then the 30x20 foreground characters and it stays at 60 FPS vsync or 300 FPS without vsync.
If you need only a console solution look here : https://github.com/tvbronswijk/love-console
If i print a buffer of characters 30x20 character with love.graphics.rectangle for filling the background color and love.graphics.print for printing the character with foreground color i see a drop down of FPS from 60 to 20. Must be because of the ttf font used i quessed and abandoned this solution.
Then i made a small tile of 16x16 pixels for background as empty white picture and foreground for a character that will be drawn over the background tile. The result again drops down to around 20 FPS.. what the heck right?
So i split the drawing and first i draw the 30x20 tiles for background. Then 30x20 tiles for foreground. FPS stays at 60 with vsync on. Without vsync it goes to around 265.
EDIT: Ok, got it fixed even for ttf font. I did the split of drawing the background first 30x20 and then the 30x20 foreground characters and it stays at 60 FPS vsync or 300 FPS without vsync.
If you need only a console solution look here : https://github.com/tvbronswijk/love-console
Re: How to make terminal in love2d
You can load a custom font to use with love.graphics.font
See wiki: https://love2d.org/wiki/love.graphics.newFont (example at bottom of page)
There are tons of free fonts on the internet, random example: https://www.dafont.com/8-bit-pusab.font
See wiki: https://love2d.org/wiki/love.graphics.newFont (example at bottom of page)
There are tons of free fonts on the internet, random example: https://www.dafont.com/8-bit-pusab.font
Re: How to make terminal in love2d
Very thanks!Rigachupe wrote: ↑Sat Aug 27, 2022 5:36 pm If you need only a console solution look here : https://github.com/tvbronswijk/love-console
Who is online
Users browsing this forum: Ahrefs [Bot], Google [Bot] and 4 guests