la respuesta ya ye la di en otros temas.
Tambien se pueden crear hilos. aunque no estables al 100%
$Handle1 = DllCallbackRegister("hilo", "int", "ptr")
Func CreateThread($Handle, $struct)
$return = DllCall("kernel32.dll", "hwnd", "CreateThread", "ptr", 0, "dword", 0, "long", DllCallbackGetPtr($Handle), "ptr", DllStructGetPtr($struct), "long", 0, "int*", 0)
Return $return[0]
EndFunc
$Struct1 = DllStructCreate("Char[200];int")
DllStructSetData($Struct1, 1, 10)
CreateThread($Handle1, $Struct1)
MsgBox(0x40, "Normal", "Hola mundo")
Func hilo($x)
$y = DllStructCreate("char[200];int", $x)
MsgBox(0x40, "Desde hilo", "Soy un hilo")
EndFunc
saludos