![]() |
Attention | Topic was automatically imported from the old Question2Answer platform. |
![]() |
Asked By | dezekeerjoran |
![]() |
Old Version | Published before Godot 3 was released. |
how to make an event happen when a certain velocity is hit?
You’ll have to be more specific. What velocity are you interested in? One of your own or the one reported by get_linear_velocity()
? Also what axis are you interested in? X or Y? Or did you want to measure magnitude? Then what do you consider an “event”? A custom signal?
avencherus | 2017-03-01 10:49
It sounds like an if
statement.
if velocity == x: # or , >=, <=, <, >
do_something()
But maybe you want something else.
Give us more details, as avencherus said.
eons | 2017-03-01 11:35
when the player( rigidBody ) if falling so -y axis and hits 0,-200: the scene will reload. oke?
dezekeerjoran | 2017-03-01 14:43