public string getMaterialDefText(string name) { MaterialDef md = findMaterialDef(name); if (md == null) { return(null); } string d = p.getData(); return(d.Substring(md.getStart(), md.getEnd() - md.getStart())); }
public MaterialDef findMaterialDef(string name) { foreach (MtrFile f in matFiles) { MaterialDef md = f.findMaterialDef(name); if (md != null) { return(md); } } return(null); }