Offset bug in constructor fixed