Browse Source

allows for frame counts on animations with the same name, but not neccessarily the same channel name in the same directory

Chris Brunner 15 years ago
parent
commit
2c15943a7c
1 changed files with 4 additions and 1 deletions
  1. 4 1
      dtool/pptempl/Template.models.pp

+ 4 - 1
dtool/pptempl/Template.models.pp

@@ -395,7 +395,10 @@ $[TAB]$[MAYA2EGG] $[MAYA2EGG_OPTS] -p -a model -cn "$[CHAR_NAME]" -o $[target] $
     #define source $[MAYA_PREFIX]$[anim]$[MAYA_EXTENSION]
     #define source $[MAYA_PREFIX]$[anim]$[MAYA_EXTENSION]
     #define begin 0
     #define begin 0
     #define end
     #define end
-    #if $[$[anim]_frames]
+    #if $[$[CHAR_NAME]_$[anim]_frames]
+      #set begin $[word 1,$[$[CHAR_NAME]_$[anim]_frames]]
+      #set end $[word 2,$[$[CHAR_NAME]_$[anim]_frames]]
+    #elif $[$[anim]_frames]
       #set begin $[word 1,$[$[anim]_frames]]
       #set begin $[word 1,$[$[anim]_frames]]
       #set end $[word 2,$[$[anim]_frames]]
       #set end $[word 2,$[$[anim]_frames]]
     #endif
     #endif