refactored proto.go
One last major rewrite. Figured out all sticking points.