Advertisement
Benji23245

Untitled

Oct 16th, 2017
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.80 KB | None | 0 0
  1. //To animate Super/Hyper Sonic
  2. void processobject(NJS_OBJECT *obj)
  3. {
  4. do
  5. {
  6. if (obj->basicdxmodel)
  7. {
  8. NJS_MODEL_SADX *mdl = obj->basicdxmodel;
  9. for (int i = 0; i < mdl->nbMat; i++)
  10. if (mdl->mats[i].attr_texId == 30)
  11. materials.push_back(&mdl->mats[i]);
  12. }
  13. if (obj->child)
  14. processobject(obj->child);
  15. obj = obj->sibling;
  16. } while (obj);
  17. }
  18.  
  19.  
  20. using std::vector;
  21.  
  22. vector<NJS_MATERIAL *> materials2;
  23.  
  24. //To animate Super/Hyper Sonic
  25. void processobject2(NJS_OBJECT *obj)
  26. {
  27. do
  28. {
  29. if (obj->basicdxmodel)
  30. {
  31. NJS_MODEL_SADX *mdl = obj->basicdxmodel;
  32. for (int i = 0; i < mdl->nbMat; i++)
  33. if (mdl->mats[i].attr_texId == 34)
  34. materials2.push_back(&mdl->mats[i]);
  35. }
  36. if (obj->child)
  37. processobject2(obj->child);
  38. obj = obj->sibling;
  39. } while (obj);
  40. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement