Hello, I'm doing a "Jump" script, but I have a problem.
Following the script (situation)
==aligned==
1 stone: (-5, -4, -3, -2)
2 stones: (-5, -4, -3)
3 stones: (-5, -4)
4 stones: (-5)
5 stones: (Not Work)
==with spaces==
stone, space, stone: (-5, -4)
stone, space, stone, space, stone.... (not work)
Could anyone help me?
Download Demo: https://drive.google.com/file/d/0B3d2YApCS0RxczllMmcyRndHVDA/view?usp=sharing
class Game_Player < Game_Character alias tiagoms_jump update def update tiagoms_jump if Input.trigger?🙂C) if stopping? jump end end end def jump case @direction when 4 # Left if passable?(@x-5,@y,@direction) print "-5 pass \n" end if passable?(@x-4,@y,@direction) print "-4 pass \n" end if passable?(@x-3,@y,@direction) print "-3 pass \n" end if passable?(@x-2,@y,@direction) print "-2 pass \n" end if passable?(@x-1,@y,@direction) print "-1 pass \n" end if passable?(@x,@y,@direction) print "0 pass \n" end if passable?(@x-5,@y,@direction) or passable?(@x-4,@y,@direction) or passable?(@x-3,@y,@direction) or passable?(@x-2,@y,@direction) or passable?(@x-1,@y,@direction) or passable?(@x,@y,@direction) else print "Not Work \n" end end endend
==aligned==
1 stone: (-5, -4, -3, -2)
2 stones: (-5, -4, -3)
3 stones: (-5, -4)
4 stones: (-5)
5 stones: (Not Work)
==with spaces==
stone, space, stone: (-5, -4)
stone, space, stone, space, stone.... (not work)
Could anyone help me?
Download Demo: https://drive.google.com/file/d/0B3d2YApCS0RxczllMmcyRndHVDA/view?usp=sharing
