[MP] Fix #450 - R_FogFactor segfault

When fixing the render command list, the shader indexes are reassigned
in the sort keys. However, when rebuilding the sort key, the entity num
was not re-shifted into the correct place in the bitfield.
Merge branch 'master' into rend2
[MP] Rend2: Merge fog fix from vanilla.
Merge remote-tracking branch 'upstream/rend2' into rend2