Very nice bro! Thy very much this is actually a very neat thing to use if you have LunaLUA Loader/SMBX! The script can be found on the forum to make Peach fly after running. I will replace the default Peach sprite with the fix and put the LunaLUA code into every world I have!
Voymo wrote:Very nice bro! Thy very much this is actually a very neat thing to use if you have LunaLUA Loader/SMBX! The script can be found on the forum to make Peach fly after running. I will replace the default Peach sprite with the fix and put the LunaLUA code into every world I have!
Thank you, and Peach is my favorite character! for those who want a link for the Peach Flight Script, it is here!
DarkShadeX wrote:Found this old code while removing stuff from my hard drive.
This Script basically allows Peach to fly while she's in her racoon form like Mario and Co.
Before i remove this code from the hard drive,i aswell just release it here.
-- SMBX - Peach flying Script by DarkShadeX
-- 0x1C = Princess hover timer
-- 0x16E = Is flying
-- 0xF0 = Player identity index (0 = nothing! don't use, 1 = demo, 2 = iris, 3 = princess, 5 = sheath)
local fly_lenght = 80 -- How long you can fly,adjust it so its perfect for you ;)
local remaining_fly = fly_lenght
function onLoop()
printText("RUNNING "..tostring(remaining_fly).." FRAMES", 30, 60)
-- If you Hover,prevent that you can fly:
if( player:mem(0x1C,FIELD_WORD) >= 1 )then
remaining_fly = 0
end
-- Check if Stuff ... :
if( player:mem(0x1C,FIELD_WORD) == 0 and player.speedY ~= 0 and remaining_fly >= 0 and player:mem(0xF0,FIELD_WORD) == 3 and player.speedX >= 5.55 and player.powerup == PLAYER_LEAF)then
player:mem(0x16E,FIELD_WORD,-1) -- LET THE FLY BEGIN :>
remaining_fly = remaining_fly - 0.25 -- Reduce our flying timer.
end
-- Check if Stuff ... LEFT :
if( player:mem(0x1C,FIELD_WORD) == 0 and player.speedY ~= 0 and remaining_fly >= 0 and player:mem(0xF0,FIELD_WORD) == 3 and player.speedX <= -5.55 and player.powerup == PLAYER_LEAF)then
player:mem(0x16E,FIELD_WORD,-1) -- LET THE FLY BEGIN :>
remaining_fly = remaining_fly - 0.25 -- Reduce our flying timer.
end
-- End the Flying:
if( remaining_fly <= 1 )then -- If you don't have any flying timer anymore...
player:mem(0x16E,FIELD_WORD,0) -- Stop the Flying.
end
-- Extra Fixes:
if( remaining_fly <= fly_lenght and player:mem(0x16E,FIELD_WORD) == -1 )then -- So the counter doesnt stop if you change the direction ;)
remaining_fly = remaining_fly - 0.25
end
end
function onJumpEnd()
remaining_fly = fly_lenght -- Reset the counter if you fall.
end
Anyway, I am glad to be of help! I had the Peach flight script since May 30th or sooner by the way! I just waited til I finished the 8-bit Peach graphics! I will update this with Daisy if I can get the graphic of her!
The graphic of the playable Princess Daisy was made by Redigit & Valtteri and is included in the "Valtteri's Graphics Pack 1.0.1" under SMB2. Actually that isn't hard, you just gotta copy and paste the tail from the fixed file
Last edited by Voymo on Mon Oct 12, 2015 9:09 am, edited 2 times in total.
Voymo wrote:The graphic of the playable Princess Daisy was made by Redigit & Valtteri and is included in the "Valtteri's Graphics Pack 1.0.1" under SMB2. Actually that isn't hard, you just gotta copy and paste the tail from the fixed file
I know, I just never had the origial to begin with!
-- 0x1C = Princess hover timer
-- 0x16E = Is flying
-- 0xF0 = Player identity index (0 = nothing! don't use, 1 = demo, 2 = iris, 3 = princess, 5 = sheath)
local fly_lenght = 80 -- How long you can fly,adjust it so its perfect for you
local remaining_fly = fly_lenght
-- If you Hover,prevent that you can fly:
if( player:mem(0x1C,FIELD_WORD) >= 1 )then
remaining_fly = 0
end
-- Check if Stuff ... :
if( player:mem(0x1C,FIELD_WORD) == 0 and player.speedY ~= 0 and remaining_fly >= 0 and player:mem(0xF0,FIELD_WORD) == 3 and player.speedX >= 5.55 and player.powerup == PLAYER_LEAF or player.powerup == PLAYER_TANOOKIE)then
player:mem(0x16E,FIELD_WORD,-1) -- LET THE FLY BEGIN :>
remaining_fly = remaining_fly - 0.25 -- Reduce our flying timer.
end
-- Check if Stuff ... LEFT :
if( player:mem(0x1C,FIELD_WORD) == 0 and player.speedY ~= 0 and remaining_fly >= 0 and player:mem(0xF0,FIELD_WORD) == 3 and player.speedX <= -5.55 and player.powerup == PLAYER_LEAF or player.powerup == PLAYER_TANOOKIE)then
player:mem(0x16E,FIELD_WORD,-1) -- LET THE FLY BEGIN :>
remaining_fly = remaining_fly - 0.25 -- Reduce our flying timer.
end
-- End the Flying:
if( remaining_fly <= 1 )then -- If you don't have any flying timer anymore...
player:mem(0x16E,FIELD_WORD,0) -- Stop the Flying.
end
-- Extra Fixes:
if( remaining_fly <= fly_lenght and player:mem(0x16E,FIELD_WORD) == -1 )then -- So the counter doesnt stop if you change the direction
remaining_fly = remaining_fly - 0.25
end
end
function onJumpEnd()
remaining_fly = fly_lenght -- Reset the counter if you fall.
end
It works and uses the animation, but Peach takes off too fast compared to for example Toad. She was like off the screen in a second I am not familiar with coding in LUA, I just copy and paste the codes from the forum. If I need something altered, I do it by logical thinking + editing and testing. For example I know how to remove this debug-like output on the screen (but I didn't on this one in the spoiler, maybe still needed). What I did is I added or player.powerup == PLAYER_TANOOKIE here. Maybe there is a way to make Peach use the "wingman style flight" so she doesn't take off so fast, but with the regular Leaf/Tanookie "Take-Off" rules from the game, not the cheat effect, if you get what I mean. Maybe someone could help us here, would be nice. I bet since the flying Peach sprite was in the game already it would have been a regular ability of Peach to fly like Mario, Luigi & Toad in SMBX 1.3.1 if Nintendo wouldn't have stopped the developer.
-- 0x1C = Princess hover timer
-- 0x16E = Is flying
-- 0xF0 = Player identity index (0 = nothing! don't use, 1 = demo, 2 = iris, 3 = princess, 5 = sheath)
local fly_lenght = 80 -- How long you can fly,adjust it so its perfect for you
local remaining_fly = fly_lenght
-- If you Hover,prevent that you can fly:
if( player:mem(0x1C,FIELD_WORD) >= 1 )then
remaining_fly = 0
end
-- Check if Stuff ... :
if( player:mem(0x1C,FIELD_WORD) == 0 and player.speedY ~= 0 and remaining_fly >= 0 and player:mem(0xF0,FIELD_WORD) == 3 and player.speedX >= 5.55 and player.powerup == PLAYER_LEAF or player.powerup == PLAYER_TANOOKIE)then
player:mem(0x16E,FIELD_WORD,-1) -- LET THE FLY BEGIN :>
remaining_fly = remaining_fly - 0.25 -- Reduce our flying timer.
end
-- Check if Stuff ... LEFT :
if( player:mem(0x1C,FIELD_WORD) == 0 and player.speedY ~= 0 and remaining_fly >= 0 and player:mem(0xF0,FIELD_WORD) == 3 and player.speedX <= -5.55 and player.powerup == PLAYER_LEAF or player.powerup == PLAYER_TANOOKIE)then
player:mem(0x16E,FIELD_WORD,-1) -- LET THE FLY BEGIN :>
remaining_fly = remaining_fly - 0.25 -- Reduce our flying timer.
end
-- End the Flying:
if( remaining_fly <= 1 )then -- If you don't have any flying timer anymore...
player:mem(0x16E,FIELD_WORD,0) -- Stop the Flying.
end
-- Extra Fixes:
if( remaining_fly <= fly_lenght and player:mem(0x16E,FIELD_WORD) == -1 )then -- So the counter doesnt stop if you change the direction
remaining_fly = remaining_fly - 0.25
end
end
function onJumpEnd()
remaining_fly = fly_lenght -- Reset the counter if you fall.
end
It works and uses the animation, but Peach takes off too fast compared to for example Toad. She was like off the screen in a second I am not familiar with coding in LUA, I just copy and paste the codes from the forum. If I need something altered, I do it by logical thinking + editing and testing. For example I know how to remove this debug-like output on the screen (but I didn't on this one in the spoiler, maybe still needed). What I did is I added or player.powerup == PLAYER_TANOOKIE here. Maybe there is a way to make Peach use the "wingman style flight" so she doesn't take off so fast, but with the regular Leaf/Tanookie "Take-Off" rules from the game, not the cheat effect, if you get what I mean. Maybe someone could help us here, would be nice. I bet since the flying Peach sprite was in the game already it would have been a regular ability of Peach to fly like Mario, Luigi & Toad in SMBX 1.3.1 if Nintendo wouldn't have stopped the developer.
In the spoiler, what I turned green, that is the line that effects how long she can fly, about 70 seconds are good for Mario!
Ness-Wednesday wrote:This is not bad for a Peach playable.
It is actually fitting for an 8-bit SMB2 (retro) level.
Thank you, I opened up the original game on my NES emulator for the colors! I had to ask a very specific friend for help with color when I got to Fire and Ice Peach! I went to world four of the game to get the ice-blocks gradient,
Ness-Wednesday wrote:
MECHDRAGON777 wrote:☢SEIZURE WARNING☢
Bro, you just gave me an idea for a new graphic!
What graphic did I inspire you to make by giving a Seizure warning?
NathanBros wrote:Good character! This must be awesome to girl players... (for lot's of guys too).
Okay, I am male, but I actually like playing as Peach! (Rosalina in particular) [spoiler]Sadly, I kind of wish I was female...[/spoiler]
Snowburger wrote:
NathanBros wrote:Good character! This must be awesome to girl players... (for lot's of guys too).
That's quite sexist to be honest,but on-topic.
These are quite good,nice for a retro level.And thanks for the fix code,I'll be using it!
Well, I am remaking NES Super Mario Brothers 2 as you can see from the video and I used 1-1 as my video to show off the new playable. In all honesty, I am adding Peach and Toad to give more option and for people like Witchking666, 8bitmushroom, or others who like to play as Toad and me who likes playing as Peach and Link. I had to make the Peach graphic and I guess I should not hold it from the public. ...but I do have to ask you what you mean by:
Snowburger wrote:And thanks for the fix code,I'll be using it!
I just did not get that! Anyway, I hope you enjoy this! Did you mean the fixed flight animation on Peach and Rosalina? If you mean that, then I thank you very much for liking what I did!
Guys, this is not quite right yet... I am male too :p I am simply a big Super Mario fan and Peach is a Mario character to me, I simply like playing everyone on SMBX (besides Link, he doesn't quite fit to the game). But that wasn't the reason for this comment. Mecha, the code is not 100% fine yet... Peach takes off way too fast compared to the other characters. What could we do to fix this?
Voymo wrote:Guys, this is not quite right yet... I am male too :p I am simply a big Super Mario fan and Peach is a Mario character to me, I simply like playing everyone on SMBX (besides Link, he doesn't quite fit to the game). But that wasn't the reason for this comment. Mecha, the code is not 100% fine yet... Peach takes off way too fast compared to the other characters. What could we do to fix this?
I do not know since I am not good in lua yet. I would ask he creator! What is not quite right?
Well, when Peach starts flying she gains hight as fast as if she would jump. She should gain hight slower when flying (Compare Peach flying to the other characters flying).
Voymo wrote:Well, when Peach starts flying she gains hight as fast as if she would jump. She should gain hight slower when flying (Compare Peach flying to the other characters flying).
Sorry for replying a bit late maybe, I am currently on vacation in Spain. Who actually made this script again? I know a possible fix I think, but I don't know how to turn my idea into reality, since also I cannot code in LUA.
Edit: Never mind, I found him/her (DarkShadeX) but I cannot pm this person because I guess he set it so only friends can...
Voymo wrote:Sorry for replying a bit late maybe, I am currently on vacation in Spain. Who actually made this script again? I know a possible fix I think, but I don't know how to turn my idea into reality, since also I cannot code in LUA.
Edit: Never mind, I found him/her (DarkShadeX) but I cannot pm this person because I guess he set it so only friends can...
No he deactivated that everyone expect the staff can pm him.
Just head to the lunalua thread DSX only did for lunadll