Mar-11-2019, 03:34 AM
(Mar-11-2019, 03:04 AM)moga2003 Wrote: If I write it this way: self._src_type('discover'):
Why are you writing that? You need to check if self._src_type is equal to 'discover'. You use the comparison operator (==) for that, not a function call.
I don't know what you are talking about with the variable names. src_type is a parameter to you __init__ method. It is defined in the def line as having a default value of 'discover', which is only used if no value is supplied to that parameter. self._src_type is an instance attribute that is set to the value associated with the src_type parameter by the __init__ code.
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures