-
Notifications
You must be signed in to change notification settings - Fork 68
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
menu example panics with can not convert float seconds to Duration: value is negative
#41
Comments
The panic happens because:
I feel like EDIT: I guess any return value between 0.0 and 1.0 would be "technically true" and would make the math work in |
Nevermind, not fixed by #38 because progress is still implemented the same way. Though as mentioned, tick needs to be rewritten anyway to not use progress so this will go away. |
Note to self: write a test for this when rewriting sequences. |
I don't know if this should go in a separate issue, but somehow in my game where I'm using a fork of As a workaround, I'm changing the line to |
Interesting. What's the panic about exactly? Is |
Yes, it is. I've only seen it happen once so it seems to be pretty rare. |
In my case, it is not rare, I hit by the panic each time run
|
A work around, set start_time_ms to a small value, e.g
|
I assume you're referring to the "can not convert float seconds to Duration: value is negative" panic (original panic mentioned in this issue, guaranteed to occur in the menu example), and not the "overflow when subtracting durations" panic (mentioned in #41 (comment), seen rarely in other code). |
@benfrankel ah, yeah, different panic, "'can not convert float seconds to Duration: value is either too big or NaN'" |
Actually I think a |
Make `Delay::new()` panic if a zero duration is passed as argument. Fix the `menu` example to skip inserting a `Sequence<Transform>` containing a zero-duration `Delay`. Bug: #41
I'm closing this issue because the |
@Gyrobifastigium FYI this is probably a bug in #39
This is blocking #34
The text was updated successfully, but these errors were encountered: