improved structure

Used a more OO approach and added some missing resources