LunaLua errors

Post here for help and support regarding LunaLua and SMBX2's libraries and features.

Moderator: Userbase Moderators

mariobrigade2018
Rocky Wrench
Rocky Wrench
Posts: 612
Joined: Wed May 24, 2023 7:00 pm
Flair: OK in coding who dreams of making a Mario game
Pronouns: he/him

LunaLua errors

Postby mariobrigade2018 » Sat Jul 01, 2023 12:36 pm

I tried to put some LunaLua things into The Invasion 2, but I get an error message.

Here's the Scripts:
viewtopic.php?t=26306 modernReserveItems.lua
viewtopic.php?t=26353 flutterjump.lua
viewtopic.php?t=21495 Twirl.lua
viewtopic.php?t=28174furyinventory.lua

And the Error:

Image

Hope this will give enough info to help me out.

Edit: All of the files work now, but I get this error every time I use the inventory.

Image

Any ideas?
Last edited by mariobrigade2018 on Sun Jul 02, 2023 1:36 pm, edited 1 time in total.

DRACalgar Law
Tweeter
Tweeter
Posts: 135
Joined: Sun Oct 16, 2022 3:59 pm
Flair: King of the Boss Makers
Pronouns: he/him
Contact:

Re: LunaLua errors

Postby DRACalgar Law » Sat Jul 01, 2023 2:33 pm

mariobrigade2018 wrote:
Sat Jul 01, 2023 12:36 pm
I tried to put some LunaLua things into The Invasion 2, but I get an error message.

Here's the Scripts:
viewtopic.php?t=26306 modernReserveItems.lua
viewtopic.php?t=26353 flutterjump.lua
viewtopic.php?t=21495 Twirl.lua
viewtopic.php?t=28174furyinventory.lua

And the Error:

Image

Hope this will give enough info to help me out.
Have you tried opening up the episode script and put

Code: Select all

local [lua script] = require("[lua script]")
So for example, try putting

Code: Select all

local modernReserveItems = require("modernreserveItems")
local flutterJump = require("flutterjump")
local Twirl = require("Twirl")
local furyinventory = require("furyinventory")

mariobrigade2018
Rocky Wrench
Rocky Wrench
Posts: 612
Joined: Wed May 24, 2023 7:00 pm
Flair: OK in coding who dreams of making a Mario game
Pronouns: he/him

Re: LunaLua errors

Postby mariobrigade2018 » Sun Jul 02, 2023 1:44 am

I forgot to update this, but I did put the local lua script code, and I put the scripts in a !globalscript folder and moving them out of there made only modernReserveItems.lua work. The rest act like they don't exist and furyinventory.lua is still giving me the error.


Image

Also how do I report bugs?

Emral
Cute Yoshi Egg
Cute Yoshi Egg
Posts: 9865
Joined: Mon Jan 20, 2014 12:58 pm
Flair: Phoenix

Re: LunaLua errors

Postby Emral » Sun Jul 02, 2023 5:27 am

mariobrigade2018 wrote:
Sun Jul 02, 2023 1:44 am
I forgot to update this, but I did put the local lua script code, and I put the scripts in a !globalscript folder and moving them out of there made only modernReserveItems.lua work. The rest act like they don't exist and furyinventory.lua is still giving me the error.
If you put scripts into an arbitrary subdirectory, you must adjust the require calls accordingly. In your case, "local furyInventory = require("!globalscript/furyinventory")". Do keep in mind that there are likely dependency paths that need to be adjusted as well, or if you put assets like images into a subfolder, those need adjustment as well.
mariobrigade2018 wrote:
Sun Jul 02, 2023 1:44 am
Also how do I report bugs?
Fastest way is the #smbx2 channel on the codehaus discord server.


Return to “LunaLua Help”

Who is online

Users browsing this forum: No registered users and 2 guests

SMWCentralTalkhausMario Fan Games GalaxyKafukaMarioWikiSMBXEquipoEstelari