Fixed errors caused by merging in draw3d