import pymel.core as pm
vert = pm.selected()[0]
mesh = vert.node()
sc = mesh.listHistory(type='skinCluster')[0] # Note this is not a great way to get skinClusters in general, but it works in simple situations.
infs = sc.influenceObjects()
print vert
print mesh
print sc
vId = vert.currentItemIndex()
print 'Vert:', vId
for jId in xrange(sc.numInfluenceObjects()):
print '\t', infs[jId], pm.getAttr(sc.weightList[vId].weights[jId])
pCylinderShape1.vtx[16:17]
pCylinderShape1
skinCluster1
[nt.Joint(u'joint1'), nt.Joint(u'joint2'), nt.Joint(u'joint3'), nt.Joint(u'joint4')]
[0, 1, 2, 3]
Vert: 16
joint1 0.0163752022203
joint2 0.933793770143
joint3 0.0495594248894
joint4 0.000271602747264
pCylinderShape1.vtx[16:17]
pCylinderShape1
skinCluster1
Vert: 16
joint1 0.0163752022203
joint2 0.933793770143
joint3 0.0495594248894
joint4 0.000271602747264
Hey Michael,
You can query objects in the vicinity of a vertex using the MRichSelection class from the API. It’s piggybacking on Maya’s soft-selection feature.
I found a thread with an example here: https://groups.google.com/forum/#!topic/python_inside_maya/q1JlddKybyM
If that doesn’t do it, let me know and I’ll type up an example, I’ve done something similar using this class in the past.