So I'm working on a conveyor belt tile and here's the current code:
and I'm kinda stumped - it shoots the player like a cannon, instead of a steady movement. I know that the problem is that I change the speed based on previous speed, but if I'd just rigidly set it, the player wouldn't be able to move in order to beat the conveyor/move faster along it. Any ideas?
Code:
;conveyor belt - left
;pushing accumulator to the stack to avoid memory corruption just in case
pha
CPX player1_object
BNE notPlayerConvL
LDA Object_h_speed_hi,x
SEC
SBC #$01
STA Object_h_speed_hi,x
notPlayerConvL:
;pulling back the acc.
pla
and I'm kinda stumped - it shoots the player like a cannon, instead of a steady movement. I know that the problem is that I change the speed based on previous speed, but if I'd just rigidly set it, the player wouldn't be able to move in order to beat the conveyor/move faster along it. Any ideas?