/// <summary> /// Finds the location of the method in the virtual table of its definition mixin /// </summary> /// <param name="methodDeclaration"></param> /// <returns></returns> public VTableReference GetBaseDeclaration(MethodDeclaration methodDeclaration) { var baseMethodDeclMixin = methodDeclaration.GetTag(XenkoTags.BaseDeclarationMixin) as string; var slot = -1; var vt = VirtualTableGroup[baseMethodDeclMixin]; for (int i = 0; i < vt.Length; ++i) { if (methodDeclaration.IsSameSignature(vt[i])) { slot = i; break; } } return(new VTableReference { Shader = baseMethodDeclMixin, Slot = slot }); }