did some tests; fixed some bug. well there's still something weird