We make a model of a bullet.
1 set the parameters in 3d Max First, set customize->units setup metic to cm
2 modelling, here we use plane, a plane,
3 then Export
4 Model settings in unity,
Here is a parameter scale Factor, which is very important, the setting is small, resulting in unity may not be seen, big and inappropriate.
5 Creating a material
6 Create a shader, assign this shader to the material you just created
Here's the shader code below
Shader"angrybots2/fx2/additive"{Properties {_maintex ("Base", 2D) =" White"{} _tintcolor ("Tintcolor", Color) = (1.0,1.0,1.0,1.0)} cginclude #include"Unitycg.cginc"sampler2d _maintex; Fixed4 _tintcolor; Half4 _maintex_st; structv2f {Half4 pos:sv_position; Half2 uv:texcoord0; }; v2f Vert (Appdata_full v) {v2f o; O.pos=Mul (UNITY_MATRIX_MVP, V.vertex); O.uv.xy=Transform_tex (V.texcoord, _maintex); returno; } fixed4 Frag (v2f i): COLOR {returnTex2d (_maintex, I.uv.xy) *_tintcolor; } ENDCG Subshader {Tags {"Rendertype"="Transparent" "Reflection"="Renderreflectiontransparentadd" "Queue"="Transparent"} cull off Lighting off Zwrite off Fog {Mode off} Blend one one Pass { Cgprogram#pragmaVertex vert#pragmaFragment Frag#pragmaFragmentoption Arb_precision_hint_fastestENDCG}} FallBack Off}
7, create texture, from this shader can be seen, using a 2d texture picture, the 2d texture picture dragged to the correct position
8 material effect is as follows
9 The final shot of the bullet is as follows
The above is the whole process of setup.
Here we need to have a simple understanding of shader.
Unity3d to import footage from 3ds Max to Unity settings