platform/actor & jumping

paulofuertespaulofuertes Member Posts: 24
edited September 2012 in Working with GS (Mac)
Hello all,

after looking around and trying all I could, i don't think I'm getting somewhere
I have two issues:

1. I made the double jumps, and they do work fine (I think):
- if I double tap quick, it jumps abit high, but thats fine!

This is the problem:
if I tap (1jump) and then when the actor is falling (almost touching the platform) and I tap again for the second jump, it barely jumps (maybe 1 pixel up?)
[this is what i have]
----------------------
game.Jump =0

actor: jump button
if gamejump <= 2, then change attribute game.jump to game.jump+1


actor: player
gravity 270 down, acc 400

rule. if collides with wall,change attribute game.jump to 0
rule. if game.jump = 1, change attribute motion.linVel.Y to motion.linVel.Y+250
rule. if game.jump = 2, change attribute motion.linVel.Y to motion.linVel.Y+250

actor: wall
if collides with player, change attribute game.jump to game.jump=0
-----------------------

2. When my player collides with the wall (platform), every single time I jump and it collides, the wall moves down. So, if I jump alot, the wall will end up disappearing off the screen, with my player (which doesnt moves left/right, only jumps)
I tried constraining attributes, and also adding like, if collapses with player, move wall alittle up with the position.y, guess the logic of my "code" was bad.

any ideas?
thank you veeery much!


--edit:
downloaded a template and could fixed both.. sorry for the post

Comments

  • GamexsGamexs Member Posts: 35
    Hello , Can any one here let me explain Jump rule here for making actor jumping
  • joshiwujoshiwu Member Posts: 207
    Its in the calfs. lololl jk. put the rule for the second jump in a timer? so that the opportunity for a double jump expires after a moment. so "for 2 second: if jump pressed and game.jump=2 change lin.vel"
Sign In or Register to comment.