deathAnimations.lua - make Mario's day worse!

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

Moderator: Userbase Moderators

Master of Disaster
Bit
Bit
Posts: 62
Joined: Sun Nov 28, 2021 9:29 am
Flair: Average Koopa Fan
Pronouns: he/him

deathAnimations.lua - make Mario's day worse!

Postby Master of Disaster » Mon Jul 15, 2024 1:50 pm

Hello there, I've been torturing Mario for a while and now it's time to release this library so you can join in on the fun
Introducing

deathAnimations.lua v1.0

Instead of dying the ordinary way with the ordinary (and boring) death effect, let the player react to their demise in unique ways!
This library overrides the normal death animation and lets you register your own instead.
You'll need some lua knowledge to register your own death animations!

To register a death animation, you'll need three functions:
- checkFunc(p): return true when the player has died to the desired source. You might need do some trickery with this
- tickFunc(p,data): onTick() equivalent. Use it to set values in the data table, which you can use to draw the death animation in
- drawFunc(p,data): onDraw() equivalent. Draw the death animation here, using values from the data table
(Note: data.deathTimer is reserved and counts up every frame, starting with 1. Don't forget to end an animation with deathAnimations.endAnimation(p))

Here are some examples (gone wrong):
Spoiler: show

You're gonna have a blast with this one, trust me
Image

Luigi made a shocking realization today
Image

[insert food joke]
Image

not even multiplayer is safe
Image
By the way, this library is multiplayer compatible! If you use respawnRooms.lua, you'll have to disable quick respawn though to get these animations.

Don't be as cruel as I am and credit me if you use this library.

interested? Then here's the download!
deathAnimations.lua v1.0

Pixelated_Perfection
Swooper
Swooper
Posts: 52
Joined: Fri Feb 25, 2022 1:23 pm
Pronouns: Any/All

Re: deathAnimations.lua - make Mario's day worse!

Postby Pixelated_Perfection » Mon Jul 15, 2024 5:34 pm

oh this looks amazing

ChromaNyan
Tweeter
Tweeter
Posts: 152
Joined: Sat Feb 17, 2018 5:32 pm

Re: deathAnimations.lua - make Mario's day worse!

Postby ChromaNyan » Mon Jul 15, 2024 7:32 pm

does this work with the basegame character graphics, or just the SMW costumes?

Pixelated_Perfection
Swooper
Swooper
Posts: 52
Joined: Fri Feb 25, 2022 1:23 pm
Pronouns: Any/All

Re: deathAnimations.lua - make Mario's day worse!

Postby Pixelated_Perfection » Tue Jul 16, 2024 11:34 am

ChromaNyan wrote:
Mon Jul 15, 2024 7:32 pm
does this work with the basegame character graphics, or just the SMW costumes?
it comes packaged for SMW graphics, but all it'd take to fix it for the default ones is a bit of image editing

Master of Disaster
Bit
Bit
Posts: 62
Joined: Sun Nov 28, 2021 9:29 am
Flair: Average Koopa Fan
Pronouns: he/him

Re: deathAnimations.lua - make Mario's day worse!

Postby Master of Disaster » Wed Jul 17, 2024 9:51 am

Pixelated_Perfection wrote:
Tue Jul 16, 2024 11:34 am

it comes packaged for SMW graphics, but all it'd take to fix it for the default ones is a bit of image editing
Yeah I originally wanted to also add a default costume image but then I realized that I am lazy and didn't. Hence there's also no dedicated death animation for Link in those cases, it's very much possible, I just couldn't be bothered lol

mariofan101+
Shy Guy
Shy Guy
Posts: 6
Joined: Sun Jan 09, 2022 1:55 pm
Pronouns: he/him

Re: deathAnimations.lua - make Mario's day worse!

Postby mariofan101+ » Wed Aug 07, 2024 9:06 pm

this script is crash bandicoot on mario

Pixelated_Perfection
Swooper
Swooper
Posts: 52
Joined: Fri Feb 25, 2022 1:23 pm
Pronouns: Any/All

Re: deathAnimations.lua - make Mario's day worse!

Postby Pixelated_Perfection » Thu Aug 08, 2024 9:37 am

mariofan101+ wrote:
Wed Aug 07, 2024 9:06 pm
this script is crash bandicoot on mario
Image

PizzaNoob
Fighter Fly
Fighter Fly
Posts: 43
Joined: Wed May 29, 2024 8:36 pm
Flair: I like to make comics!
Pronouns: he/him

Re: deathAnimations.lua - make Mario's day worse!

Postby PizzaNoob » Tue Apr 15, 2025 3:32 pm

Is it possible to check if the player is colliding with a box made by easyLiquids.lua (by Akromaly). I'm having a hard time trying to check for the script's lava collider.

Alucard648
Tweeter
Tweeter
Posts: 165
Joined: Sun Aug 16, 2015 3:45 am

Re: deathAnimations.lua - make Mario's day worse!

Postby Alucard648 » Tue Apr 15, 2025 7:27 pm

This library is quite interesting. But I have to say, forbidden knowledge takes longer time to comprehend.


Return to “LunaLua”

Who is online

Users browsing this forum: No registered users and 0 guests

SMWCentralTalkhausMario Fan Games GalaxyKafukaMarioWikiSMBXEquipoEstelari