objectType.json 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. {
  2. "type" : "object",
  3. "$schema" : "http://json-schema.org/draft-04/schema",
  4. "title" : "VCMI map object type format",
  5. "description" : "Description of map object type, used only as sub-schema of object",
  6. "required" : [ ],
  7. "additionalProperties" : true, // may have type-dependant properties
  8. "properties" : {
  9. "index" : {
  10. "type" : "number"
  11. },
  12. "aiValue" : {
  13. "type" : "number"
  14. },
  15. "base" : {
  16. "additionalProperties" : true, // Not validated on its own - instead data copied to main object and validated as part of it
  17. "type" : "object"
  18. },
  19. "rmg" : {
  20. "additionalProperties" : false,
  21. "type" : "object",
  22. "properties" : {
  23. "value" : {
  24. "type" : "number"
  25. },
  26. "mapLimit" : {
  27. "type" : "number"
  28. },
  29. "zoneLimit" : {
  30. "type" : "number"
  31. },
  32. "rarity" : {
  33. "type" : "number"
  34. }
  35. }
  36. },
  37. "name" : {
  38. "type" : "string"
  39. },
  40. "templates" : {
  41. "type" : "object",
  42. "additionalProperties" : {
  43. "$ref" : "objectTemplate.json"
  44. }
  45. },
  46. "battleground" : {
  47. "description" : "Battleground that will be used for combats in this object. Overrides terrain this object was placed on",
  48. "type" : "string"
  49. },
  50. "sounds" : {
  51. "type" : "object",
  52. "additionalProperties" : false,
  53. "description" : "Sounds used by this object",
  54. "properties" : {
  55. "ambient" : {
  56. "type" : "array",
  57. "description" : "Background sound of an object",
  58. "items" : {
  59. "type" : "string",
  60. "format" : "soundFile"
  61. }
  62. },
  63. "visit" : {
  64. "type" : "array",
  65. "description" : "Sound that played on object visit",
  66. "items" : {
  67. "type" : "string",
  68. "format" : "soundFile"
  69. }
  70. },
  71. "removal" : {
  72. "type" : "array",
  73. "description" : "Sound that played on object removal",
  74. "items" : {
  75. "type" : "string",
  76. "format" : "soundFile"
  77. }
  78. }
  79. }
  80. }
  81. }
  82. }