I am trying to add a current-gear indicator like the one that shows in Sport gear (S1, S2, S3, etc.) to the regular Drive gear (it would look like D1, D2, D3, etc), so I know which gear the transmission is in without using the EngineInfo app or putting the transmission in S. I'm getting an error message (below). Here's the lua file, can someone take a look?
Problem seems to be in getGearName, line 65 should probably be elseif instead of if. No idea if this will make the rest of your code work, but will probably fix the first error. I'd recocomend running an editor with linting like the setup here: https://www.beamng.com/threads/trying-out-a-new-editor.54612/#post-853327 that will tell you about problems like this before you reload in BeamNG.