Style cleanup 4
Style cleanup 4

Refactoring for the following rules: no-undefined, new-cap, no-use-before-define.

Several functions have been rearranged but otherwise left unchanged.

LakeYS/7DTD-Discord,LakeYS/7DTD-Discord