LaffinJoker
New member
So I followed this:
LDA Object_y_hi,x
CLC
ADC #$04
STA tempB
LDA Object_vulnerability,x
AND #%10000000 ;; skip top collision set?
BEQ +notCrouching ;; no, skip
LDA tempB
CLC
ADC #$03 ;; 3 pixel lower than the normal shooting position
STA tempB
+notCrouching:
Thank you a million. I got it working with your code, I had to change the ADC #$03 to ADC #$08 but my character is 3x4 sprites so I’m not using the original ADC #$04 setting. Thank you very much for helping me break through my stuck point.Hmmm. In your shoot script, check the the "skip collision" action step flag is set (= if the player is "crouching")... in that case, change the value used for the vertical position of the projectile.
In the script, you will see something like:
In that variable the vertical position value is set.Code:LDA Object_y_hi,x CLC ADC #$04 STA tempB
So, after those lines... add a code like that:
Code:LDA Object_vulnerability,x AND #%10000000 ;; skip top collision set? BEQ +notCrouching ;; no, skip LDA tempB CLC ADC #$03 ;; 3 pixel lower than the normal shooting position STA tempB +notCrouching: