coordinates = self.props.values()
The property shown in the Property Editor is value
, not values
. Try,
coordinates = self.props.value
That will return a dictionary, not a list, so you will need to refer to the elements using the key (and we can do it directly without introducing the coordinates
variable):
lat = self.props.value.lat
lng = self.props.value.lng
Tips:
- Use the Script Editor's Browse Properties button to pick properties. It can eliminate this type of error.
- Post code as code, not as quotations. See below.