Most of the systems that vpinmame emulates do light dimming effects by rapidly modulating a lamp output on and off. The modulation isn't handled by a separate board, the game code is turning a light on an off rapidly in a tight loop. The only exception is the newer LE SAM games with the serial LED boards.
In vpinmame, for each emulated system, there's always "smoothing" code in the lamp outputs that masks the fact that the game code is doing this at all. Even if you were to disable the smoothing code, vpinmame and VPX only sync with each other every frame, the binary light state every 16ms isn't nearly enough to properly determine the dimming level in vbscript.
I added the "VPMModSol" system into vpinmmame to address this for flashers, but the problem is not actually limited to flashers. TRON's neon ramps do the same thing with standard light outputs. I use similar code there, but just handle it as a custom light output.
The implementation of modulated solenoids inside vpinmame is very tricky to get the timing right so that you get a stable dimming effect. Say the rom is turning it on and off rapidly for 50% brightness. You have to find a method to reverse engineer the timing of the on/off switches and the durations to glean what intensity the ROM is trying to achieve. SAM was pretty easy, the ROM just pushes on/off states every loop, so you can read it like a binary pattern, so we got pretty high fidelity with that system. WPC was a complete nightmare. The big test was the pop bumpers in Scared Stiff. The game dims them very slowly. Get the timing wrong and they flicker. But if you over-smooth it you lose the sharp intentional flickering/strobing. I did the best I could, but it's not perfect.
The implementation is system specific. At one point I implemented the code for Whitestar (very, very similar to SAM, I think they use the same output board). But you really need to test it with a table to flesh out the timing. The only Whitestar table people seem to care much about is LOTR, and that seems to need the effect applied to lamps. Do-able, but no one was really working on a table at the time.
Edited by DJRobX, 12 January 2022 - 04:05 PM.




Top












are all trademarks of VPFORUMS.