CmResource.cpp 383 B

12345678910111213141516171819202122232425
  1. #include "CmResource.h"
  2. #include "CmResourceRTTI.h"
  3. namespace CamelotEngine
  4. {
  5. void Resource::load()
  6. {
  7. if(mLoadState != RS_Loaded)
  8. {
  9. loadImpl();
  10. mLoadState = RS_Loaded;
  11. }
  12. }
  13. RTTITypeBase* Resource::getRTTIStatic()
  14. {
  15. return ResourceRTTI::instance();
  16. }
  17. RTTITypeBase* Resource::getRTTI() const
  18. {
  19. return Resource::getRTTIStatic();
  20. }
  21. }