isCollisionEnabledBetween.lua 818 B

12345678910111213141516171819202122232425262728293031323334
  1. return {
  2. tag = 'worldCollision',
  3. summary = 'Check if two tags can collide.',
  4. description = 'Returns whether collisions are currently enabled between two tags.',
  5. arguments = {
  6. {
  7. name = 'tag1',
  8. type = 'string',
  9. description = 'The first tag.'
  10. },
  11. {
  12. name = 'tag2',
  13. type = 'string',
  14. description = 'The second tag.'
  15. }
  16. },
  17. returns = {
  18. {
  19. name = 'enabled',
  20. type = 'boolean',
  21. description = 'Whether or not two colliders with the specified tags will collide.'
  22. }
  23. },
  24. notes = [[
  25. Tags must be set up when creating the World, see `lovr.physics.newWorld`.
  26. By default, collision is enabled between all tags.
  27. ]],
  28. related = {
  29. 'lovr.physics.newWorld',
  30. 'World:disableCollisionBetween',
  31. 'World:enableCollisionBetween'
  32. }
  33. }