When calling a function with a parameter set, using a wait inside the function clears it's parameters.
Is this normal?
Attach a Capx
Description of Capx
This demonstrates that a parameter zeros after a system wait.
Steps to Reproduce Bug
After a system wait, function param always returns 0.
I didn't expect to loose my parameter after a system wait.
Operating System and Service Pack
Construct 2 Version ID
It's a known "feature" that function parameters only exist for the function call, and not into the next tick.
The reasoning is the same function can be called multiple times with different params, within the same tick.
Best solution is to store the data in a global.
Develop games in your browser. Powerful, performant & highly capable.
per tick, gotcha, ty. It's now officially known to me also.
I'm moved my pauses (using wait for signal within it's own function) and refined my code.
I got to many globals already man
Closing as not a bug. As newt described, "Wait" doesn't itself clear the function parameters, it's just by the time the next action runs the function call has ended.