(shouting)

ASM: Request, help and general discussion

Anthrax 2 Multiply Themodynamics
User avatar
swirlybomb
a bomb that is swirly
Posts: 65
Joined: 12 years ago
First name: Swirlus Bomberton
Location: The Canadas

Re: ASM: Request, help and general discussion

Post by swirlybomb »

If you need to know (you probably do), the intro encompasses levels/sublevels C5, 1FE, and 1FD (1FE is the one with the enemies). I don't recall what the title screen level is offhand, but I know it's none of these, so there shouldn't be any issues.
anonymousbl00dlust wrote:All the obstacles in my level can be beaten on the players first attempt without any 'future predicting'.
Image
limepie20
Posts: 0
Joined: 14 years ago
Location: Doesn't Matter

Re: ASM: Request, help and general discussion

Post by limepie20 »

I just want to get a sense of what you are doing. What are you gonna use the extra sublevels for? I thought the sublevel I tested alone was great as the intro level.
User avatar
swirlybomb
a bomb that is swirly
Posts: 65
Joined: 12 years ago
First name: Swirlus Bomberton
Location: The Canadas

Re: ASM: Request, help and general discussion

Post by swirlybomb »

Eh?? I'm not sure where the confusion comes in, but here's the entirety of the intro (spoilered because why not):
The first room (C5) is the very sketch-looking walls and Iris in the background, with text floating above.

The second room (1FE) is the whole Fission Mailed portion where Demo can't be harmed by enemies and causes things to crumble under her touch.

Then the third room (1FD) drops her into a pit of lava but the 'VIDEO GAMES ?!' message pops up right before she falls in and puts her on the world map.
It's been that way since the start, and I did reserve those sublevels when I started working on this. Did you only see the first room when you played it?
anonymousbl00dlust wrote:All the obstacles in my level can be beaten on the players first attempt without any 'future predicting'.
Image
limepie20
Posts: 0
Joined: 14 years ago
Location: Doesn't Matter

Re: ASM: Request, help and general discussion

Post by limepie20 »

I guess I did only see the first room?
Whatever, your plan sounds find. I just wanted clarification.
User avatar
Diortem
Posts: 0
Joined: 13 years ago

Re: ASM: Request, help and general discussion

Post by Diortem »

Hi Swirly,

I made the following levelASM. Place this in the the levelcode.asm under "level1FE:" and the player will be able to interact (e.g. jump on enemies), but cannot get hurt and enemies will die when having contact with Demo. I played some trickery here to make it work without modifying any of the standard sprite routines. Therefore, you should test it on all the sprite types you use. In the current level design they're all regulars so I don't expect any troubles.

Code: Select all

  LDA #$11
  STA $1497 ; Mercy mode ON -> No hurt possible
  STA $1490 ; Star man ON
  LDX #$0B        ; Handle all sprites (set to max)
.Sprite
  STX $15E9       ; Set X to sprite index in RAM
  LDA $167A,x     ; \ temporarily store SpriteTweaker 
  PHA             ; | 
  AND #$7F        ; | 
  STA $167A,x     ; / use default interaction here

  LDA $14C8,x     ; \ Prevent crazy loops when
  CMP #$08        ; | sprite not in regular state
  BNE .NextSprite ; / only check if state == $08
  JSL $01A7DC     ; \ Default Collision / Interact Routine
  BCC .NextSprite ; / return with Carry flag -> if set contact
  LDA $1662,x     ; \ Just to make sure any
  ORA #$80        ; | sprite will die and 
  STA $1662,x     ; / not glitch fixed on screen
.NextSprite
  PLA
  STA $167A,x
  DEX             ; And continue doing that until  
  BPL .Sprite     ; you've  handled every sprite.
  STZ $1490 ; Star man OFF
  RTS
Basically, it fixates the 'mercy' invincibilty on a fixed frame so the player doesn't flash, and during the level asm it check contact with all sprites, while temporarily enabling star power and setting the default interact sprite tweaker bit. This was the simplest way to kill any sprite in a regular fashion without modifying too much code.


Note: if you wish, you can use 1 copy of the custom fake goal tape sprite, which I use in my own level (custom sprite 76).
It will morph into an enemy if the player doesn't hit the tape and only has an SFX when hit. Just take care as the tape can spawn various standard sprites depending on
A: x-placement
B: the 'extra' bit setting
C: randomness
If you have chucks in the sprite set, which you do, there won't be GFX issues with misplaced sprites. So it should work fine.
User avatar
swirlybomb
a bomb that is swirly
Posts: 65
Joined: 12 years ago
First name: Swirlus Bomberton
Location: The Canadas

Re: ASM: Request, help and general discussion

Post by swirlybomb »

...Well, it appears that I can't figure out how to put either of those things in :oops: Or at least, the methods I assumed would work didn't, so I may just be on the wrong track entirely.

I may need step-by-step instructions on this one, if possible.

While I'm at it, is removing the HUD for all the intro sublevels something that can be done within Lunar Magic, or is that also ASM-flavored?
anonymousbl00dlust wrote:All the obstacles in my level can be beaten on the players first attempt without any 'future predicting'.
Image
User avatar
Diortem
Posts: 0
Joined: 13 years ago

Re: ASM: Request, help and general discussion

Post by Diortem »

Have you patched the rom before? If not, I'll send you a PM with some more instructions. It's not that hard, but it can require some research to find which steps are required.

For the other item: Coincidently, I am working on removing the HUD in the treasure room as well; see the treasure chest topic. I found out the problem why setting $0D9B to $01 doesn't work (as suggested on smwcentral.net), but I'll need some more time to get it working. <technical details>The core of the problem is that the bottom bit is only evaluated if the top bit is set (e.g. $81 or $C1), but then you enter the Bowser/Koopa battle mode which is not intended.</technical details>

I'm going to create a small patch which does allow disabling the HUD in normal level modes. So once that is done, I can help you remove the HUD with ease.
User avatar
spitznagl
­­­­~1.68e+7 real colors
Posts: 0
Joined: 12 years ago
Location: .qc.ca/

Re: ASM: Request, help and general discussion

Post by spitznagl »

A couple of questions for the pros.

Is it possible to get rid of the small vertical scrolling offset? Demo isn't always centered vertically. When you go up and then down or the other way around, the camera doesn't follow for a couple of pixels. That means that you're not at the same height when you fall on a block and when you jump on it from below.

My level is vertical and has an invisible water line on layer 2, which is set to H-Scroll: None, V-Scroll: None. The result is unlimited mid-air jumping until you stop. The problem is that when you land, you can be either on ground or in water because of the scrolling. Could the scrolling be changed to work in direct relation to Demo?

Also, I made a 32x32 pixels animated gear that acts like four munchers. Because the object is spherical and the level is vertical and compact, the square hit-box is a problem. It's fine with the smaller single tile version, but would it be possible to have the four tiles act like slopes and be lethal at the same time. I only mean for the hit detection. Demo doesn't have to be able to walk on them since the level is designed with no power-ups.
ImageImage
User avatar
Argumentable
the biggest shit
Posts: 690
Joined: 14 years ago
Location: A butthole
Contact:
https://argu.talkhaus.com/

Re: ASM: Request, help and general discussion

Post by Argumentable »

Not that I actually have the solution, but you can have the screen always scroll with mario with a hex edit, so it's probably able to be patched (I still know nothing of patches or patching)

I used it for a while in ARH until I realized how disorienting it was in non-vertical levels with vertical scroll
I'm on Youtube andTwitter and Discord so say hi to me on there cause I don't really post here also I have sigs off so I can make my sig as ugly as I want and it won't bother me this is my sig btw
User avatar
Diortem
Posts: 0
Joined: 13 years ago

Re: ASM: Request, help and general discussion

Post by Diortem »

For the second thing, I dunno exactly how your gear looks like, but can't you just make the top two tiles behave like an empty space and the bottom two as a muncher? That way there is some leeway, cause unless your graphic demands it I doubt anybody will bother the small overlap with the top tiles. That would be the easy way, the other might be possible. But then you'd need something to check that they're actually making contact with the slope before calling the Hurt routine.
User avatar
spitznagl
­­­­~1.68e+7 real colors
Posts: 0
Joined: 12 years ago
Location: .qc.ca/

Re: ASM: Request, help and general discussion

Post by spitznagl »

Diortem: They're all over the place. The fish (Placeholder graphic. It'll be some sort of propeller) is a key and with the layer 2 water, you can move horizontally at will while holding it and you can jump from mid-air. There is a lot of diagonal jumping involved and I keep hitting the corners.

Image

I could adjust the layout though if doing the modification isn't possible or worth the time, but I think that even with more room, the square hit-box would still cause some annoying deaths. It's not just like clearing a normal jump, but rather navigating obstacles with a constant horizontal speed.

Argumentable: Glad to learn that it should be possible, but I also do not know how to hex edit. Hopefully someone can help because of the two points, the vertical scrolling is the thing that needs to be changed the most.

I'll post a link to the level in the testing thread later today.
ImageImage
User avatar
Diortem
Posts: 0
Joined: 13 years ago

Re: ASM: Request, help and general discussion

Post by Diortem »

Ah I see, that's a very nice concept you have there! I don't have too much experience with block asm, but I was thinking of the following concept at the moment:

Use the diagonal triangle block as a base; it already has a 45degree slope and then use $72 (Mario in Air flag) in the block's ASM to check whether he's actually making contact. Based on that JSL "Hurt" or do nothing. I'm not quite sure how the game handles this, though.
User avatar
spitznagl
­­­­~1.68e+7 real colors
Posts: 0
Joined: 12 years ago
Location: .qc.ca/

Re: ASM: Request, help and general discussion

Post by spitznagl »

Thank you for the info. I will need to learn block asm first, but at least I have something to try.
ImageImage
User avatar
Chdata
Posts: 11
Joined: 14 years ago
Location: Computer Chair

Re: ASM: Request, help and general discussion

Post by Chdata »

It doesn't sound hard probably just set layer 2's y to demo's y whenever she touches a border with all vert scrolling disabled in level settings.
Image
Trouble with a capital COW.

<math>\tan{A}\sin{N}</math>
User avatar
AUS
Toni#4796
Posts: 483
Joined: 14 years ago
First name: Toni
Pronouns: they/them/their
Location: アース

Re: ASM: Request, help and general discussion

Post by AUS »

I'm trying to make a level where--(I'm not sure if I even need to make this level for anything, but I wanted to make a level anyway)--you can't jump. How do I ASM out the ability to jump?
Image
"oh no my best friend was replaced by a evil demon shadow monster"
"argh i am the evil shadow monster demon shadow"
Vip is pronounced "Beep"
nostalgic realtime nitroid let's play playlist
limepie20
Posts: 0
Joined: 14 years ago
Location: Doesn't Matter

Re: ASM: Request, help and general discussion

Post by limepie20 »

This might be it. I'm not sure.

Code: Select all

	REP #$20
	LDA #$8080
	TSB $0DAA
	TSB $0DAC
	SEP #$20
User avatar
AUS
Toni#4796
Posts: 483
Joined: 14 years ago
First name: Toni
Pronouns: they/them/their
Location: アース

Re: ASM: Request, help and general discussion

Post by AUS »

Yeah that did it. Thanks!
Image
"oh no my best friend was replaced by a evil demon shadow monster"
"argh i am the evil shadow monster demon shadow"
Vip is pronounced "Beep"
nostalgic realtime nitroid let's play playlist
User avatar
anonymousbl00dlust
Posts: 131
Joined: 14 years ago
Location: West Korea

Re: ASM: Request, help and general discussion

Post by anonymousbl00dlust »

Time for me to drop another giant wall of code into this thread.

EDIT: I just realized... that gigantic code is probably annoying/unreadable inside that code table thing. Here's a link instead Free Ipod /EDIT

This is the windowing code for the opening cinematic to the final level. The first subroutine shoots a (solid color) laser into the sky. It's just a skinny rectangle with a upsideown-triangle base. It's width increases, shakes a little bit, then decreases until its gone. The second subroutine is the wormhole thing I keep going on about. The final subroutine just fills the whole window permanently (player has gone through the wormhole).

I'm wondering if the laser part is really necessary. I don't really know how I can embellish it graphically. I'm doing the aurora thing for the wormhole using a gigantic 48 tile sprite, but at least it's somewhat simple because the wormhole doesn't change shape or size.

So yeah I'm wondering what people think I should do. How do I approach this?
Last edited by anonymousbl00dlust 11 years ago, edited 1 time in total.
alex2 wrote:It's all a matter of taste.
User avatar
anonymousbl00dlust
Posts: 131
Joined: 14 years ago
Location: West Korea

Re: ASM: Request, help and general discussion

Post by anonymousbl00dlust »

alex2 wrote:If it's too much of a hassle, then don't bother.
Well, it isn't so much about hassle on my end as it is about time on your (the talkhaus's) end. I don't mind the tedium if it means a better final product. My main concerns are a) will it look good/add to the experience, and b) will it lengthen the amount of time before I can actually submit the level.

the answer to both is yes, so it boils down to weighing the magnitudes of said yeses
alex2 wrote:It's all a matter of taste.
User avatar
AUS
Toni#4796
Posts: 483
Joined: 14 years ago
First name: Toni
Pronouns: they/them/their
Location: アース

Re: ASM: Request, help and general discussion

Post by AUS »

Is it possible to get a similar code but disabling running (and picking up items)? So that if you're holding either of the run buttons and touch a shell, it just flies off.
Image
"oh no my best friend was replaced by a evil demon shadow monster"
"argh i am the evil shadow monster demon shadow"
Vip is pronounced "Beep"
nostalgic realtime nitroid let's play playlist
User avatar
AUS
Toni#4796
Posts: 483
Joined: 14 years ago
First name: Toni
Pronouns: they/them/their
Location: アース

Re: ASM: Request, help and general discussion

Post by AUS »

It keeps throwing "invalid opcode or command: TRB #$40" ..
Image
"oh no my best friend was replaced by a evil demon shadow monster"
"argh i am the evil shadow monster demon shadow"
Vip is pronounced "Beep"
nostalgic realtime nitroid let's play playlist
Zygl
Posts: 616
Joined: 11 years ago

Re: ASM: Request, help and general discussion

Post by Zygl »

AUS wrote:It keeps throwing "invalid opcode or command: TRB #$40" ..
That's because it should be LDA #$40 and TRB $15. Or AND #$BF instead of TRB #$40, either one should work if I have any clue what I'm talking about.
User avatar
AUS
Toni#4796
Posts: 483
Joined: 14 years ago
First name: Toni
Pronouns: they/them/their
Location: アース

Re: ASM: Request, help and general discussion

Post by AUS »

Now no key works. :lol:
EDIT: No, this was my fault this time.
EDIT2: Except now the code is not working at all.

I don't know if that's because the code is bad, or because I'm also using limepie's code from above-
REP #$20
LDA #$8080
TSB $0DAA
TSB $0DAC
SEP #$20
(to disable the ability to jump..by the way, when the code you gave didn't work, this code still did)

I don't even know if it could be because of that or not. :P
Image
"oh no my best friend was replaced by a evil demon shadow monster"
"argh i am the evil shadow monster demon shadow"
Vip is pronounced "Beep"
nostalgic realtime nitroid let's play playlist
Zygl
Posts: 616
Joined: 11 years ago

Re: ASM: Request, help and general discussion

Post by Zygl »

It could be that you can't actually manually clear bits in $15 or $17, I actually haven't tried it myself. Though actually looking at limepie's code there I just noticed there are controller disable flags in the RAM map. So you'll probably want to mess with those.

Code: Select all

REP #$20
LDA #$4040
TSB $0DAA
TSB $0DAC
SEP #$20
Yeah, it's actually the exact same code but with #$4040 instead of #$8080.

e: Also I apparently really like the word "actually."
User avatar
spitznagl
­­­­~1.68e+7 real colors
Posts: 0
Joined: 12 years ago
Location: .qc.ca/

Re: ASM: Request, help and general discussion

Post by spitznagl »

Does anyone know if there's an easy way to change the camera offset of the vertical scrolling when falling in one level?

For the second section of my level I had planned a skiing segment, but even with slower falling speed, Demo is too close to the bottom of the screen to dodge the obstacles in time.

I already know a little bit about block asm, but I couldn't figure any way to do it by looking at the ROM and RAM maps on smw central.
ImageImage
Locked