I'm not aware of any software solutions that would allow you to emulate a fn key for 2nd layer options for media keys. For that you would need a hardware solution I think. If you don't use particular fkeys for anything in daily use, you could just remap them to mediakeys outright.
Autohotkey is best option for creating media key macros, but it often doesn't work in games. For the L winkey, what I used to do is start with US intl keymap, and set L winkey to deadkey. You can also remap it to nothing via registy by setting it to scancode 00_00.
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,02,00,00,00,5b,e0,00,00,00,00,00,00