Robienie przeźroczystych presetów jest bardzo łatwe. Standardowy wzór material na preset wygląda tak:
material preset_8_bodyMatL
{
technique
{
pass
{
texture_unit
{
texture preset_8body.jpg
}
}
}
}
material preset_8_bodyMatR
{
technique
{
pass
{
texture_unit
{
texture preset_8body.jpg
}
}
}
}
material preset_8_headMatL
{
technique
{
pass
{
texture_unit
{
texture preset_8head.jpg
}
}
}
}
material preset_8_headMatR
{
technique
{
pass
{
texture_unit
{
texture preset_8head.jpg
}
}
}
}
material preset_8_eyeMatL
{
technique
{
pass
{
cull_hardware none
cull_software none
texture_unit
{
texture preset_8eye.jpg
}
}
}
}
material preset_8_eyeMatR
{
technique
{
pass
{
cull_hardware none
cull_software none
texture_unit
{
texture preset_8eye.jpg
}
}
}
}
material preset_8_tailMat
{
technique
{
pass
{
texture_unit
{
texture preset_8tail.jpg
}
}
}
}
material preset_8_maneMat
{
technique
{
pass
{
lighting off
cull_hardware none
cull_software none
scene_blend alpha_blend
depth_write off
texture_unit
{
texture preset_8mane.png
}
}
}
}
Na początku zajmijmy się materialem do przeźroczystego preseta.
Weźmy na przykład taką sytuację. Chcemy, żeby przeźroczyste było na lewej stronie ciała. Wklejamy zamiast
material preset_8_bodyMatL
{
technique
{
pass
{
texture_unit
{
texture preset_8body.jpg
}
}
}
}
To:
material preset_8_bodyMatL
{
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
cull_hardware none
cull_software none
scene_blend alpha_blend
texture_unit
{
texture Body_Left.png
}
}
}
}
Zależy od numeru preseta, którego chcemy użyć. Jakbyśmy chcieli np. 1 to zamiast 9 wpisujemy 1. Cała filozofia. Jakbyśmy chcieli przeźroczyste np. na lewej stronie głowy wystarczy, że wkleisz to zamiast
material preset_8_headMatL
{
technique
{
pass
{
texture_unit
{
texture preset_8head.jpg
}
}
}
}
Wkleisz:
material preset_9_headMatL
{
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
cull_hardware none
cull_software none
scene_blend alpha_blend
texture_unit
{
texture Head_Left.png
}
}
}
}
Co takiego? Chcesz wiedzieć jak zrobić niewidzialną część na presecia jak już masz material? To proste! Najpierw rysujesz preset. Gdy już jest skończony przejdźmy do przeźroczystości. Załóżmy, że chcesz niewidzialną łapę.
1. Otwórz Gimpa'a i na przybiorniku znajdź ,lasso".
2. Zaznacz fragment, który ma być niewidzialny.
3.Znajdź opcję ,,wytnij".
4. Wejdź w kolory>>zmień kolor w alfę.
5. Teraz fragment jest niewidzialny. Co dalej? Trzeba zmenić format obrazku z jpg na png. Jpg nie przyjmuje przeźroczystości i fragment nie będzie niewidzialny po zapisaniu.
Tam zmień jpg w nazwie na png. Potem klinkij drugi ,,+" i wybierz rozszerzenie png. Dalej akceptuj i gotowe.
Mam nadzieję, że poradnik się przyda.
Ostatnio edytowany przez Rainbow (2012-08-03 18:54:35)
Offline