fixed init function + improved offset + added dragging and Array.filter