CHS.lua - Custom Health and more! [v1.3]

Share and discuss custom LunaLua code and content packs for SMBX2.

Moderator: Userbase Moderators

AlanLive2020
Buster Beetle
Buster Beetle
Posts: 98
Joined: Fri Nov 27, 2020 8:15 am
Flair: The guy with no social skills or self-esteem :')

Re: SmgLifeSystem.lua v1.1 - Custom Health and more! Now with icantswim.lua support!

Postby AlanLive2020 » Mon Jan 17, 2022 8:54 pm

marioman2007 wrote:
Mon Jan 17, 2022 8:49 pm
AlanLive2020 wrote:
Mon Jan 17, 2022 12:25 pm
There is some boolean text on the top left of the screen. Dunno if thats intentional or not. Anyway i deleted it.
at which line? can't seem to find that

AlanLive2020 wrote:
Mon Jan 17, 2022 12:25 pm
How do i make the coin reward from collecting a heart at full health add to anothercurrency.lua?
it already does that
1. Line 414
2. Doesn't seem to work, the custom currency counter doesn't increase, it just adds coins for 1ups.

Mal8rk
Snifit
Snifit
Posts: 217
Joined: Mon Oct 25, 2021 11:04 pm
Flair: English Speaking Spanish Speaker
Pronouns: He/Him
Contact:

Re: SmgLifeSystem.lua - Custom Health and more!

Postby Mal8rk » Thu Feb 17, 2022 11:06 am

Is there a way to make this work with SMW Mario and Luigi costume sprites? I saw some harmed SMW Mario and Luigi sprites, but they don't seem to be used in the code as far as I'm aware

Marioman2007
2025 Egg Hunter
2025 Egg Hunter
Posts: 544
Joined: Tue Aug 25, 2020 3:19 am
Flair: Dr. Bones
Pronouns: He/Him

Re: SmgLifeSystem.lua - Custom Health and more!

Postby Marioman2007 » Thu Feb 17, 2022 9:52 pm

POPME wrote:
Thu Feb 17, 2022 11:06 am
Is there a way to make this work with SMW Mario and Luigi costume sprites? I saw some harmed SMW Mario and Luigi sprites, but they don't seem to be used in the code as far as I'm aware
you need to modify the row used by the sheet as:

Code: Select all

SmgLifeSystem.HarmedSheetRow = {
        [CHARACTER_MARIO] = 3, [CHARACTER_LUIGI] = 1,
        [CHARACTER_PEACH] = 0, [CHARACTER_TOAD] = 1}
AlanLive2020 wrote:
Mon Jan 17, 2022 9:46 pm
2. Doesn't seem to work, the custom currency counter doesn't increase, it just adds coins for 1ups.
you need to set hijackDefaultCounter to true

Mal8rk
Snifit
Snifit
Posts: 217
Joined: Mon Oct 25, 2021 11:04 pm
Flair: English Speaking Spanish Speaker
Pronouns: He/Him
Contact:

Re: SmgLifeSystem.lua - Custom Health and more!

Postby Mal8rk » Wed Feb 23, 2022 9:52 am

Hey, I have another question, hope I'm not bothering

But how can I disable the false/true words on the top left of the screen?

Marioman2007
2025 Egg Hunter
2025 Egg Hunter
Posts: 544
Joined: Tue Aug 25, 2020 3:19 am
Flair: Dr. Bones
Pronouns: He/Him

Re: SmgLifeSystem.lua - Custom Health and more!

Postby Marioman2007 » Wed Feb 23, 2022 10:29 am

POPME wrote:
Wed Feb 23, 2022 9:52 am
But how can I disable the false/true words on the top left of the screen?
remove the line 414 "Text.print(icantswim_inWater,0,0)"
(sorry for that, but I'm too lazy to update the link just for one line lol)

RadMetalMarioSMIX
Buster Beetle
Buster Beetle
Posts: 87
Joined: Sat Mar 14, 2015 6:42 pm
Flair: What kind of grave is this?
Pronouns: he/him

Re: SmgLifeSystem.lua - Custom Health and more!

Postby RadMetalMarioSMIX » Sat Mar 05, 2022 6:23 pm

Could this also work with a Wario Land-esque episode?

Marioman2007
2025 Egg Hunter
2025 Egg Hunter
Posts: 544
Joined: Tue Aug 25, 2020 3:19 am
Flair: Dr. Bones
Pronouns: He/Him

Re: SmgLifeSystem.lua - Custom Health and more!

Postby Marioman2007 » Sat Mar 19, 2022 5:20 am

Version 1.2 is here!
This version mostly fixes some bugs.

Mal8rk
Snifit
Snifit
Posts: 217
Joined: Mon Oct 25, 2021 11:04 pm
Flair: English Speaking Spanish Speaker
Pronouns: He/Him
Contact:

Re: SmgLifeSystem.lua - Custom Health and more!

Postby Mal8rk » Wed Jun 15, 2022 8:37 am

Hey there, I have a question

Is it possible to trigger events depending on how much health you have? Like for example, an event that triggers if you are on 1 hp

Marioman2007
2025 Egg Hunter
2025 Egg Hunter
Posts: 544
Joined: Tue Aug 25, 2020 3:19 am
Flair: Dr. Bones
Pronouns: He/Him

Re: SmgLifeSystem.lua - Custom Health and more!

Postby Marioman2007 » Thu Jun 16, 2022 7:27 am

POPME wrote:
Wed Jun 15, 2022 8:37 am
Hey there, I have a question

Is it possible to trigger events depending on how much health you have? Like for example, an event that triggers if you are on 1 hp

Code: Select all

SmgLifeSystem.HealthCounter
Returns the current health of the player.

Marioman2007
2025 Egg Hunter
2025 Egg Hunter
Posts: 544
Joined: Tue Aug 25, 2020 3:19 am
Flair: Dr. Bones
Pronouns: He/Him

HUGE Update: CHS.lua - Custom Health and more! [v1.3]

Postby Marioman2007 » Tue Oct 11, 2022 6:44 am

Huge Update!

That's right an update just dropped, and a really huge one!
Changelog and download link are in the original post.
Enjoy!!


I hope there are no more bugs...


Return to “LunaLua”

Who is online

Users browsing this forum: BlueStaggo, Petal [Bot] and 6 guests

SMWCentralTalkhausMario Fan Games GalaxyKafukaMarioWikiSMBXEquipoEstelari