Add basic map editing function and make them work