Doodle jump game accelerometer question, and platform question

Braydon_SFXBraydon_SFX Member, Sous Chef, Bowlboy Sidekick Posts: 9,273
edited November -1 in Working with GS (Mac)
Hey guys,

I'm making a game like Doodle jump, and i need help with the accelerometer.
I think everyone knows about Doodle Jump, so how do you think you would make the accelerometer work?

Also, about the platforms, in Doodle Jump you can just....Jump right through them, and then when you start falling, you are able to collide with them. Does anybody have any clue on how to do that?

Any help would be great guys, thanks!

Comments

  • jb15jb15 Member Posts: 602
    If you go to the main forum page, there is a search bar--type in Doodle Jump and you can find some templates to use. For instance, you might try toastkitten's template. It's free.
  • Braydon_SFXBraydon_SFX Member, Sous Chef, Bowlboy Sidekick Posts: 9,273
    Okay, but all i need is the jumping through platform. I have everything else set up.
  • Braydon_SFXBraydon_SFX Member, Sous Chef, Bowlboy Sidekick Posts: 9,273
    Okay, that works, but when i hit the platform i accelerate up. I need it so that i go through one, and then come back down, hit platform, etc etc etc. You know?

    Hmm.
  • svnsvn Member Posts: 445
    What's your restitution level? The higher, the bouncier.
  • Braydon_SFXBraydon_SFX Member, Sous Chef, Bowlboy Sidekick Posts: 9,273
    Its not restitution i want. When i hit a platform, i accelerate 1000. So if i just through them, i just keep going and going.
  • tenrdrmertenrdrmer Member, Sous Chef, Senior Sous-Chef Posts: 9,934
    I would try something like this.
    you need something to check if its above or below the platform. So what I would do is make a boolean game attribute well say jumpallowed.

    And then a real Game attribute for the players y position if you don't already have one setup

    You will have rule within a rule

    When Overlap or Collide with Player
    --Attribute self.Position.Y is > game.player.y
    ----Change attribute game.jumpallowed to false
    --Otherwise
    ----Nothing
    Otherwise
    --Change attribute game.jumpallowed to true

    Now in theory that will not change back to true until the player is all of the way through. and then in your jump rule require that game.jumpallowed be true along with your collide of the platform.

    Its possible that wont work since I have not tested it my self but the logic makes sense. Oh and make sure you setup that change attribute to true in the otherwise of the outer rule not the rule inside

    Good Luck
Sign In or Register to comment.