There isn't an OnMouseDown function for anything other than the left button, but you can sort of override OnMouseOver instead, like this:
function OnMouseOver () { if (Input.GetMouseButton(1)) { // do something } } 如果是监测鼠标右键按下或抬起改为
Input.GetMouseButtonDown(1)、
Input.GetMouseButtonUp(1)即可
转自:http://answers.unity3d.com/questions/18875/right-mouse-detection.html