Reimplemented some stuff