Skip to content
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

Regression in 1.3.0 SynchedTimeSource #6

Open
MeFisto94 opened this issue Dec 30, 2018 · 2 comments
Open

Regression in 1.3.0 SynchedTimeSource #6

MeFisto94 opened this issue Dec 30, 2018 · 2 comments

Comments

@MeFisto94
Copy link

In an attempt to update the sim-eth-es example to support SimEthereal 1.3.0, I've stumbled across the breaking changes introduced in c6272ff
The Problem is that EtherealClient#getTimeSource has a return type of "TimeSource" where stateReciever clearly has a RemoteTimeSource (implementing SynchedTimeSource) as it's timeSource.

I guess it's only a simple overlooking, but it would be nice to fix this so a cast is not necessary.

@pspeed42
Copy link
Contributor

What cast? What breaking change? Can you be more specific?

Which code is not ok with a plain TimeSource? And if your answer is the stats debug state... then that state should be casting because it's trying to do non-standard under-the-covers views of stuff.

@MeFisto94
Copy link
Author

Well the "Breaking Change" was that the TimeSource Interface was split into TimeSource and SynchedTimeSource and yeah, the TimeSequenceState requires getOffset(),

however I am not sure that casting is the answer because StateReciever always has a RemoteTimeSource so it's guaranteed to be a SynchedTimeSource.
Any other code might also want to rely on the offset (maybe some sort of prediction), but that's out of my knowledge for now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants