#Can somebody explain me why the jump pad is not working
1 messages · Page 1 of 1 (latest)
extends Node2D
@export var force = -500.0
func _on_area_2d_area_entered(area):
if area.get_parent() is Player:
area.get_parent().velocity.y = force
that's the jump pads script
I think I've already tried all of the tutorials onn yt and nothing is working
but this one is form here
Hope you guys enjoy the tutorial, and as always thank you for the support, I'm gonna try upload a bit more again, have a nice day everyone!
Come watch me stream!
https://kick.com/gamedevknight
Endless Nite - https://gamedevknight.itch.io/endless...
Buy me a coffee - https://ko-fi.com/gamedevknight
Discord - https://discord.gg/UnKwdJrEdP
Inst...
have you reproduced the tutorial verbatum before applying it to your own game?
yeah
I don't think you need to specify area.get_parent() to access the inherited velocity property (you could try putting the jump-pad logic in the jump pad, not via signal to the player?). also how come force is negative, wouldn't that force the player downwards?
up is -y in godot
- does the player have an area2d?
- is this signal correctly connected?