def _parse_chance(self, element):
try:<EOL><INDENT>chance = float(element.text)<EOL><DEDENT>except (ValueError, TypeError, AttributeError):<EOL><INDENT>self._log.warn('<STR_LIT>'.format(chance=element.text))<EOL>return<EOL><DEDENT>if not (<NUM_LIT:0> <= chance <= <NUM_LIT:100>):<EOL><INDENT>self._log.warn('<STR_LIT>')<EOL>return<EOL><DEDENT>self.chance = chance<EOL>self.chance_blocking = bool_attribute(element, '<STR_LIT>', self.chance_blocking)<EOL>
Parse a chance element
:param element: The XML Element object
:type  element: etree._Element