Fix some bugs and missed things, but still doesn't work well at live