Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

319
Visualizações
How can I make my game character stop on the ground level

I am struggling a bit with a piece of code. The point is that a "game character" should jump when the spacebar is pressed (to 100 px above floor-level) and fall down after. But in my case, the game character jumps once to the right height, falls to the ground and then jumps again and fly up to the sky, just to disappear. Each time I press the spacebar it comes back, just to jump another time to the sky. Cam someone just looks at my code and give me a hint of what I am doing wrong?

the code

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

if (isFalling == false){
  gameChar_y >= floorPos_Y;
}

It seems like the problem might be here. That's just a boolean expression and you're not modifying anything.

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda