Urho2D.cpp 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. // Copyright (c) 2008-2017 the Urho3D project.
  2. //
  3. // Permission is hereby granted, free of charge, to any person obtaining a copy
  4. // of this software and associated documentation files (the "Software"), to deal
  5. // in the Software without restriction, including without limitation the rights
  6. // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  7. // copies of the Software, and to permit persons to whom the Software is
  8. // furnished to do so, subject to the following conditions:
  9. //
  10. // The above copyright notice and this permission notice shall be included in
  11. // all copies or substantial portions of the Software.
  12. //
  13. // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  14. // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  15. // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
  16. // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  17. // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
  18. // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  19. // THE SOFTWARE.
  20. //
  21. #include "../Precompiled.h"
  22. #include "../Core/Context.h"
  23. #include "../Urho2D/AnimatedSprite2D.h"
  24. #include "../Urho2D/AnimationSet2D.h"
  25. #include "../Urho2D/CollisionBox2D.h"
  26. #include "../Urho2D/CollisionChain2D.h"
  27. #include "../Urho2D/CollisionCircle2D.h"
  28. #include "../Urho2D/CollisionEdge2D.h"
  29. #include "../Urho2D/CollisionPolygon2D.h"
  30. #include "../Urho2D/Constraint2D.h"
  31. #include "../Urho2D/ConstraintDistance2D.h"
  32. #include "../Urho2D/ConstraintFriction2D.h"
  33. #include "../Urho2D/ConstraintGear2D.h"
  34. #include "../Urho2D/ConstraintMotor2D.h"
  35. #include "../Urho2D/ConstraintMouse2D.h"
  36. #include "../Urho2D/ConstraintPrismatic2D.h"
  37. #include "../Urho2D/ConstraintPulley2D.h"
  38. #include "../Urho2D/ConstraintRevolute2D.h"
  39. #include "../Urho2D/ConstraintRope2D.h"
  40. #include "../Urho2D/ConstraintWeld2D.h"
  41. #include "../Urho2D/ConstraintWheel2D.h"
  42. #include "../Urho2D/ParticleEffect2D.h"
  43. #include "../Urho2D/ParticleEmitter2D.h"
  44. #include "../Urho2D/PhysicsWorld2D.h"
  45. #include "../Urho2D/Renderer2D.h"
  46. #include "../Urho2D/RigidBody2D.h"
  47. #include "../Urho2D/Sprite2D.h"
  48. #include "../Urho2D/SpriteSheet2D.h"
  49. #include "../Urho2D/TileMap2D.h"
  50. #include "../Urho2D/TileMapLayer2D.h"
  51. #include "../Urho2D/TmxFile2D.h"
  52. #include "../DebugNew.h"
  53. namespace Urho3D
  54. {
  55. const char* URHO2D_CATEGORY = "Urho2D";
  56. void RegisterUrho2DLibrary(Context* context)
  57. {
  58. Renderer2D::RegisterObject(context);
  59. Sprite2D::RegisterObject(context);
  60. SpriteSheet2D::RegisterObject(context);
  61. // Must register objects from base to derived order
  62. Drawable2D::RegisterObject(context);
  63. StaticSprite2D::RegisterObject(context);
  64. AnimationSet2D::RegisterObject(context);
  65. AnimatedSprite2D::RegisterObject(context);
  66. ParticleEffect2D::RegisterObject(context);
  67. ParticleEmitter2D::RegisterObject(context);
  68. TmxFile2D::RegisterObject(context);
  69. TileMap2D::RegisterObject(context);
  70. TileMapLayer2D::RegisterObject(context);
  71. PhysicsWorld2D::RegisterObject(context);
  72. RigidBody2D::RegisterObject(context);
  73. CollisionShape2D::RegisterObject(context);
  74. CollisionBox2D::RegisterObject(context);
  75. CollisionChain2D::RegisterObject(context);
  76. CollisionCircle2D::RegisterObject(context);
  77. CollisionEdge2D::RegisterObject(context);
  78. CollisionPolygon2D::RegisterObject(context);
  79. Constraint2D::RegisterObject(context);
  80. ConstraintDistance2D::RegisterObject(context);
  81. ConstraintFriction2D::RegisterObject(context);
  82. ConstraintGear2D::RegisterObject(context);
  83. ConstraintMotor2D::RegisterObject(context);
  84. ConstraintMouse2D::RegisterObject(context);
  85. ConstraintPrismatic2D::RegisterObject(context);
  86. ConstraintPulley2D::RegisterObject(context);
  87. ConstraintRevolute2D::RegisterObject(context);
  88. ConstraintRope2D::RegisterObject(context);
  89. ConstraintWeld2D::RegisterObject(context);
  90. ConstraintWheel2D::RegisterObject(context);
  91. }
  92. }