Como podría hacer que un botón funcione solo cuando el personaje esta cerca?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By TheFirstHD

como podría hacer que un botón funcione solo cuando el personaje se acerque

You should provide an english and and spanish translation, just so that your question has a better chance of being answered

Debe proporcionar una traducción al inglés y al español, solo para que su pregunta tenga más posibilidades de ser respondida.

Snail0259 | 2021-07-25 03:21

:bust_in_silhouette: Reply From: Snail0259

English:
You could get the distance from the sprite and the button, then disable the button when it passes a certain threshold.

Español (lo siento, esto fue traducido del inglés):
Puede obtener la distancia desde el sprite y el botón, luego deshabilitar el botón cuando pase un cierto umbral

Thanks a lot

TheFirstHD | 2021-07-25 13:56