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?
XerX wrote:
That's pretty neat. I was working on something similar myself to go with the Overhaul mod, but never got around to finishing it. Maybe I should finish it just for the heck of it.
Why is Mayro half on the map down and half above it.
Not sure if this bug has been reported before, but the Underground background track in SMB1 appears to be broken. The game still seems to be searching for an MP3 rather than the .spc file, so any level that uses "smb-underground.mp3" throws up an error and no music plays.
The other tracks work fine however as far as I'm aware. I'm using LunaLUA 0.7.2.2-beta, but this issue was present in LunaLUA 0.7.2.1 as well.
Cornholio309 wrote:Not sure if this bug has been reported before, but the Underground background track in SMB1 appears to be broken. The game still seems to be searching for an MP3 rather than the .spc file, so any level that uses "smb-underground.mp3" throws up an error and no music plays.
The other tracks work fine however as far as I'm aware. I'm using LunaLUA 0.7.2.2-beta, but this issue was present in LunaLUA 0.7.2.1 as well.
1) Please download FULL build of LunaLUA, because it has updated & fixed music.ini and fixed musics folder + SMB-Underground is NSF-based track whuch also requires track number suffix, I.e. "file.nsf|2", because alone NSF file contains multiple different music tracks.
2) LunaLUA 0.7.2.2-beta still have a bug with support of track number suffix which wasn't worked from INI-files (but worked from "custom" music field or from lua-code Audio.openMusic("file.nsf|2")). So, after re-taking of full LunaLUA, please take a fixed LunaDLL.dll: http://engine.wohlnet.ru/docs/_laborato ... unaDll.dll
+ a little news that nightly builds of LunaLUA core are available for everyone: https://ci.appveyor.com/project/Wohlstand/lunadll
(you also can find a "Build passing" badge which is a direct link to that page). Download build you can in the "Artifacts" tab.
Wohlstand wrote:
1) Please download FULL build of LunaLUA, because it has updated & fixed music.ini and fixed musics folder + SMB-Underground is NSF-based track whuch also requires track number suffix, I.e. "file.nsf|2", because alone NSF file contains multiple different music tracks.
2) LunaLUA 0.7.2.2-beta still have a bug with support of track number suffix which wasn't worked from INI-files (but worked from "custom" music field or from lua-code Audio.openMusic("file.nsf|2")). So, after re-taking of full LunaLUA, please take a fixed LunaDLL.dll: http://engine.wohlnet.ru/docs/_laborato ... unaDll.dll
+ a little news that nightly builds of LunaLUA core are available for everyone: https://ci.appveyor.com/project/Wohlstand/lunadll
(you also can find a "Build passing" badge which is a direct link to that page). Download build you can in the "Artifacts" tab.
Excellent. That worked wonders! The SMB1 Underground track now plays a-okay which is pretty awesome!
Thank you so much!
I have to say LunaLua is incredibly nifty. In addition to the music looping seamlessly now and taking chip tune formats, I swear the game runs at a constant stable framerate. Back in 1.3, the framerate really felt all over the place which is a bit odd.
Now to delete me 0.7.2.1 installation and transfer my custom level over to this new one.
Edit: I'm starting to notice an issue now where MP3s don't seem to play properly. All of them are played at a higher pitch and sound significantly speed up for some reason. I noticed this while playing New Great Castle Adventure'sRuinous Caverns. That level uses Donkey Kong Country'sCave Dweller Concert.
Here's what is should sound like:
Here's what it sounds like in LunaLUA 0.7.2.2:
For further reference, here's the same level recorded by bossedit8. The music plays at the proper pitch here:
Resample your audio file into 44100 hz!
Until I will don't implement SOXR support, SDL2 has a shitty resampler which doing a shit instead of output, therefore I commented it to play music as-is (result is pitched because it wasn't re-sampled)
....or better put .SPC file with this music from Donkey Kong Chip tunes pack which will be played directly in LunaLUA-SMBX (for Vanillia you should rip it into MP3)
(you can see that LunaLUA-SMBX's music folder has a lot of SPC-files instead of MP3/OGG files since SDL2_mixer_ext directly supports playback of those formats)
Full music formats list supported by PGE and by LunaLUA-SMBX: http://engine.wohlnet.ru/pgewiki/SDL2_m ... ic_Formats
* Unpack contents of downloaded archive into the "%Your SMBX Path%\worlds" folder
* Run a "MusicFixer.bat" file and wait while it will say "All files has been fixed!"
I actually found out that another user was having the same issue in a completely separate thread and saw your advice there. Thanks for that! A bit of an unfortunate issue, but Foobar2000 made quick work of the issue and now all of the tracks in New Great Castle Adventure are now fixed!
I'll definitely have to use that tool though if I run into the issue again. Any chance of adding it to the PGE Tool Pack? It seems pretty handy.
Cornholio309 wrote:I actually found out that another user was having the same issue in a completely separate thread and saw your advice there. Thanks for that! A bit of an unfortunate issue, but Foobar2000 made quick work of the issue and now all of the tracks in New Great Castle Adventure are now fixed!
I'll definitely have to use that tool though if I run into the issue again. Any chance of adding it to the PGE Tool Pack? It seems pretty handy.
In the PGE is a WIP-tool calling as "PGE Maintainer" which will unite all PNG2GIFs, GIFs2PNG, LazyFixTool and flexible music fixing/conversion. That tool will provide features to quickly port episodes between PGE or LunaLUA/Vaniila SMBX, graphics fixing/coversion and convenient and flexible music fixing toolset (you be able to convert all MP3's into OGG's with automatic replacing of links inside level files)
XerX wrote:
That's pretty neat. I was working on something similar myself to go with the Overhaul mod, but never got around to finishing it. Maybe I should finish it just for the heck of it.
Why is Mayro half on the map down and half above it.
it's a glitch that happens when you change his powerup from small to anything on the world map.
XerX wrote:
That's pretty neat. I was working on something similar myself to go with the Overhaul mod, but never got around to finishing it. Maybe I should finish it just for the heck of it.
Why is Mayro half on the map down and half above it.
it's a glitch that happens when you change his powerup from small to anything on the world map.
Never tried on the World Map but your one is nice too
Nice Job
I have done on my side now player select for who got the powerups from the inv. and also the Inventory bar got now 4 Row of items and working soon
But I need to figure a better way to increment more less faster instead of in the loop the number add 1 and reach the last max number in a micro second, lol
I mean 1 by 1 ...
and also a way how to remove an item in a table and they move to 1 to the side left like in the real smb3 when the item is taken :S , I have hard time with this one
(Maybe I have a hint , when in the table the value is " nil " then the value is not " nil " do -1 to his value) not sure how I will do this one but I will try harder to get it working now
If some one have idea I'm open
local coins = Graphics.loadImage("coincounter.png")
local raocoin = true
raocoin = loadSharedAPI("raocoin2");
rc = raocoin.registerCurrency(274, true, 472, 66);
coins = raocoin.registerMemCurrency(0x00B2C5A8,FIELD_WORD,true,false,0,0,"coincounter.png");
function raocoin.onCollect()
if(currency.id == 272) then
Currency:get(1)
currency:save(1);
end
end
Does anyone know what code i should be putting in?
Enjl wrote:Also, you're setting the value "coins" repeatedly. What you're essentially doing in onLoad is overwriting a bunch of stuff. Only the last time you define "coins" will actually be relevant, because it's the one up to date. It's like defining:
Hello = 1
Hello = 2
Hello = 1
Hello = 2
Hello = 5
while you could just write
Hello = 5
which would give the same result.
I don't know if that's the problem, but you still shouldn't do it.
Let me run over this, I marked the areas which are faulty or weird to me in the quote. Keep in mind that I never used raocoin.
SuperMario12345 wrote:local coins = Graphics.loadImage("coincounter.png") -- Do you want "coins" to be the image file, or the registered currency (further down)? local raocoin = true
raocoin = loadSharedAPI("raocoin2");-- What are you trying to accomplish in these lines? You're setting the variable you just set to "true" to hold the raocoin API
rc = raocoin.registerCurrency(274, true, 472, 66); -- You're registering ID 274, but further down you're calling for 272 coins = raocoin.registerMemCurrency(0x00B2C5A8,FIELD_WORD,true,false,0,0,"coincounter.png"); -- This overwrites "coins" set in the first line. I'd just get rid of the first line altogether.
function raocoin.onCollect()
if(currency.id == 272) then --SMB2 Hoopster || EVERYTHING IS CASE SENSITIVE BY THE WAY
Currency:get(1) --From looking at the wiki, this will return the value of the currency. With Currency.get() you can store the value of the currency in a variable. An example: local stuff = Currency:get() currency:save(1); --There is no such thing as Currency:save(1). It's just Currency:save() and saves the currency value set with Currency:set(number)
end
end
Enjl wrote:Let me run over this, I marked the areas which are faulty or weird to me in the quote. Keep in mind that I never used raocoin.
SuperMario12345 wrote:local coins = Graphics.loadImage("coincounter.png") -- Do you want "coins" to be the image file, or the registered currency (further down)? local raocoin = true
raocoin = loadSharedAPI("raocoin2");-- What are you trying to accomplish in these lines? You're setting the variable you just set to "true" to hold the raocoin API
rc = raocoin.registerCurrency(274, true, 472, 66); -- You're registering ID 274, but further down you're calling for 272 coins = raocoin.registerMemCurrency(0x00B2C5A8,FIELD_WORD,true,false,0,0,"coincounter.png"); -- This overwrites "coins" set in the first line. I'd just get rid of the first line altogether.
function raocoin.onCollect()
if(currency.id == 272) then --SMB2 Hoopster || EVERYTHING IS CASE SENSITIVE BY THE WAY
Currency:get(1) --From looking at the wiki, this will return the value of the currency. With Currency.get() you can store the value of the currency in a variable. An example: local stuff = Currency:get() currency:save(1); --There is no such thing as Currency:save(1). It's just Currency:save() and saves the currency value set with Currency:set(number)
end
end
I meant to insert 274 right there, that was a mistake. Thanks for telling me that Currency:save(1) isn't a real code. I also wanted coins to be image file name.
I don't really understand what i was doing on the API line. Ok, i'll get rid of first line and see what happens.
Enjl wrote:Let me run over this, I marked the areas which are faulty or weird to me in the quote. Keep in mind that I never used raocoin.
SuperMario12345 wrote:local coins = Graphics.loadImage("coincounter.png") -- Do you want "coins" to be the image file, or the registered currency (further down)? local raocoin = true
raocoin = loadSharedAPI("raocoin2");-- What are you trying to accomplish in these lines? You're setting the variable you just set to "true" to hold the raocoin API
rc = raocoin.registerCurrency(274, true, 472, 66); -- You're registering ID 274, but further down you're calling for 272 coins = raocoin.registerMemCurrency(0x00B2C5A8,FIELD_WORD,true,false,0,0,"coincounter.png"); -- This overwrites "coins" set in the first line. I'd just get rid of the first line altogether.
function raocoin.onCollect()
if(currency.id == 272) then --SMB2 Hoopster || EVERYTHING IS CASE SENSITIVE BY THE WAY
Currency:get(1) --From looking at the wiki, this will return the value of the currency. With Currency.get() you can store the value of the currency in a variable. An example: local stuff = Currency:get() currency:save(1); --There is no such thing as Currency:save(1). It's just Currency:save() and saves the currency value set with Currency:set(number)
end
end
I meant to insert 274 right there, that was a mistake. Thanks for telling me that Currency:save(1) isn't a real code. I also wanted coins to be image file name.
I don't really understand what i was doing on the API line. Ok, i'll get rid of first line and see what happens.
I'm not very good in lua not now :S , but with the "Currency:get(1)" the 1 is just a number on save and get you need to put a variable to insert the value you want.
like
lotus006 wrote:
I'm not very good in lua not now :S , but with the "Currency:get(1)" the 1 is just a number on save and get you need to put a variable to insert the value you want.
like
local banana = 1
currency:save("banana");
Currency:get("banana")
Sorry if i'm wrong
What you're doing is absolute bollocks. Watch the case-sensitivity
Also, You're trying to set the currency to a string, which isn't possible.
I'll give you a quick run-through of the Data class and how it differs from the raocoin class, from my understanding:
The data class lets you save values to different strings inside a file, which can be carried across levels. If you want to set a value, you do this:
data:set("value", 1)
sata:save()
This sets the value of "value" to 1. If you fancy, you can go more complicated and do stuff like
data:set("value", data:get("value") + 1)
to have it count up every time the event is executed.
To get a variable from the data class, you, as seen above, type
data:get("value")
You can save this to a variable by typing
local variable = data:get("value")
and vice-versa, you don't have to use numbers when setting your custom data class element:
data:set("other thing", variable)
data:save()
The Currency class for raocoin seems to get rid of the string present in the data class, which means all you can set now is the value of the internal currency. With Currency:get() you get the value of the currency, and with Currency:set(number) you can set it. Currency:save() works the same way as in the data class.
Someone with more knowledge, correct me if I'm wrong.
lotus006 wrote:
I'm not very good in lua not now :S , but with the "Currency:get(1)" the 1 is just a number on save and get you need to put a variable to insert the value you want.
like
[code]
local banana = 1
Currency:save( banana ); -- not sure about this one , I need to add like this ? ( Currency:save( banana + 1); or Currency:save( ); ?
Currency:get( banana )
[/code]
Thanks you are very good , without your help our codes will be disastruous ^^
in talk of this, is there a way to make it dynamic like my graphic menu if I change value like a button if is true then the next time it will be staying on the same value
on the next load ?
I think it should be the same thing ? when the value is saved I can get the saved value and the button will stay true ? I mean just in an example for sure ^^