By now all cao ans sao classes (rat/firefly/mob/luaentity) are within one big file and even use different coding styles.
I've harmonized coding styles and split up to different files for each object. This doesn't change any features but is meant to be a first step to remove c++ implemented mobs, or add a generic mob support to c++ if decided to go this way.
Yes i know the patch is quite big, reason for this is splitting requires removing code from one file adding to another thus patch is at least twice the size of changes.
EDIT1: there's a problem with this patch I'll have to fix it first so don't use it
Edit2: I've fixed it problem was cao/sao prototypes where created in random order not ensuring that factory is available when beeing created.
Patch V2