All works!!! Vadim is ill =(
Fixed bugs. And some refactoring.