Author Topic: Animated Preset?  (Read 9502 times)

Crocodile

  • Guest
Animated Preset?
« on: February 01, 2012, 11:14:43 pm »
So, I'm trying to do an animated preset. Just a simple one, with the tail's color switching from black to white.

I got the code here: http://happyshadow.deviantart.com/art/Feral-Heart-Preset-Script-Tuto-199736102

This is what my code looks like:

material preset_2_bodyMatL
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2body.jpg
         }
      }
   }
}
material preset_2_bodyMatR
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2body.jpg
         }
      }
   }
}
material preset_2_headMatL
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2head.jpg
         }
      }
   }
}
material preset_2_headMatR
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2head.jpg
         }
      }
   }
}
material preset_2_eyeMatL
{
   technique
   {
      pass
      {
         cull_hardware none
         cull_software none
         texture_unit
         {
            texture preset_2eye.jpg
         }
      }
   }
}
material preset_2_eyeMatR
{
   technique
   {
      pass
      {
         cull_hardware none
         cull_software none
         texture_unit
         {
            texture preset_2eye.jpg
         }
      }
   }
}
material preset_2_tailMat
{
   technique
   {
      pass
      {
         texture_unit
         {
            animtexture preset_2tail1.jpg preset_2tail2 .jpg 1
         }
      }
   }
}
material preset_2_maneMat
{
   technique
   {
      pass
      {
         lighting off
         cull_hardware none
         cull_software none
         scene_blend alpha_blend
         depth_write off
         texture_unit
         {
            texture preset_2mane.png
         }
      }
   }
}


The two tail files are named:

preset_2tail1.jpg

preset_2tail2.jpg

I've switched them to black.jpg and white.jpg, but that didn't work. The tail just shows up as that blurry yellow and black that appears as the fur when you don't have any data for that body area.

if anyone could help me it be GREATLY appreciated.


Crocodile

  • Guest
Re: Animated Preset?
« Reply #1 on: February 01, 2012, 11:17:28 pm »
I'm on a mac, by the way.

Crocodile

  • Guest
Re: Animated Preset?
« Reply #2 on: February 01, 2012, 11:21:08 pm »
And I'm also only in Preset maker. i haven't exported it.

Offline Lawcere

  • Finest Floof
  • ***
  • Posts: 513
  • Floof-O-Meter: 21
    • View Profile
Re: Animated Preset?
« Reply #3 on: February 01, 2012, 11:43:31 pm »
Is there a space between preset_2tail2 and .jpg?

I'm not sure why it wouldn't work, but try the coding in this one http://feral-heart.com/index.php?option=com_jfusion&Itemid=2&jfile=index.php&topic=5665.0
« Last Edit: February 01, 2012, 11:45:36 pm by Lawcere »

Crocodile

  • Guest
Re: Animated Preset?
« Reply #4 on: February 01, 2012, 11:57:04 pm »
I don't really get what is supposed to be entered. :P Like, where to put preset_2tail1.jpg and preset_2tail2.jpg?

There was a space, but when I fixed it nothing happened. Same effect.

Crocodile

  • Guest
Re: Animated Preset?
« Reply #5 on: February 02, 2012, 12:16:32 am »
So, I inserted the file names where I thought they should go, but the tail's just white now. Here's the code I had in the material:

material preset_2_bodyMatL
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2body.jpg
         }
      }
   }
}
material preset_2_bodyMatR
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2body.jpg
         }
      }
   }
}
material preset_2_headMatL
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2head.jpg
         }
      }
   }
}
material preset_2_headMatR
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2head.jpg
         }
      }
   }
}
material preset_2_eyeMatL
{
   technique
   {
      pass
      {
         cull_hardware none
         cull_software none
         texture_unit
         {
            texture preset_2eye.jpg
         }
      }
   }
}
material preset_2_eyeMatR
{
receive_shadows on
technique
{
pass
{
ambient 1.000000 1.000000 1.000000 1.000000
diffuse 1.000000 1.000000 1.000000 1.000000
specular 0.010000 0.010000 0.010000 1.000000
emissive 0.000000 0.000000 0.000000 1.000000
texture_unit
{
preset_2tail1.jpg
tex_address_mode wrap
scroll_anim 0.0 0.1 (If you dont want that Texture to move, remove the scroll_anim 0.0 0.1)
filtering trilinear
}
texture_unit
{
preset_2tail2.jpg
tex_address_mode wrap
filtering trilinear
colour_op alpha_blend
scroll_anim 0.0 0.1
}
}
}
}

material preset_2_maneMat
{
   technique
   {
      pass
      {
         lighting off
         cull_hardware none
         cull_software none
         scene_blend alpha_blend
         depth_write off
         texture_unit
         {
            texture preset_2mane.png
         }
      }
   }
}

Offline Lawcere

  • Finest Floof
  • ***
  • Posts: 513
  • Floof-O-Meter: 21
    • View Profile
Re: Animated Preset?
« Reply #6 on: February 02, 2012, 12:17:56 am »
You have it under eyeMat, not tail.

Offline Lawcere

  • Finest Floof
  • ***
  • Posts: 513
  • Floof-O-Meter: 21
    • View Profile
Re: Animated Preset?
« Reply #7 on: February 02, 2012, 12:30:38 am »
material preset_2_bodyMatL
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2body.jpg
         }
      }
   }
}
material preset_2_bodyMatR
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2body.jpg
         }
      }
   }
}
material preset_2_headMatL
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2head.jpg
         }
      }
   }
}
material preset_2_headMatR
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2head.jpg
         }
      }
   }
}
material preset_2_eyeMatL
{
   technique
   {
      pass
      {
         cull_hardware none
         cull_software none
         texture_unit
         {
            texture preset_2eye.jpg
         }
      }
   }
}
material preset_2_eyeMatR
{
   technique
   {
      pass
      {
         cull_hardware none
         cull_software none
         texture_unit
         {
            texture preset_2eye.jpg
         }
      }
   }
}
material preset_2_tailMat
{
   receive_shadows on
   technique
   {
      pass
      {
         ambient 1.000000 1.000000 1.000000 1.000000
         diffuse 1.000000 1.000000 1.000000 1.000000
         specular 0.010000 0.010000 0.010000 1.000000
         emissive 0.000000 0.000000 0.000000 1.000000
         texture_unit
         {
         anim_texture preset_2tail1.jpg preset_2tail2.jpg 1
         tex_address_mode wrap
         filtering trilinear
         rotate_anim 0.00
         }
      }
   }
}      
material preset_2_maneMat
{
   technique
   {
      pass
      {
         lighting off
         cull_hardware none
         cull_software none
         scene_blend alpha_blend
         depth_write off
         texture_unit
         {
            texture preset_2mane.png
         }   
      }   
   }
}


Try this.

Crocodile

  • Guest
Re: Animated Preset?
« Reply #8 on: February 02, 2012, 12:35:59 am »
material preset_2_bodyMatL
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2body.jpg
         }
      }
   }
}
material preset_2_bodyMatR
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2body.jpg
         }
      }
   }
}
material preset_2_headMatL
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2head.jpg
         }
      }
   }
}
material preset_2_headMatR
{
   technique
   {
      pass
      {
         texture_unit
         {
            texture preset_2head.jpg
         }
      }
   }
}
material preset_2_eyeMatL
{
   technique
   {
      pass
      {
         cull_hardware none
         cull_software none
         texture_unit
         {
            texture preset_2eye.jpg
         }
      }
   }
}
material preset_2_eyeMatR
{
   technique
   {
      pass
      {
         cull_hardware none
         cull_software none
         texture_unit
         {
            texture preset_2eye.jpg
         }
      }
   }
}
material preset_2_tailMat
{
   receive_shadows on
   technique
   {
      pass
      {
         ambient 1.000000 1.000000 1.000000 1.000000
         diffuse 1.000000 1.000000 1.000000 1.000000
         specular 0.010000 0.010000 0.010000 1.000000
         emissive 0.000000 0.000000 0.000000 1.000000
         texture_unit
         {
            preset_2tail1.jpg preset_2tail2.jpg
            scroll_anim -0.02 -0.08
            tex_address_mode wrap
            filtering trilinear
         }
      }
   }
}

material preset_2_maneMat
{
   technique
   {
      pass
      {
         lighting off
         cull_hardware none
         cull_software none
         scene_blend alpha_blend
         depth_write off
         texture_unit
         {
            texture preset_2mane.png
         }
      }
   }
}

Supposedly fixed, but there's the yellow and black again. :(
« Last Edit: February 02, 2012, 12:38:18 am by Terror »

Offline Lawcere

  • Finest Floof
  • ***
  • Posts: 513
  • Floof-O-Meter: 21
    • View Profile
Re: Animated Preset?
« Reply #9 on: February 02, 2012, 12:38:08 am »
Hey, use the code I gave you above.