Melee Object is off when attacking in the air

drexegar

Member
This has nothing to do with the gravity, but while jumping and attack with melee object, it 8 pixels higher than normal when it get created. I'm using Dale's melee object from the community tutorial.

If there is no solution, Is there a way I can go into the jump script and just get the melee position and just add 8 pixels to it?

Just get the objects ID, then tell the object to go down 8 pixels, I can always use a variable too to check for jumping or falling if it comes to that.
 

dale_coop

Moderator
Staff member
Yep... you could also check if the player is in the air:
Code:
    LDA Object_physics_byte,x
    AND #%00000001 ;; if is in air
    BNE playerIsNotInAir

Or another solution, is not allow attack when jumping :p
 

drexegar

Member
dale_coop said:
Yep... you could also check if the player is in the air:
Code:
    LDA Object_physics_byte,x
    AND #%00000001 ;; if is in air
    BNE playerIsNotInAir

Or another solution, is not allow attack when jumping :p

Thanks will keep this in mind. i need to attack in the air.
 
Top Bottom