Advertisement
spookymunky

VBS to Remove the Constraints and Nulls/Groups Created

Dec 10th, 2012
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ' This script will remmove all the constraints from the skyrim mesh and delete the groups and objects
  2. ' created created in my constraint script. Save your scene first !
  3.  
  4. ' If you didn't create a group for the gear guide, comment out the line DeleteObj "ManGuide_Visibility"
  5.  
  6. ' Open up Explorer(8) then run this script (F5)
  7. ' First pick the model containing the skyrim rig
  8. ' Then pick the model containing the Gear rig
  9.  
  10. LogMessage "!!! Pick the Model containing the Skyrim Rig in explorer !!!"
  11. PickObject "Skyrim model", "Skyrim model", PickSession1
  12. LogMessage "!!! Pick the Model containing the Gear Rig in explorer !!!"
  13. PickObject "Gear rig", "Gear rig", PickSession2
  14.  
  15. 'Remove Constraints from every NPC bone
  16. RemoveAllCns PickSession1 + ".NPC_COM__COM__", 1
  17. RemoveAllCns PickSession1 + ".NPC_Head__Head_", 1
  18. RemoveAllCns PickSession1 + ".NPC_L_Calf__LClf_", 1
  19. RemoveAllCns PickSession1 + ".NPC_L_Clavicle__LClv_", 1
  20. RemoveAllCns PickSession1 + ".NPC_L_Finger00__LF00_", 1
  21. RemoveAllCns PickSession1 + ".NPC_L_Finger01__LF01_", 1
  22. RemoveAllCns PickSession1 + ".NPC_L_Finger02__LF02_", 1
  23. RemoveAllCns PickSession1 + ".NPC_L_Finger10__LF10_", 1
  24. RemoveAllCns PickSession1 + ".NPC_L_Finger11__LF11_", 1
  25. RemoveAllCns PickSession1 + ".NPC_L_Finger12__LF12_", 1
  26. RemoveAllCns PickSession1 + ".NPC_L_Finger20__LF20_", 1
  27. RemoveAllCns PickSession1 + ".NPC_L_Finger21__LF21_", 1
  28. RemoveAllCns PickSession1 + ".NPC_L_Finger22__LF22_", 1
  29. RemoveAllCns PickSession1 + ".NPC_L_Finger30__LF30_", 1
  30. RemoveAllCns PickSession1 + ".NPC_L_Finger31__LF31_", 1
  31. RemoveAllCns PickSession1 + ".NPC_L_Finger32__LF32_", 1
  32. RemoveAllCns PickSession1 + ".NPC_L_Finger40__LF40_", 1
  33. RemoveAllCns PickSession1 + ".NPC_L_Finger41__LF41_", 1
  34. RemoveAllCns PickSession1 + ".NPC_L_Finger42__LF42_", 1
  35. RemoveAllCns PickSession1 + ".NPC_L_Foot__LLft__", 1
  36. RemoveAllCns PickSession1 + ".NPC_L_FootBox", 1
  37. RemoveAllCns PickSession1 + ".NPC_L_Forearm__LLar_", 1
  38. RemoveAllCns PickSession1 + ".NPC_L_ForearmTwist1__LLt1_", 1
  39. RemoveAllCns PickSession1 + ".NPC_L_ForearmTwist2__LLt2_", 1
  40. RemoveAllCns PickSession1 + ".NPC_L_Hand__LHnd_", 1
  41. RemoveAllCns PickSession1 + ".NPC_L_HeelPivot", 1
  42. RemoveAllCns PickSession1 + ".NPC_L_Thigh__LThg_", 1
  43. RemoveAllCns PickSession1 + ".NPC_L_Toe0__LToe_", 1
  44. RemoveAllCns PickSession1 + ".NPC_L_ToePivot", 1
  45. RemoveAllCns PickSession1 + ".NPC_L_UpperArm__LUar_", 1
  46. RemoveAllCns PickSession1 + ".NPC_L_UpperarmTwist1__LUt1_", 1
  47. RemoveAllCns PickSession1 + ".NPC_L_UpperarmTwist2__LUt2_", 1
  48. RemoveAllCns PickSession1 + ".NPC_Neck__Neck_", 1
  49. RemoveAllCns PickSession1 + ".NPC_Pelvis__Pelv_", 1
  50. RemoveAllCns PickSession1 + ".NPC_Pelvis__Tail_", 1
  51. RemoveAllCns PickSession1 + ".NPC_R_Calf__RClf_", 1
  52. RemoveAllCns PickSession1 + ".NPC_R_Clavicle__RClv_", 1
  53. RemoveAllCns PickSession1 + ".NPC_R_Finger00__RF00_", 1
  54. RemoveAllCns PickSession1 + ".NPC_R_Finger01__RF01_", 1
  55. RemoveAllCns PickSession1 + ".NPC_R_Finger02__RF02_", 1
  56. RemoveAllCns PickSession1 + ".NPC_R_Finger10__RF10_", 1
  57. RemoveAllCns PickSession1 + ".NPC_R_Finger11__RF11_", 1
  58. RemoveAllCns PickSession1 + ".NPC_R_Finger12__RF12_", 1
  59. RemoveAllCns PickSession1 + ".NPC_R_Finger20__RF20_", 1
  60. RemoveAllCns PickSession1 + ".NPC_R_Finger21__RF21_", 1
  61. RemoveAllCns PickSession1 + ".NPC_R_Finger22__RF22_", 1
  62. RemoveAllCns PickSession1 + ".NPC_R_Finger30__RF30_", 1
  63. RemoveAllCns PickSession1 + ".NPC_R_Finger31__RF31_", 1
  64. RemoveAllCns PickSession1 + ".NPC_R_Finger32__RF32_", 1
  65. RemoveAllCns PickSession1 + ".NPC_R_Finger40__RF40_", 1
  66. RemoveAllCns PickSession1 + ".NPC_R_Finger41__RF41_", 1
  67. RemoveAllCns PickSession1 + ".NPC_R_Finger42__RF42_", 1
  68. RemoveAllCns PickSession1 + ".NPC_R_Foot__Rft__", 1
  69. RemoveAllCns PickSession1 + ".NPC_R_FootBox", 1
  70. RemoveAllCns PickSession1 + ".NPC_R_Forearm__RLar_", 1
  71. RemoveAllCns PickSession1 + ".NPC_R_ForearmTwist1__RLt1_", 1
  72. RemoveAllCns PickSession1 + ".NPC_R_ForearmTwist2__RLt2_", 1
  73. RemoveAllCns PickSession1 + ".NPC_R_Hand__RHnd_", 1
  74. RemoveAllCns PickSession1 + ".NPC_R_HeelPivot", 1
  75. RemoveAllCns PickSession1 + ".NPC_R_Thigh__RThg_", 1
  76. RemoveAllCns PickSession1 + ".NPC_R_Toe0__RToe_", 1
  77. RemoveAllCns PickSession1 + ".NPC_R_ToePivot", 1
  78. RemoveAllCns PickSession1 + ".NPC_R_UpperArm__RUar_", 1
  79. RemoveAllCns PickSession1 + ".NPC_R_UpperarmTwist1__RUt1_", 1
  80. RemoveAllCns PickSession1 + ".NPC_R_UpperarmTwist2__RUt2_", 1
  81. RemoveAllCns PickSession1 + ".NPC_Root__Root_", 1
  82. RemoveAllCns PickSession1 + ".NPC_Spine1__Spn1_", 1
  83. RemoveAllCns PickSession1 + ".NPC_Spine2__Spn2_", 1
  84. RemoveAllCns PickSession1 + ".NPC_Spine__Spn0_", 1
  85.  
  86. 'Delete the objects and groups created by my constraint script
  87.  
  88. DeleteObj PickSession2 + ".Cons_Left_Elbow"
  89. DeleteObj PickSession2 + ".Cons_Left_Knee"
  90. DeleteObj PickSession2 + ".Cons_Right_Elbow"
  91. DeleteObj PickSession2 + ".Cons_Right_Knee"
  92. DeleteObj PickSession2 + ".JointConst"
  93. DeleteObj PickSession2 + ".HideTheToes"
  94.  
  95. 'If don't have a ManGuide group creation part in the original script comment out or delete line
  96. DeleteObj "ManGuide_Visibility"
  97. 'If don't have a ManGuide group creation part in the original script comment out or delete line
  98.  
  99. LogMessage "All constraints should now be removed!"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement