Some bugs yet but it makes his function