Apprendre
Bibliothèque de moteurs
task

*Ce contenu est traduit en utilisant l'IA (Beta) et peut contenir des erreurs. Pour consulter cette page en anglais, clique ici.


Résumé
Fonctions
spawn(functionOrThread: function | coroutine,...: Variant):coroutine
defer(functionOrThread: function | coroutine,...: Variant):coroutine
delay(duration: number,functionOrThread: function | coroutine,...: Variant):coroutine
wait(duration: number):number
cancel(thread: coroutine):()

Référence API
Fonctions
spawn
task.spawn(
functionOrThread:function | coroutine, ...:Variant
Paramètres
functionOrThread:function | coroutine
...:Variant
Retours

defer
task.defer(
functionOrThread:function | coroutine, ...:Variant
Paramètres
functionOrThread:function | coroutine
...:Variant
Retours

delay
task.delay(
duration:number, functionOrThread:function | coroutine, ...:Variant
Paramètres
duration:number
functionOrThread:function | coroutine
...:Variant
Retours

desynchronize
task.desynchronize():()
Retours
()

synchronize
task.synchronize():()
Retours
()

wait
task.wait(duration:number):number
Paramètres
duration:number
Valeur par défaut : 0
Retours

cancel
task.cancel(thread:coroutine):()
Paramètres
thread:coroutine
Retours
()

©2026 Société Roblox. Roblox, le logo Roblox et Powering Imagination font partie de nos marques déposées aux États-Unis et dans d'autres pays.