playMaker

Author Topic: Helicopter game [New problem]  (Read 3896 times)

ArctheLad

  • Playmaker Newbie
  • *
  • Posts: 24
Helicopter game [New problem]
« on: January 02, 2013, 10:03:34 AM »
Hello,

I'm currently working with playmaker to build a game that is similar to those helicopter games where an object moves forwards and, by left clicking and holding, the object moves upwards and then falls again as the button is released. I've got the click set up but I'm having trouble making the object move upwards when the left click is pressed down. Could anyone shed any light on how I do this?
« Last Edit: January 24, 2013, 11:15:45 AM by ArctheLad »

MajorIdea

  • Full Member
  • ***
  • Posts: 131
Re: Helicopter game
« Reply #1 on: January 02, 2013, 12:25:32 PM »
Depends if you want it to be a physics based controller or a standard one. If you want a physics based you need to add a rigidbody to your helicopter, and then have a state connected to your "button down" with a AddForce on the Y axis (to go up). To go forwards would be on the Z axis in Self space.

You'll need to tweek the drag option on your rigidbody to tune the control.

If you dont want a physics based controller do the same but instead of an AddForce, use a translate for example. That should get it going :)

Ticked_Off_Pixel

  • Playmaker Newbie
  • *
  • Posts: 31
    • http://happystar-adventures.tumblr.com/
Re: Helicopter game
« Reply #2 on: January 02, 2013, 04:46:01 PM »
Awesome!

My first (and only so far) game was an helicopter game. Check it here: http://www.kongregate.com/games/ticked_off_pixel/heli-escape

It wasn't made with Playmaker. But it took me a looooooong time to do stuff that now I see could have been done in seconds in Playmaker (which I just purchased).

I used AddForce to lift and lower the helicopter, without gravity. At the time I was having a hard time with gravity, I don't know why.

If you need more tips, please let me know.  8)
« Last Edit: January 02, 2013, 05:24:26 PM by Ticked_Off_Pixel »

ArctheLad

  • Playmaker Newbie
  • *
  • Posts: 24
Re: Helicopter game
« Reply #3 on: January 03, 2013, 06:11:34 AM »
Thanks for the help, adding force has really helped. I couldn't believe I didn't see it before now. >.<

Thanks again though :]

ArctheLad

  • Playmaker Newbie
  • *
  • Posts: 24
Re: Helicopter game [New problem]
« Reply #4 on: January 24, 2013, 11:15:15 AM »
Hey forum,

Since learning how to build this helicopter game I have gone through some various idea, from the standard 2D style, to a 3D style forward moving type of game.

I have a new problem right now, and it is increasing the efficiency of the game and building it. (Atempted to build a 70 level game with a start and end and it proved to be time consuming. So, I looked into generating infinited blocks.

I found the M2H example and the platformer in there proved to be a brilliant starting point in getting to work. (Thank you Jean for posting that) However, feeling as though I almost have it cracked, I've hit a wall.

The problem in question, I have the fsm set up from the M2H Platformer, (Game 2 in the M2H game folder) and I have slowly been re-working it to create walls. However, it seems to only generate platforms one on top of each other and reloads the level without any actual collisions. If this makes any sense, could anyone shed some light upon it?