Add spectIndex accessor to Star for use by Squirrel scripts

We prefer indices than random order alphabet notation in computation.

Also exposed spectralToName() and nameToSpectral() static methods for
Squirrel scripts.
Allow using register_const() from outside sqadapt.cpp

The function defines global constant, so it might not be extensively used,
but extension modules can make use of it.

Also re-ordered parameters of the function to match register_closure().
Add register_static() to define a static member variable for Squirrel

Also cleaned up neighboring codes that are mixing coding styles and have
trailing spaces.
The type of argument of register_*() is matched to Squirrel's integer type.
Expose Star's maxSpectralTypes to Squirrel scripts
Diverse spectral type of randomly generated Stars

Also reduced redundant codes in init.nut by introducing a local function.