Skip to content

Star Trek: The Next Generation

Star Trek: The Next Generation is a Williams WPC table that received one of the most thorough VPW post-release polish cycles, going through 18+ minor versions after initial release. The project benefited enormously from clarkkent9917 owning the real machine, providing crucial accuracy feedback for physics, sounds, and gameplay feel. Key development areas included NFozzy lamp routines, physics edge cases, wire ramp sounds, and VR-specific challenges.

Build Notes

VR Sideblades

The table has two versions of sideblades: normal (korpus) and large/cabinet (korpus1). When running Cabinet Mode in VR, the large sideblades appeared incorrectly. Solution: use RenderingMode in script -- if rendermode=2 (VR), show korpus; otherwise show korpus1 for cabinet mode.

Wire Ramp Sounds

Wire ramps were missing mechanical sounds. Ball velocity-based volume was added with debugging logic showing sound playback in the debug window. Different sound samples have different RMS levels, so some ramps sound quieter at low ball speeds.

Solution: use PlaySoundAtVolumeLevel logic with custom volume curves per ramp. An OriginalWireRampSounds toggle allows switching between Fleep samples and Knorr's machine-recorded samples.

Gate vs Spinner for Ramp Entry

Left and right ramp gate animations were originally hooked to spinners instead of actual gates, causing the left ramp to sometimes not register hits. Changing to actual gate objects with animations and sounds hooked to gate hit events provides more realistic swing and accurate detection.

Neutral Zone Sound

The neutral zone holes had no ball drop sound. The fix:

  1. Add a trigger at height -20 (not playfield height 0)
  2. Position so it does not trigger from balls rolling down Subway1 ramp (at -80)
  3. Play the drop sound only when the trigger fires within 0.5 seconds of a target hit
  4. Keep target hit sounds separate from ball drop sound

Desktop Mode Background

Desktop mode background changed to space-themed imagery for better visual presentation.

Lower Slingshot Posts

Lower slingshot posts (18 and 19) should have physics values 0.6/0.4/0.8 for better post passes. These values were changed at some point during development and restoring them made the table feel correct.

VR Playfield Reflections

Default table reflection strength of 25 is distracting in VR. Set dynamically: table1.PlayfieldReflectionStrength = 7 in VRRoom init.

Physical Rebuild Complexity

STTNG lock mechanism uses ball teleporting/destroying, not physical subways. A physical rebuild was not attempted due to the complexity of subways, VUKs, internal ramps, and cannon mechanisms.

Playfield Mesh Verification

The playfield mesh around the neutral zone hole was investigated and found to be "dead on accurate." No adjustment was needed -- the issue was with target elasticity and primitive collision, not mesh geometry. Always verify mesh accuracy before making changes.

Scripting

NFozzy Lamp Routine Order

JP's light routine requires specific order: NFadeLm (multiple lamp) subs must go BEFORE NFadeL (regular fading). Example for lamp 34:

NFadeLm 34, l34
NFadeLm 34, l34b
NFadeL 34, f34

Multiple NFadeLm calls must end with NFadeL on the last lamp:

NFadeLm 78, l78a
NFadeLm 78, l78b
NFadeLm 78, l78c
NFadeLm 78, l78borgd
NFadeL 78, l78borge

If order is wrong, the last lamp in a group does not fade properly.

Staged Flippers

For users with staged flipper buttons. Key learning: do not call solcallback directly in keyup/keydown routines. VPinMame handles flipper solenoid mapping automatically through WPC.VBS and core.vbs. If usesolenoids=2, core.vbs bypasses mame callback for lower latency.

PWM Flashers

PWM flashers create more realistic flashes. VPX 10.8 has a completely different PWM implementation handled by VPX itself, not requiring Lampz. STTNG does not use Lampz at all in the current implementation.

Modulated Flasher Script

The Borg ship flasher (906) should pulse during multiball, not blink on/off. This is PWM modulation. WPC does PWM modulation on solenoid/flasher outputs, not lamps. The fix involved copying modulated flasher script from another table and tuning fade rates to match real machine behavior.

Custom L8 ROM

Custom L8 ROM available with timer pause mechanic: if a switch is not hit for a while, the timer stops. This prevents mode timeouts during careful play. Now officially supported in current PinMAME. For older PinMAME versions, patch L8 and rename to L7.

Switch Height and Hit Detection

When switch detection fails (like sw48 on Borg ramp not giving jackpot credit), check the hit height value. Increase sw48 hit height to 120 or re-reference the correct collision object.

3D & Art

Borg Ship Material

To fix the Borg ship color from luminous green to proper appearance:

  1. Open texture in GIMP, drop hue/saturation on green to olive
  2. Change red from pure red
  3. Change material back to white (was tinted to offset green)
  4. Add normal map back
  5. Add 0.05 disablelighting to tune brightness

Final settings: white material, adjusted texture, normal map enabled, DisableLighting at 0.05.

Borg Ship Flasher Color

Real machine: white 906 bulbs with colored windows (blue original, green is common mod). The community preferred green since Borg are greenish. Table-side flashers changed from green to white to match real playfield illumination.

Troubleshooting

Borg Ramp Ball Diversion

When the ball diverts to the top lock at high speed, it falls into the bumpers. Fix: disable borgramp1a and set detarampendborg to collidable. Increase sw48 hit height to 120.

Neutral Zone Difficulty

The neutral zone hole was extremely difficult to shoot. Multiple fixes applied:

  1. Reduce elasticity on center target to 0.2
  2. Make exception for target in target bouncer script
  3. Use shaped target primitive for physics
  4. Make yellow plastic primitive (T27P2) collidable with low elasticity and falloff = 0

Cannon Ball Height

Balls got caught on habitrails because they sat too high. Fix: change CannonLBall.Z=105 + BallSize to CannonLBall.Z=86 + BallSize/2. Set RadiusR / RadiusL = 135. Visual hitch remains but habitrail collisions are prevented.

Ball Through Delta Ramp

Ball goes airborne and jumps through delta ramp at certain angles. Fix: increase BallGuide12 Physical Wall Right from 50 to 120.

VR DMD Not Showing in FS Mode

When "Use always FS backdrop settings" is checked in VPX video options, the DMD disappears in VR. Fix: change UseVPMDMD = DesktopMode to UseVPMDMD = True.

BallVel Function Crash (Picard Maneuver)

Crash when using Picard maneuver to lock a ball. The wire ramp roll sound was not stopped when the ball entered the Borg ship kicker. Fix: add wirerampoff call on Borg ship kicker entry.

Lockbar Button Bug

Lockbar button added to KeyDown but not KeyUp, causing launch switch (12) not to release. This broke 2nd and 3rd ball launches. Fix: add lockbar key to KeyUp event.

PUP Packs in VR

PUP packs do not work with authentic simulated VR backboxes. PUP requires a single backglassimage primitive, but VPW tables use separate lights and flashers. Workaround: add a script option to turn off real backglass elements. Most users prefer the authentic VR backbox.

Primitive Position Corruption

scoopleft2 primitive position got tweaked despite being locked. Always lock important primitives and verify positions if visuals look off. Even locked objects can occasionally move in the VPX editor.

Game Knowledge

Middle Shot Difficulty

The middle shot (neutral zone area) is harder than on the real machine. On real STTNG, you can hit it 10+ times in a row -- one of the most satisfying repeatable shots in pinball. The VPW version still rejects it too often despite significant tuning effort.

Inlane Ski-Jumps

Ski-jumps from inlanes are easy and reliable. PAPA tournament videos show real machines also allow consistent ski-jumps, so no slowdown code was implemented -- the behavior matches the real machine.

Resources

Knorr's SFX Pack

Machine-recorded sound samples from clarkkent's real STTNG table. Provides authentic wire ramp sounds and other mechanical audio vs generic Fleep samples.

AltSound Package

ClarkKent converted the best STTNG PinSound package to AltSound format. Available in Discord.

Custom ROM

L8 ROM with timer pause mechanic, available via MEGA. Pre-patched and renamed as L7 for older PinMAME compatibility. Now officially supported in current PinMAME.

Blender File

STTNG_VPXcleanstart.blend available on Google Drive for clean 3D modeling start.