// Any number of lights, diffuse material Cube_Lava_Normal { technique { // Base ambient pass pass ambient { // base colours, not needed for rendering, but as information // to lighting pass categorisation routine diffuse 0 0 0 } // Now do the lighting pass // NB we don't do decal texture here because this is repeated per light pass perlight { // do this for each light iteration once_per_light scene_blend add // base colours, not needed for rendering, but as information // to lighting pass categorisation routine ambient 0 0 0 // Vertex program reference vertex_program_ref Examples/BumpMapVP { param_named_auto lightPosition light_position_object_space 0 param_named_auto worldViewProj worldviewproj_matrix } // Fragment program fragment_program_ref Examples/BumpMapFP { param_named_auto lightDiffuse light_diffuse_colour 0 } // texture shadow receiver program shadow_receiver_vertex_program_ref Examples/BumpMapVPShadowRcv { param_named_auto lightPosition light_position_object_space 0 param_named_auto worldViewProj worldviewproj_matrix param_named_auto worldMatrix world_matrix param_named_auto texViewProj texture_viewproj_matrix } // Additive texture shadow receiver program shadow_receiver_fragment_program_ref Examples/BumpMapFPShadowRcv { param_named_auto lightDiffuse light_diffuse_colour 0 } // Base bump map texture_unit normalmap { texture Cube_Lava_NORM.jpg colour_op replace } } // Decal pass pass decal { // hint to pass categorisation routine, that this is decal only lighting off scene_blend dest_colour zero ambient 0.5 0.5 0.5 1 } } }