Language…
6 users online:  Alex, Europia79, Hot Sauce, Maw, Slash-18, yoshistar184 - Guests: 99 - Bots: 156
Users: 69,715 (2,539 active)
Latest user: CORROSIVEsprings

Posts by hash

hash's Profile → Posts

I am using this block by MarioE. The green gas bubble seems to have no interaction with it. Are there any changes that could be made to this code to give the green gas bubble some interaction and shatter the blocks? This is the code in the block:
Code
db $42

!horizontal	= 1		; Shatter horizontally? (0 = no, 1 = yes)
!vertical	= 1		; Shatter vertically? (0 = no, 1 = yes)
!kicked		= 0		; Kicked to shatter? (0 = no, 1 = yes)

JMP return : JMP return : JMP return
if !vertical
	JMP main
else
	JMP return
endif
if !horizontal
	JMP main
else
	JMP return
endif
JMP return : JMP return : JMP return : JMP return : JMP return

sprites:
	db $0F,$90	; What sprite numbers to shatter (more may be added) ;$0F = galoomba, $90 = green gas bubble
.end

main:	PHY
	LDY.b #sprites_end-sprites-1
	LDA $9E,x
loop:	CMP sprites,y
	BNE next
	PLY
	
if !kicked
	LDA $14C8,x
	CMP #$0A
	BNE return
endif
	
	%sprite_block_position()
	%shatter_block()
	RTL
	
next:	DEY
	BPL loop
	PLY
	
return:	RTL

if !kicked
	print "Shatters if a certain sprite is kicked at it."
else
	print "Shatters if a certain sprite touches it."
endif
A rather large suggestion, but something I think would be useful for those with large hacks or collabs; the ability to preview and otherwise categorize ExGFX files from within Lunar Magic. The idea comes from a 3rd party addon called 'Super GFX Bypass+' that enables a function to do just that. Here are some previews of what that plugin can do:
https://bin.smwcentral.net/u/32624/exgfxbypassplus.png

The plugin is kind of shotty and doesn't always want to work right, but having a proper version baked into Lunar Magic would be nice. The current addon doesn't always load the correct GFX/ExGFX used in a level, and the labels aren't intuitive. Perhaps an added ability to determine unused ExGFX files for cleanliness would be nice.
Request: ExtSprite Shooter Blocks
Type: Blocks
Short description: Blocks that shoot ExtSprites such as hammers, baseballs, fireballs, dry bones' bone, lotus fire, etc.
Long description: These blocks would shoot extended sprites [listed above]. Direction, frequency, and speed should be adjustable in the .asm file. Having a dormant block as well that activates the ExtSprite block when hit by Mario's fireball would be ideal.
I've been searching for a way to make use of Lunar Magic's extension field, in correlation with a sprites speed, to avoid using multiple sprite entries in pixi but am having no luck.

What I want to do is adjust the speed [among other things] of a sprite based on the value I enter in Lunar Magic's extension field instead of hardcoding it in the .asm file. RussianMan's Flying Coin N' Solid Block do exactly this but I can't seem to figure out how to give that functionality to other sprites.

I am using imamelia's Urchin Disassembly and tried the following edit to the .asm file:

Original
Code
LDA XSpeed,y	;
STA $B6,x	;

Edit (this is the code the flying block above uses)
Code
  LDA !extra_byte_1,x	;take value from Lunar Magic's extra byte (y'know, those number in extension field) for X speed
  STA !B6,x		;


A bit further down in the urchin disassembly are other entries for $B6,x which I have tried changing to !B6,x as well with the same result. I get no errors when assembling, and the sprite still works, but no value I enter in Lunar Magic's extension field will stay and the urchin moves very fast left and right regardless. I figured it would be as easy as using the '!extra_byte_1' define in place of a value to allow me to alter the speed in Lunar Magic, but have had no luck. Is there a tutorial on how to use the extension field when messing in the .asm file of a sprite, or someone that knows what I am doing wrong?
In your main level press the F1 key (or #lm{vex} in the toolbar). This will show your screen numbers. Now find the screen number that your exit is on, and press the #lm{sex} button. Select the screen number from the dropdown. Type your sublevel number into the "Level Destination or Secondary Exit Number" box. You have a few options at this point:
If you leave it as is, it will send you to the main entrance of your sublevel.
Or you can tick the "Use the above value as a secondary exit number" box and use any number you'd like above.
If you choose the second option you'll want to click the #lm{2door} icon in the toolbar. At this point you're presented with plenty of options to use. First, in the top left dropdown, you'll want to select the same number that you wrote in the box in the earlier step. Now on the right hand side type in the level number of your sublevel (and the screen number of the entrance if you know it).
Now go to your sublevel in the main lunar magic window and you should see a mario that says "Secondary Entrance #xyz" (where #xyz is the number you choose for your secondary exit). You can grab this mario in sprite mode and place him where ever you need him to enter from your main level. Now click the #lm{2door} icon again and you can choose mario's actions at the bottom so he enters the level correctly.
I hope this helps
I am also having problems disabling controller input with a block. Hopefully it's okay to post my question here instead of a new thread. Like Golden Yoshi I had tried using Blockreator, but to disable the L and R shoulder buttons when touching the block, with no success. I tried using Mario90's code he posted but also no success. My exact code is as follows:
Code
db $42
JMP LR : JMP LR : JMP LR : JMP Return : JMP Return : JMP Return : JMP Return
JMP LR : JMP LR : JMP LR

LR:
LDA #%00110000	;button(s) you want to disable
;TRB $15
;TRB $16		;If disabling A, X, or Y you probably want to include $17 and $18 as well
TRB $17
TRB $18

Return:
RTL

print "Disables LR Scrolling."


Any ideas on what I'm doing incorrectly? I just want to disable L+R scrolling while touching the block. Thanks
That's a more elegant way of handling the task. Thank you Thomas
If you click #lm{MARIO69} what is your level mode? If you're currently on '0E' change it to '00' and see if that makes a difference.
Does anyone know if it's possible to have overworld pipes that only allow you to access them from unlocked directions? Here is a picture of a section of overworld in my hack:


If I beat the castle and go up to the pipe, I can press down while on the pipe and access the yellow level below it, before I have actually unlocked the yellow level. How can I prevent this from happening? Thank you
All of my pipes were the same number, 0, so I changed all of them to unique numbers (and set their #lm{owlevel} initial level settings flags accordingly) but the pipes will still allow me to go in directions that haven't been revealed yet. I also made sure to start from a fresh save file but got the same results. I am not using any UberASM or custom sprites on the overworld, and the only patches I've used that affect the OW are as follows:
Widescreen Overworld
Overworld Speed Changer
Extended "Extended Overworld Level Names"

The pipe I posted about above has the following unique level settings:


Playing level 10D and getting an exit triggers correctly, but if I go up first to the pipe, and press down I go to the unrevealed level 10F.

Could something else be causing this behavior? (if it matters, the pipe tile I am using is Tile 0x82 in the Layer 1 16x16 Tile Selector)
In all my years using Lunar Magic I've never realized both pipe tiles have different properties. Thank you once again for all your assistance Thomas! Problem solved :)
I'm trying to create reverse versions of the vanilla switch blocks with proper acts like [I have this working] and animation.

I know how to set up the ExAnimation fields in Lunar Magic, but I'm unsure of the required .asm to trigger the Manual Triggers. I have 4 blocks that act as reverse switch palace blocks (solid when switch isn't pressed). I am using the custom blocks by MarioE to achieve this. It's working correctly except the animation doesn't change.

I read in this file that Manual Triggers start at RAM address $7FC070, and I am using Trigger 0, 1, 2, and 3. So I think I use addresses $7FC070 [yellow], $7FC071 [green], $7FC072 [blue], $7FC073 [red]? Then I need to store a byte value of 0 [solid] or 1 [pass through] to each address to switch between the frames of animation. But how do I determine if the correct switch has been pressed and when to execute the .asm to control the block animation?

Hopefully that made sense and any help would be appreciated. Thanks!
Thanks for the tips imamelia! I gave ObjecTool a shot, but it gave me an error when patching to my rom*. I may have been setting it up wrong, so I continued to go the UberASM route. So far the code I have written works for the yellow switch:
Code
; $1F27 green
; $1F28 yellow
; $1F29 blue
; $1F2A red
;
; $7FC0FC (#$01) is for Custom 0 (yellow)
;	  (#$02) is for Custom 1 (green)
;	  (#$04) is for Custom 2 (blue)
;	  (#$08) is for Custom 3 (red)


main:
	LDA $1F28 ;Yellow
	BEQ .Switch
	LDA #$00
	STA $7FC0FC
	JML .Return
.Switch
	LDA #$01  ;Bit value
	STA $7FC0FC
.Return
	RTL

I honestly have no idea how efficient the code is (as I wrote it inspired from other blocks), but it does work. Now my problem is getting the other 3 working in the same UberASM file. I can get them working one at a time, but get weird results when attempting to check the state of more than one switch. Am I missing something obvious? Edit: I actually don't know what you mean by GameMode 13/14. I have a GM14.asm file loaded with UberASM but it was a file included with screen scrolling pipes I believe.
* The error I get with ObjecTool is:
Thanks for the reply MarioFanGamer! I know the code I posted is meant for UberASM. I figured since I already had the custom blocks inserted, the ExAnimation set up, and the graphics ready to go I would use UberASM and not ObjecTool. When I did try ObjecTool however (not with the UberASM from above, but wrong code none the less), I received an error which is at the bottom of my last post. I can't seem to patch ObjecTool.asm with asar to my ROM because it gives me an error about a missing label. The missing label is the same one you mentioned "ClusterExObjRt_NotCustSize" but when I change it to "ClusterExObj_NotCustSize" I still get an error and nothing gets patched. This is also why I choose to go with UberASM.

I will gladly use any method that achieves success, but I don't know what to change in ObjecTool to stop the error, or how to properly check the switch state for all 4 switches in one UberASM file.
Request Name: Pokey
Type: Sprite
Tool: Pixi
Description: The vanilla pokey sprite, but each time you spin jump on it, the head explodes in a puff of smoke, and gets one segment shorter. Variable height and speed independent of Yoshi or not (preferably using the LM extension field) would be added bonuses.
I'm attempting to create a 'Layer 2 Interactive' Vertical Level (level mode 08) and have realized that the left and right facing triangles don't work as they should. I looked around for a fix (patch, rom map, google) with no luck. I did find an old thread about about this same problem but no fix was shared.
After a bit more trial and error in Lunar Magic I also noticed that other layer 2 interact modes such as mode 02, 06, and 1F also didn't work with the triangles. I did discover that while in mode 05, which is a horizontal layer 2 interact mode that Lunar Magic warns you not to use, the purple triangles do work. But the screen is garbled with corrupted graphics. Has a fix for these triangles in layer 2 interact levels been made yet and could be shared?
And to make a block non-interactive with Mario you would set it's act-like settings to 25 in the Map16 Editor.

On the overworld make sure you're in Layer 1 16x16 Mode #lm{ow16x1}. Press 9 on the keyboard to reveal the paths each level will guide mario along (pressing 0 will make them translucent as well). This will allow you to see the directions each level will let mario travel. Now we start selecting the levels. Click the first level you'd like to open the paths for and press the #lm{owlevel} button in the toolbar. The window that pops open will have a bunch of options on the right hand side. You'll want to enable the "Inital Level Settings Flag" for whichever direction you'd like unlocked. Repeat this for all your overworld levels, and you'll have all exits open.

Edit: Do note, this will not reveal any of the events. This will only allow you to travel along the paths in the direction you enable.
Ah okay, well it's easy, but can take some time. While on the overworld you'll want to be in Layer 2 8x8 Editor Mode #lm{ow8x2}. If you scroll the overworld to the right you'll notice a collection of tiles. These are the event tiles, but we will use them to fill in your paths.


Press 9, then 0 on your keyboard to reveal the directions mario can walk and make them translucent. This will make filling in the paths easier. Now just select any of the tiles pictured above, and paste them in the locations your events would normally fill in. Don't forget to also click the Layer 2 Event Editor #lm{owev2}, hold the PageUp key on your keyboard until you've cycled all the way to event 0x77 then highlight all of the events and delete them.

Alternately, and more robust, would be to use the 8x8 Overworld Tile Selector #lm{ow8xsel}. This gives you full access to all available tiles on the overworld and you can create whatever you'd like. Below I have highlighted the tiles used for the beige revealed path events.