1. The units in the game are arbitrary.
2. Yes, all of the distances are in the same unit.
3. Sometimes from the centre, sometimes from the surface

for minasteroidseparation i just discovered it's from the centre, which is bad... should fix that. I think it ought to be from the surface in general.
4. In game units? According to the debugger it's {Width = 2111.99976 Height = 1188.0}. I should think we'll make it so that the camera can be scripted though, so that Rudolf and other level designers can place the camera in a sensible place at the start of a level or at key points or whatever.
5. The asteroid's size is calculated from the following code:
float radiusAmount = (a.Energy) * Globals.Asteroids.SizeFromEnergy + a.Strength * Globals.Asteroids.SizeFromStrength + a.Speed * Globals.Asteroids.SizeFromSpeed;
float radiusBand = (Globals.Asteroids.MaxRadius - Globals.Asteroids.MinRadius);
radiusAmount /= radiusBand; // this should give us 0->1
Utils.Clamp(ref radiusAmount, 0, 1);
float radius = Globals.Asteroids.MinRadius + (float)Math.Pow(radiusAmount, Globals.Asteroids.RadiusPowerRule) * radiusBand;
if (radius > Globals.Asteroids.MaxRadius) radius = Globals.Asteroids.MaxRadius;
So we have the min size and add on a power rule for a value between 0 and 1 that is the ratio of the size from each attribute to the range in size of asteroids in the level. Confused? So were we!
Glad you're enjoying the game, don't work too hard making an editor yet as it might be easier for you to do it later. At the moment we're using XML for level data but later it will be possible to use Lua.