#18 Limiter dashboard feedback Implementation, #14 debug fix#21
#18 Limiter dashboard feedback Implementation, #14 debug fix#21byBlurr wants to merge 8 commits into
Conversation
- Needs testing, no iracing install
- Moved limiter lights out of rpm for loop. - Tested by reverting if statement, not tested with iRacing client open.
|
I think I played around with irsdk_pitSpeedLimiter back then trying to do something similar, but it didn't quite work the way I expected. Please let me know once someone has had the chance to test this and I'll be happy to review/merge. |
| D2D1_ELLIPSE l6 = { float2(r2ax(0.5f - ww / 2 + (6 + 0.5f) * ww / 8),r2ay(0.065f)), r2ax(0.007f), r2ax(0.007f) }; | ||
| D2D1_ELLIPSE l7 = { float2(r2ax(0.5f - ww / 2 + (7 + 0.5f) * ww / 8),r2ay(0.065f)), r2ax(0.007f), r2ax(0.007f) }; | ||
|
|
||
| int frames = 60; |
There was a problem hiding this comment.
Would be nice if this was time-based rather than counting frames. I think there's some "blinking" logic in other places in the code.
There was a problem hiding this comment.
This is the only thing left to do for this implementation now. I am unsure where blinking has been used elsewhere? I'll take another skim through.
There was a problem hiding this comment.
I might be misremembering about blinking used elsewhere. It was in there at some point for something, but I might have removed it.
There was a problem hiding this comment.
For now I have opted for using the current tick count to work out if the lights should be on or off. Only thing is that I had to use a magic number (16) because the tick count was jumping 16 for every render call, however on odd occasions it would jump 17. There's definitely better ways of doing it, but this illuminates the need for incrementing a variable every tick.
The main rpm lights are moved out of the pit limiter if statement scope now, so this shouldn't affect performance at all if not using the limiter. I have fully tested this now on a laptop with lowest possible graphics settings, if anything would have performance issues it is this laptop. Tested on both 30Hz and 60Hz. I believe this is ready for merge.
- Moved draw into its own for loop - Changed to only draw outline on LEDs, allowing RPM to still be displayed on LEDs when limiter is enabled - Gear indicator background flashes green in sync with LED outline
|
I also committed a small change adding a lap counter to the standings overlay. So this PR also covers issue #9 |
|
I am having no luck with fixing my issue #22... I am unable to diagnose it and therefor unable to test any features. I will leave it as is for now for someone else to test before I make any further changes. |
- No longer crashes in debug mode
- Changed how timing works for pit limiter feedback - Would prefer to not use as many magic numbers, but I am limited by inconsistency in tick numbers
RPM lights flash yellow if the limiter is enabled. flashes on for half second, off for half second.
I have tested this by reverting
if (!(ir_EngineWarnings.getInt() & irsdk_pitSpeedLimiter))but have not tested it by enabling the pit limiter in sim. I do not have access to my pc with iRacing installed. Please test that the if statement works when enabling/disabling the limiter in sim. If it doesn't, then OverlayDDU.h line 261 needs looking into. If there are any other issues, I can look into them.