refactored a bit. Now with new renderer!