You can use any combination of light sources from the com.jme3.light
package: ambient lights, directional lights, point lights, and spot lights. Remove the lights from HoverTank.java
file's simpleInit()
method, and add them back one by one to see the difference.
Add an ambient light. Try multiplying the color by different scalars, larger or smaller than 1.0f, to increase or decrease its brightness. Note how it illuminates the whole scene evenly. Try setting the color to something other than
White
.AmbientLight ambient = new AmbientLight(); ambient.setColor(ColorRGBA.White.mult(5f)); rootNode.addLight(ambient);
Remove the ambient light and add a point light. Move it to different locations to see the difference. Try different colors and multiply them by a scalar to see the difference in brightness.
PointLight lamp = new PointLight(); lamp.setPosition(Vector3f.ZERO); lamp.setColor(ColorRGBA.Yellow); rootNode.addLight(lamp);
Remove the point light and add a directional...