#Module 'luasteam' not found

1 messages · Page 1 of 1 (latest)

mellow mural
#

It's crash when I launched the game, I download luasteam.dll and put it everywhere I could found, and it's no use. I unzip the game and copied a luasteam.dll or coding a luasteam.lua and it's contains

local o = require("luasteam")
return o

it's no use
I have love2d on my computer and it's version is 11.3

flat moon
#

i have the same issue and it might have to do with the fact that i had lua preinstalled on my machine. im on windows

flat moon
#

i managed to fix the issue, but unfortunately i cannot pinpoint exactly what finally helped, so i will list the things i did:

  • removing lua from environment variables and path. i had two entries there that had lua in the name. i deleted these links. in path there was a link to something/something/scoop. i deleted that too.
  • i searched for lua on my machine and found another game called project zomboid that had a lua directory in it. i deleted that one. (tho i dont think that made the difference)
  • i re-installed balatro
  • i did the verify integrity of game files within steam
  • restarted the pc

note that i didnt do them in that order necessarily, but i remember getting the error, doing a restart and then it worked (i obviously had tried restarting before but that alone didnt help) so my guess is that one of the steps before, combined with a restart did the trick.

upbeat marlin
#

I also had this problem with lua installed through scoop. Uninstalling it and restarting my PC fixed the problem.

mellow mural
#

I see

#

The game will using lua from scoop, but scoop doesn't has luasteam

upbeat marlin
#

Small PSA: You only have to remove the LUA_CPATH environment variable set by scoop

wispy gust
#

I've posted the same thing on Steam, people asked me to report it here as well. Hope it helps.

Note: I'm pretty sure my crashes are due to Lua5.1 installation being in path on my machine, as well as some libraries in system-wide LUA_PATH and LUA_CPATH, but if anyone encounters this nasty "luasteam not found" issue, here's what I did to fix it:

I've added these lines to main.lua around #L100 to "fix" the cpath (basically MacOS behavior, but with .dll instead of .so)

        else
            local dir = love.filesystem.getSourceBaseDirectory()
            local old_cpath = package.cpath
            package.cpath = package.cpath .. ';' .. dir .. '/?.dll'
            st = require 'luasteam'
            package.cpath = old_cpath
        end

After applying the fix, the game works as a folder with main.lua, as a .love file being open in stripped down Balatro.exe, and when being bundled into .exe and placed into the Balatro folder.

This is probably not something just anyone can do, but it might be helpful for those not willing to botch their lua/love2d dev machine.

Kudos to the developer, and hope this luasteam issue will be fixed in the official release. ❤️‍🔥

native flower
#

The game crashes for me with this error as well. Removing lua from LUA_PATH/LUA_CPATH would break other things for me, so it's not really an option. It'll be nice to have a step-by-step guide or a bug-fix.

languid oyster
#

I found that you can prepend the Balatro game directory path to the LUA_CPATH variable. This variable uses a special syntax where you need to wildcard the DLLs in the format ?.dll and also semicolon-delimit the paths (as @4aiman also uses) :

So, this would be C:\Program Files (x86)\Steam\steamapps\common\Balatro\?.dll;<whatever this value was originally>

Do it through the env var menu, or Powershell:

[System.Environment]::SetEnvironmentVariable('LUA_CPATH', "C:\Program Files (x86)\Steam\steamapps\common\Balatro\?.dll;" + [System.Environment]::GetEnvironmentVariable('LUA_CPATH', 'User'), 'User')

(Make sure to completely restart Steam afterwards: system tray -> right click Steam icon -> "Exit Steam")

But this stinks because there's no good reason you'd want to search in this path for other general Lua development.