Complete overhaul of skills code

Way to much to document here...