@Aku_Aku: Oh sorry, yes right. param1 is not used xD This is only an example. I dont need this code for something. Iam very interested, how I can manage that, if I need a result of a function, that contains a while loop and need more time to finish.
The problem is, that the script dont waiting for the other functions.
My only idea is to make a global variable, save the result of the second function in it and wait in the first function for a value.
Or can I use wait_for for that? my_value = sec_func(50); must wait for the sec_func to complete. You know what i mean?
@Reconnoiter: Yes of course. Thats only an example. This -> my_value = sec_func(50); is important for me. The script should be wait for a result of a second function. It gives me an incorrect result, cause the loop need more time to run...
Oh i hope you understand
Sorry for my bad english xD