Super Flower.lua

This is the place for discussion and support for LunaLua and related modifications and libraries.

Moderator: Userbase Moderators

Forum rules
Before you make a topic/post, consider the following:
-Is there a topic for this already?
-Is your post on topic/appropriate?
-Are you posting in the right forum/following the forum rules?
TDK
Foo
Foo
Posts: 1440
Joined: Wed Nov 11, 2015 12:26 pm
Flair: Retired

Super Flower.lua

Postby TDK » Sat Jun 03, 2017 11:10 am

Did you ever wanted to have the super flower powerup in SMBX? No?
Well I made an API for it anyway.

To use the super flower API (don't worry it's really simple) :

1. First put everything in this folder into your level's folder.

2. Make a lunadll.lua file.

3. Then type in the lunadll.lua:
local super_flower = API.load("super_flower")

And that's it.

This replaces the SMB1 fire flower. However you can still use the SMB3 & SMW fire flower in the same level.

Here's a gif:
Image

Here's a level that uses this:


Download and enjoy:
https://www.mediafire.com/?j3qg370306gbjp3
Last edited by TDK on Mon Apr 23, 2018 5:05 pm, edited 4 times in total.

FireyPaperMario
Wart
Wart
Posts: 6206
Joined: Sat Sep 27, 2014 1:39 pm
Flair: 90's kid born in late 1993 ^_^"
Pronouns: He/Him
Contact:

Re: Super Flower API

Postby FireyPaperMario » Sat Jun 03, 2017 11:46 am

That's great in all... But the Big question is does it have to be a monochrome Mario sprite?

Snessy the duck
Birdo
Birdo
Posts: 2699
Joined: Sat Sep 20, 2014 6:04 am

Re: Super Flower API

Postby Snessy the duck » Sat Jun 03, 2017 11:49 am

MarioRPGExpert93 wrote:That's great in all... But the Big question is does it have to be a monochrome Mario sprite?
Pretty sure you can change it. Also, why exactly are you complaining since you love monocrome sprites so much?

FireyPaperMario
Wart
Wart
Posts: 6206
Joined: Sat Sep 27, 2014 1:39 pm
Flair: 90's kid born in late 1993 ^_^"
Pronouns: He/Him
Contact:

Re: Super Flower API

Postby FireyPaperMario » Sat Jun 03, 2017 12:02 pm

Snessy the duck wrote:
MarioRPGExpert93 wrote:That's great in all... But the Big question is does it have to be a monochrome Mario sprite?
Pretty sure you can change it. Also, why exactly are you complaining since you love monocrome sprites so much?
I'm not really complaining tbh. And you misspelled Monochrome btw

timocomsmbx2345
Nipper
Nipper
Posts: 852
Joined: Sat Feb 06, 2016 1:44 pm
Contact:

Re: Super Flower API

Postby timocomsmbx2345 » Sat Jun 03, 2017 1:06 pm

So tdk is theDinoKing?
Also, does the balls collect coins just like they do in SML?

ElectriKong
Fry Guy
Fry Guy
Posts: 4651
Joined: Mon Jun 06, 2016 4:32 pm
Flair: I have NO idea what to put here
Pronouns: he/him
Contact:

Re: Super Flower API

Postby ElectriKong » Sat Jun 03, 2017 1:11 pm

Get this guy on the 2.0 dev team, NOW.

PersonNamedUser
Birdo
Birdo
Posts: 2882
Joined: Fri Feb 27, 2015 8:07 pm

Re: Super Flower API

Postby PersonNamedUser » Sat Jun 03, 2017 2:54 pm

Wait, does this mean that, you can like, use this AND the fire flower in the same level?

TDK
Foo
Foo
Posts: 1440
Joined: Wed Nov 11, 2015 12:26 pm
Flair: Retired

Re: Super Flower API

Postby TDK » Sat Jun 03, 2017 3:29 pm

timocomsmbx2345 wrote:So tdk is theDinoKing?
Also, does the balls collect coins just like they do in SML?
Yes.
MosaicMario wrote:Wait, does this mean that, you can like, use this AND the fire flower in the same level?
Yes.

Image
MarioRPGExpert93 wrote:That's great in all... But the Big question is does it have to be a monochrome Mario sprite?
No, you can replace the graphics. For example if you want a different Mario sprite, you have to replace the "custom_mario-3.png" graphic.

Benial
Swooper
Swooper
Posts: 50
Joined: Thu Dec 15, 2016 4:28 pm
Flair: It's!
Pronouns: He/Him

Re: Super Flower API

Postby Benial » Sun Jun 04, 2017 4:42 am

Is this planned to effect all the 2.0 characters eventually?

ElectriKong
Fry Guy
Fry Guy
Posts: 4651
Joined: Mon Jun 06, 2016 4:32 pm
Flair: I have NO idea what to put here
Pronouns: he/him
Contact:

Re: Super Flower API

Postby ElectriKong » Sun Jun 04, 2017 4:46 am

Benial wrote:Is this planned to effect all the 2.0 characters eventually?
If he is in or going to be invited to the 2.0 dev team then probably.

yoshiegg
Hoopster
Hoopster
Posts: 122
Joined: Mon Jan 25, 2016 9:20 am

Re: Super Flower API

Postby yoshiegg » Mon Jun 05, 2017 10:29 am

Nice Work, Dude. You showed us a new possibility to create custom powerups without overwring existing ones.

Hoeloe
Foo
Foo
Posts: 1465
Joined: Sat Oct 03, 2015 6:18 pm
Flair: The Codehaus Girl
Pronouns: she/her

Re: Super Flower API

Postby Hoeloe » Mon Jun 05, 2017 10:49 am

yoshiegg wrote:Nice Work, Dude. You showed us a new possibility to create custom powerups without overwring existing ones.
This has always been possible but not without some hackery involved. Before we introduce new basegame powerups, we plan to ensure the methods for doing so are neat and polished, such that the visible difference between vanilla powerups and lua ones is minimised.

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

Re: Super Flower API

Postby Emral » Mon Jun 05, 2017 11:15 am

Didn't the balls bounce off coins in Super Mario Land?
https://youtu.be/EV0qJd-phvQ?t=68

TDK
Foo
Foo
Posts: 1440
Joined: Wed Nov 11, 2015 12:26 pm
Flair: Retired

Re: Super Flower API

Postby TDK » Mon Jun 05, 2017 11:32 am

Hoeloe wrote:
yoshiegg wrote:Nice Work, Dude. You showed us a new possibility to create custom powerups without overwring existing ones.
This has always been possible but not without some hackery involved. Before we introduce new basegame powerups, we plan to ensure the methods for doing so are neat and polished, such that the visible difference between vanilla powerups and lua ones is minimised.
^
It's just an illusion of a new powerup.

timocomsmbx2345
Nipper
Nipper
Posts: 852
Joined: Sat Feb 06, 2016 1:44 pm
Contact:

Re: Super Flower API

Postby timocomsmbx2345 » Mon Jun 05, 2017 7:39 pm

That is wonderful, can you do the boomerang flower next?

4matsy
Dolphin
Dolphin
Posts: 81
Joined: Fri Jan 10, 2014 11:42 pm
Pronouns: he/him

Re: Super Flower API

Postby 4matsy » Mon Jun 05, 2017 11:40 pm

Enjl wrote:Didn't the balls bounce off coins in Super Mario Land?
Sometimes they did, sometimes they didn't. It wasn't easy at all to tell which direction the ball would go after hitting a coin, especially in that one underground bonus room that was literally all coins (see the 4:30 mark here):


yoshiegg
Hoopster
Hoopster
Posts: 122
Joined: Mon Jan 25, 2016 9:20 am

Re: Super Flower API

Postby yoshiegg » Tue Jun 06, 2017 7:26 am

timocomsmbx2345 wrote:That is wonderful, can you do the boomerang flower next?
I think that isn't necessary as someone already made a boomerang flower that just works fine and that I use atm so here's the code:

Code: Select all

local BoomerangLock = 0

function onTick()
	if player.powerup == PLAYER_HAMMER then
			if BoomerangLock == 0 then
				if(player.runKeyPressing) then
					for k,v in pairs(NPC.get(171,-1)) do
						v.id = 292
						v.width = 32
						v.height = 32
						v:mem(0x110,FIELD_DFLOAT,1)
						if BoomerangLock == 0 then
							if player:mem(0x106,FIELD_WORD) ~= -1 then
								BoomerangLock = 0
								v.x = v.x + 2
								v.speedX = 25
								v.speedY = -10
							else
								v.x = v.x - 2
								v.speedX = -25
								v.speedY = -10
								BoomerangLock = 0

end
			else
				local BoomerangCheck = NPC.get(292,-1)
				if table.getn(BoomerangCheck) == 0 then
					BoomerangLock = 0
				else
					player:mem(0x160,FIELD_WORD,2)
					end
end
end
end
end
end
end
end
The only problem with this is that it doesn't work for Peach.


Return to “LunaLua”

Who is online

Users browsing this forum: No registered users and 1 guest

SMWCentralTalkhausMario Fan Games GalaxyKafukaMarioWikiSMBXEquipoEstelari