generate obstacle