MaGL X2 Discussion - MaGL X2 Lands TOMORROW. GET. HYPE.
- pholtos
- Loves adorable things.
- Posts: 1590
- Joined: 13 years ago
- Location: One of the States in the Center of the U.S.
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
Ah thanks for cutting in Willhart. Was hoping someone did because I'm actually not to knowledgeable myself.
Host and Organizer of the Rando Pokemon Tournaments. Completed: I, II, III, IV, V
Dealer of the Pokermon Discord Tourneys.












I do LPs, check them out if you'd like.
Currently playing:

The 500 char limit is evil. :P
Dealer of the Pokermon Discord Tourneys.












I do LPs, check them out if you'd like.
Currently playing:

The 500 char limit is evil. :P
- Willhart
- Stalker, Doxxer, and Sexual Harasser
- Banned
- Posts: 2434
- Joined: 12 years ago
- Location: Finland
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
I did not notice the conversation a little earlier. If you want to start the autoscroll from the middle of a section, or somewhere else than section 1, you should probably use lunadll instead.pholtos wrote:Ah thanks for cutting in Willhart. Was hoping someone did because I'm actually not to knowledgeable myself.
http://www.supermariobrosx.org/forums/v ... =69&t=4711
- DullahanDodgeman
- The Incompetent
- Posts: 44
- Joined: 8 years ago
- Location: My room, usually
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
Can anyone help diagnose what is happening with my SMBX level editor? I start it up and the window starts at a default black screen, but if I try adding any backgrounds, nothing gets added and after that the cursor just leaves after images all over the level window. I even tried play-testing the level, but it just got rid of the after images and still wouldn't do anything.
Some pictures to go along.
http://imgur.com/a/EiIEL
Some pictures to go along.
http://imgur.com/a/EiIEL
Is this the spot where I place my order for a large pizza?
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
Did you extend the level boundaries at all?
- DullahanDodgeman
- The Incompetent
- Posts: 44
- Joined: 8 years ago
- Location: My room, usually
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
Just tried, and it sort of worked. The size of the black space was bigger or smaller when I moved the camera around, but any time I try adding something it doesn't show anything, and when I try to load another level or load a background I just get after images, but only in the black space.
Is this the spot where I place my order for a large pizza?
- Willhart
- Stalker, Doxxer, and Sexual Harasser
- Banned
- Posts: 2434
- Joined: 12 years ago
- Location: Finland
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
Can you place blocks or npcs? I think the SMBX editor might be unable to locate the graphics folder. Are they both inside the "MaGL X2 Devkit" folder? Are there graphics inside the graphics folder?
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
I'd like to entirely disable the 'hold a fireball over your head' mechanic. At the moment I have a block of code to immediately kill the fireball, but [the player character] still does the animation for like a frame and it looks super gross.
I think the ideal way to do this would be to either disable the button entirely or make SMBX think the other run button's being held instead (which I presume would also entail disabling the alt run button), but I can't seem to do either of these things.
The last thing I tried that was even remotely plausible was:
I've tried KEY_X and KEY_RUN, and setting each of those addresses to 0, 1, 2, -1, -2, -5, FFFF... none of them even affected the usual behavior on pressing the button. Same goes for doing all of that in onLoop. Also the "dddddd" shows up for a frame every time I press any button but that's not really a concern, I don't think.
So uh, what am I doing wrong here? And is there even a right way to do this?
I think the ideal way to do this would be to either disable the button entirely or make SMBX think the other run button's being held instead (which I presume would also entail disabling the alt run button), but I can't seem to do either of these things.
The last thing I tried that was even remotely plausible was:
Code: Select all
function onKeyDown(KEY_X,playerIndex)
printText("dddddd",1,1)
player:mem(0xFE,FIELD_WORD,0)
player:mem(0x100,FIELD_WORD,1)
endSo uh, what am I doing wrong here? And is there even a right way to do this?
- pholtos
- Loves adorable things.
- Posts: 1590
- Joined: 13 years ago
- Location: One of the States in the Center of the U.S.
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
Well... dunno if this is what you want but looking through lua things I found this:Zyglrox Odyssey wrote:And is there even a right way to do this?
I couldn't find anything else glancing through the stuff that might also be helpful so if that doesn't help sorry.//+0x154 w = Index of sprite being held (index to a specific sprite object that was generated only, -1 = can't carry anything)
Host and Organizer of the Rando Pokemon Tournaments. Completed: I, II, III, IV, V
Dealer of the Pokermon Discord Tourneys.












I do LPs, check them out if you'd like.
Currently playing:

The 500 char limit is evil. :P
Dealer of the Pokermon Discord Tourneys.












I do LPs, check them out if you'd like.
Currently playing:

The 500 char limit is evil. :P
- Rednaxela
- Maker of Shenanigans
- Posts: 897
- Joined: 9 years ago
- Pronouns: they/them
- https://rednaxela.talkhaus.com
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
Not the main issue you're running into, but your use of KEY_X is incorrect. What you should do is:Zyglrox Odyssey wrote:Code: Select all
function onKeyDown(KEY_X,playerIndex) printText("dddddd",1,1) player:mem(0xFE,FIELD_WORD,0) player:mem(0x100,FIELD_WORD,1) end
Code: Select all
function onKeyDown(keycode, playerIndex)
if (keycode == KEY_X) then
printText("dddddd",1,1)
player:mem(0xFE,FIELD_WORD,0)
player:mem(0x100,FIELD_WORD,1)
end
end- DullahanDodgeman
- The Incompetent
- Posts: 44
- Joined: 8 years ago
- Location: My room, usually
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
So hey, apparently when I unzipped the rar file for SMBX, it didn't take all the files out, so I was missing the graphics folder in it's entirety, along with several other probably important files.
And to think I probably would not have figured that out on my own...Embarrassing.
And to think I probably would not have figured that out on my own...Embarrassing.
Is this the spot where I place my order for a large pizza?
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
Out of the characters that we where given, we have to choose one and only one? I can't have them both playable for the level?
- pholtos
- Loves adorable things.
- Posts: 1590
- Joined: 13 years ago
- Location: One of the States in the Center of the U.S.
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
You can use both, it's fine.Rezanator wrote:Out of the characters that we where given, we have to choose one and only one? I can't have them both playable for the level?
Host and Organizer of the Rando Pokemon Tournaments. Completed: I, II, III, IV, V
Dealer of the Pokermon Discord Tourneys.












I do LPs, check them out if you'd like.
Currently playing:

The 500 char limit is evil. :P
Dealer of the Pokermon Discord Tourneys.












I do LPs, check them out if you'd like.
Currently playing:

The 500 char limit is evil. :P
- Dragon Fogel
- Master of Pointlessness
- Posts: 1331
- Joined: 8 years ago
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
I'm trying to put some text boxes in my level, but I can't figure out how to do linebreaks cleanly, without manually putting in enough spaces to force a new line.
Is there a way to do that?
Is there a way to do that?
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
That's great then. That will make it easier in making the level.pholtos wrote:You can use both, it's fine.Rezanator wrote:Out of the characters that we where given, we have to choose one and only one? I can't have them both playable for the level?
- swirlybomb
- a bomb that is swirly
- Posts: 65
- Joined: 11 years ago
- First name: Swirlus Bomberton
- Location: The Canadas
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
Day 9:
...Granted, I've been preoccupied with other things, but I still have zero ideas on what to do with my level names. Seems like the 'medium' names this year are roughly equivalent to the 'hard' names last year. Or at least that they lean towards "abstract" or "monkey-cheese" names rather than names you'd actually find in a game. Debating whether I should just eat the penalty and get a list of easy names instead... Guess I'll see if I can come up with anything using the tiny vague ideas I've had first.
this message has been brought to you by Nobody Cares, Inc.
...Granted, I've been preoccupied with other things, but I still have zero ideas on what to do with my level names. Seems like the 'medium' names this year are roughly equivalent to the 'hard' names last year. Or at least that they lean towards "abstract" or "monkey-cheese" names rather than names you'd actually find in a game. Debating whether I should just eat the penalty and get a list of easy names instead... Guess I'll see if I can come up with anything using the tiny vague ideas I've had first.
this message has been brought to you by Nobody Cares, Inc.
anonymousbl00dlust wrote:All the obstacles in my level can be beaten on the players first attempt without any 'future predicting'.
- ztarwuff
- What the heck is a flair and why am I being asked to write one for my profile?
- Posts: 550
- Joined: 9 years ago
- Location: Within 2 miles of the Imperial Crypt of Napoleon III
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
Not that I'm aware of, but then again, I haven't had a go at using the new LunaLua yet.Dragon Fogel wrote:I'm trying to put some text boxes in my level, but I can't figure out how to do linebreaks cleanly, without manually putting in enough spaces to force a new line.
Is there a way to do that?
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
If you'd like, you could send your names to me in a PM and I could see if I can come up with anything?swirlybomb wrote:Day 9:
...Granted, I've been preoccupied with other things, but I still have zero ideas on what to do with my level names. Seems like the 'medium' names this year are roughly equivalent to the 'hard' names last year. Or at least that they lean towards "abstract" or "monkey-cheese" names rather than names you'd actually find in a game. Debating whether I should just eat the penalty and get a list of easy names instead... Guess I'll see if I can come up with anything using the tiny vague ideas I've had first.
this message has been brought to you by Nobody Cares, Inc.
If that's allowed in the first place! Horikawa?
-
Rixithechao
- https://www.youtube.com/watch?v=IwLdM6ejGAM
- Posts: 1608
- Joined: 8 years ago
- First name: Mack
- https://rixithechao.talkhaus.com/
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
Yeah, for now there's no line break character so you'll have to use spaces. I considered splitting the dialogue into four lines, but that would mean either taking a string array as a parameter or having four string parameters. Neither is an elegant solution.Dragon Fogel wrote:I'm trying to put some text boxes in my level, but I can't figure out how to do linebreaks cleanly, without manually putting in enough spaces to force a new line.
Is there a way to do that?
But the unfortunate side effect is that you might need different strings if you include the player character's name (cinematX.playerNameSMBX) in there -- Mario, Luigi and Peach all have 5-letter names but Link and Toad have 4 letters (hooray, Rocky can count!) so if you got Mario and Toad or Link and Peach as your characters then you'll need to account for that extra space.
Delightful Adventure Enhanced is out now!

There's an official ASMT Discord server! Check it out to follow and/or contribute to A2XT Episode 2's development! thread, invite link
(Entry requires verification, either with a connected Youtube/Twitter/Twitch/etc account or manually by the server staff.)
Itch.io (albums and eventually games), Youtube (dofur pass and I guess other videos)

There's an official ASMT Discord server! Check it out to follow and/or contribute to A2XT Episode 2's development! thread, invite link
(Entry requires verification, either with a connected Youtube/Twitter/Twitch/etc account or manually by the server staff.)
Itch.io (albums and eventually games), Youtube (dofur pass and I guess other videos)
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
If the font is monospaced, there's a pretty simply algorithm you can use to auto-wrap words. It's more difficult for kerned fonts (particularly in SMBX), but I think this is a monospaced one...Rockythechao wrote: Yeah, for now there's no line break character so you'll have to use spaces. I considered splitting the dialogue into four lines, but that would mean either taking a string array as a parameter or having four string parameters. Neither is an elegant solution.
But the unfortunate side effect is that you might need different strings if you include the player character's name (cinematX.playerNameSMBX) in there -- Mario, Luigi and Peach all have 5-letter names but Link and Toad have 4 letters (hooray, Rocky can count!) so if you got Mario and Toad or Link and Peach as your characters then you'll need to account for that extra space.
EDIT: Here's some code that will split a string into two. The first (hd) will be wrapped at l characters maximum, but won't cut off halfway through a word. The second (tl) will contain the rest of the string. You can call this repeatedly on the tail of the result to wrap multiple lines, though I could tweak it to keep wrapping the string.
I applied this to CinematX, and it works nicely, but it does need to be applied to the full string, rather than the individual substrings (as I did) or you get words jumping around as they reveal themselves.
Code: Select all
function cinematX.wrapString (str, l)
local head = "";
local tail = "";
local wrds = {}
local i = 0;
for j in string.gmatch(str, "%S+") do
wrds[i] = j;
i = i + 1
end
i = 0;
while(wrds[i] ~= nil) do
local newHd = head.." "..wrds[i];
if(string.len(newHd) <= l) then
head = newHd;
i = i + 1
else
break;
end
end
while(wrds[i] ~= nil) do
tail = tail.." "..wrds[i];
i = i + 1
end
return { hd = head, tl = tail };
end




Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
Right, of course, I should've remembered that from my (limited) Python experience. Okay, thanks, now its behaving a bit more sensibly.Rednaxela wrote:Not the main issue you're running into, but your use of KEY_X is incorrect. What you should do is:Zyglrox Odyssey wrote:Code: Select all
function onKeyDown(KEY_X,playerIndex) printText("dddddd",1,1) player:mem(0xFE,FIELD_WORD,0) player:mem(0x100,FIELD_WORD,1) endThe part in brackets on the function line, are just the names of variables that the input gets put into.Code: Select all
function onKeyDown(keycode, playerIndex) if (keycode == KEY_X) then printText("dddddd",1,1) player:mem(0xFE,FIELD_WORD,0) player:mem(0x100,FIELD_WORD,1) end end
I think my actual problem though is that the lunalua code is executed after everything else, so I can tell SMBX that the button's not being pressed all I want but it kinda already acted on the actual controller readings so it's not really accomplishing anything at all. I don't suppose there's any way to make it run first?
(Also I'm noticing KEY_X is actually the normal run button and the alt run button is KEY_X and KEY_RUN at the same time apparently. I don't really get it but okay.)
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
The hardest thing I've run into so far is having waterfalls fall in water, so having a waterfall behind surface water sprites. Holy crap. It doesn't make any sense to me. 
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
So, my level is pretty much finished, aside from a few purely asthetic tweeks here and there, but I have a few questions anyways.
1. Is it a known issue, that the Wohl editor just randomly dies when clicking the "Lock all Blocks/BGOs/NPCs etc."-buttons, because that happened to me at least once every day I worked on my level so far, and it seems to be completely random. Doesn't seem to matter how many things are on the active section or anything. If it helps, it happens only when Un-locking one of those buttons and most of the time, with the NPCs. It never hurt me much, because I pretty much save after every new thing I put down, but it's always scary either way.
2. Is it possible to play two different custom songs in one section? As the Event-Manager doesn't let you choose WHICH custom song you want to play and exclusively takes the song you choose in Section Settings, I feel like it's not possible, but if it is, that would be great, as I don't really like the choices from the original SMBX-Music library (they don't really fit my level). The only other option i have, would be to make one of the two parts of the section [Silence], which I feel, isn't really good.
3. How does the Z-Index for BGOs work? I already worked around it by just combining two overlapping BGOs into one Custom BGO, but it would be interesting to know retrospectively.
Oh, and here are my rejected easy names, because why not:
1. Is it a known issue, that the Wohl editor just randomly dies when clicking the "Lock all Blocks/BGOs/NPCs etc."-buttons, because that happened to me at least once every day I worked on my level so far, and it seems to be completely random. Doesn't seem to matter how many things are on the active section or anything. If it helps, it happens only when Un-locking one of those buttons and most of the time, with the NPCs. It never hurt me much, because I pretty much save after every new thing I put down, but it's always scary either way.
2. Is it possible to play two different custom songs in one section? As the Event-Manager doesn't let you choose WHICH custom song you want to play and exclusively takes the song you choose in Section Settings, I feel like it's not possible, but if it is, that would be great, as I don't really like the choices from the original SMBX-Music library (they don't really fit my level). The only other option i have, would be to make one of the two parts of the section [Silence], which I feel, isn't really good.
3. How does the Z-Index for BGOs work? I already worked around it by just combining two overlapping BGOs into one Custom BGO, but it would be interesting to know retrospectively.
Oh, and here are my rejected easy names, because why not:
- FrozenQuills
- overdone flair 2022
- Posts: 840
- Joined: 8 years ago
- Location: my skull
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
So I'm having some bad lag issues when I start using the new dev kit with cinematX...
I already have the majority of my level made before the update, but when I tried testing my level in it, it lags pretty badly.
When I don't disable frameskip, my level lags immensely and it's basically unplayable. If I do disable frameskip, my level is still pretty slow and annoying. I tried diagnosing the problem by completely commenting out all of my lua scripts but I still have lag. I'm 99% sure this is because of cinematX somehow because everything was working fine before I used the new devkit. I'm not even utilizing cinematX in my level (yet)...
EDIT: completely erasing the whole lua script didn't work either if that matters
EDIT 2: I tried renaming my lunadll.lua so that it doesn't affect the level at all, and it's suddenly fixed. However, if I do have a lunadll.lua file (and even if it's completely blank), it has noticeable slowdown.
I already have the majority of my level made before the update, but when I tried testing my level in it, it lags pretty badly.
When I don't disable frameskip, my level lags immensely and it's basically unplayable. If I do disable frameskip, my level is still pretty slow and annoying. I tried diagnosing the problem by completely commenting out all of my lua scripts but I still have lag. I'm 99% sure this is because of cinematX somehow because everything was working fine before I used the new devkit. I'm not even utilizing cinematX in my level (yet)...
EDIT: completely erasing the whole lua script didn't work either if that matters
EDIT 2: I tried renaming my lunadll.lua so that it doesn't affect the level at all, and it's suddenly fixed. However, if I do have a lunadll.lua file (and even if it's completely blank), it has noticeable slowdown.
Last edited by FrozenQuills 8 years ago, edited 2 times in total.


avatar by crayonchewer!
- Wohlstand
- Moondust and TheXTech developer
- Posts: 186
- Joined: 9 years ago
- First name: Vitaly
- Pronouns: he/him/his
- Location: Moscow, Russia
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
I will check out for it and will notice you and you will can get fixed build on my laboratory7TC7 wrote:1. Is it a known issue, that the Wohl editor just randomly dies when clicking the "Lock all Blocks/BGOs/NPCs etc."-buttons, because that happened to me at least once every day I worked on my level so far, and it seems to be completely random. Doesn't seem to matter how many things are on the active section or anything. If it helps, it happens only when Un-locking one of those buttons and most of the time, with the NPCs. It never hurt me much, because I pretty much save after every new thing I put down, but it's always scary either way.
- DullahanDodgeman
- The Incompetent
- Posts: 44
- Joined: 8 years ago
- Location: My room, usually
Re: MaGL X2 Discussion. No raocows! NOT the sign up thread!
Quick question, does anyone know where I can get the Sheath sprite replacements for Link? I can't find them anywhere, and the one place they were supposed to be had an expired link.
...Was that a pun?
...Was that a pun?
Is this the spot where I place my order for a large pizza?









