getMeshMaterial.lua 542 B

123456789101112131415161718192021222324
  1. return {
  2. summary = 'Get the index of the material applied to a mesh.',
  3. description = 'Returns the index of the material applied to a mesh.',
  4. arguments = {
  5. mesh = {
  6. type = 'number',
  7. description = 'The index of a mesh.'
  8. }
  9. },
  10. returns = {
  11. material = {
  12. type = 'number',
  13. description = [[
  14. The index of the material applied to the mesh, or nil if the mesh does not have a material.
  15. ]]
  16. }
  17. },
  18. variants = {
  19. {
  20. arguments = { 'mesh' },
  21. returns = { 'material' }
  22. }
  23. }
  24. }