Fixed allmost all bugs