print(text)
or
print('e')
And use lovec.exe so you can see the console.
How to run both love2d and lua
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 run both love2d and lua
Last project:
https://togfox.itch.io/hwarang
A card game that brings sword fighting to life.
Current project:
Turn-based PBEM horse stable (racing) management sim: https://togfox.itch.io/horse-stable-manager
https://discord.gg/HeHgwE5nsZ
https://togfox.itch.io/hwarang
A card game that brings sword fighting to life.
Current project:
Turn-based PBEM horse stable (racing) management sim: https://togfox.itch.io/horse-stable-manager
https://discord.gg/HeHgwE5nsZ
Re: How to run both love2d and lua
You can. You can use print() anywhere, even in love.draw(), love.update(), etc. What exactly you mean by @i can't use built-in lua functions with love"? You can't see output of "print()"? If that's the problem, then it's not "how to use built-in lua functions in love". Make sure that your ide or whatever you use was configured to output something.
Or, maybe, just maybe, you talking about output buffering, which will not send anything to terminal until game is closed?
try call io.stdout:setvbuf("no") (http://www.lua.org/manual/5.2/manual.ht ... %3asetvbuf) at start of your main.lua. After that love will send anything with "print()" immediately in terminal.
Re: How to run both love2d and lua
oops um that's a typo but I swear I tried it with the quotation mark and it didn't work eitherBrotSagtMist wrote: ↑Thu Aug 25, 2022 2:11 am You where trying it without quotation marks the whole time i must assume.
print('e') will absolutely work. print(e) will not...
Re: How to run both love2d and lua
Maybe you have problem with output buffering? Try adding to the top of main.lua
Code: Select all
io.stdout:setvbuf("no")
Who is online
Users browsing this forum: Bing [Bot] and 8 guests