First commit, everything seems to work but some tweaks still needed