Problems with Misc.score(number)

Post here for help and support regarding LunaLua and SMBX2's libraries and features.
baenyth
Koopa
Koopa
Posts: 16
Joined: Mon Sep 07, 2020 6:34 pm
Pronouns: she/her

Problems with Misc.score(number)

Postby baenyth » Mon Nov 09, 2020 12:55 am

I'm trying to use Misc.score(number) in my levels to set the score value, but they don't seem to work. I've tried using it in coroutines, in onTick(), and in onStart(). Here's how I encoded it:
Misc.score(18)
Misc.score(120)
But the score never changes. Is there something I'm doing wrong here?

Enjl
Cute Yoshi Egg
Cute Yoshi Egg
Posts: 9491
Joined: Mon Jan 20, 2014 12:58 pm
Flair: Orphion Egamalenitar Osmos IV, Esq.

Re: Problems with Misc.score(number)

Postby Enjl » Mon Nov 09, 2020 1:27 am

The feature was mistakenly documented when it didn't exist. It'll be in the next version, now that I've added it. For the time being you can manipulate SaveData._basegame.hud.score directly.


Return to “LunaLua Help”

Who is online

Users browsing this forum: cato and 2 guests