playMaker

Author Topic: less than greater than  (Read 8092 times)

gamedivision

  • Full Member
  • ***
  • Posts: 227
Re: less than greater than
« Reply #15 on: February 18, 2013, 02:25:03 PM »
i dont know why i didn't show this earlier,but i created this 2d game in another game engine and im re-creating it in 3d,i never released this game so this is the movement im trying to re-create with more of a dynamic camera,at 27 secs in you can see the movement of the character with the swipe.

gamedivision

  • Full Member
  • ***
  • Posts: 227
Re: less than greater than
« Reply #16 on: February 19, 2013, 08:25:25 AM »

Solved not sure if it could be better resolve but its done anyway.
first state detects swipe up or down
swipe up, first finds out whether the box is within position to move,then it checks whether the position is bottom or middle,if its bottom it moves to the movemiddle state,which in turn moves the box to zero with a send event giving it enough time to there,that then rolls back to the detect swipe state.
same with all the other positions if its in the middle and you swipe up the position of the box will be zero therefore it can only move in one direction.
on another FSM i have the move towards,that moves the box in one direction continuously.
surrounding the box i have empty game objects,all a distance of 3 away but this could be anything,on the move towards i just drag the target object in and done works great.
i dont know if anyone else maybe has a better option for how this would work.
thanks for the help so far