I'm trying to get a Quad to accept the Materialstate I apply to it, but it keeps staying white. I've looked around the forum and have double checked whether my lighting is on and it is. Other object with TextureState are showing the correct textures, but the Material State just doesn't want to work.
'this' in the code is a Node. Debugging shows the color object to be Blue.
public void select( Vector3f point, final ColorRGBA color ) {
SharedNode tile = new SharedNode( "", baseTile );
tile.getLocalTranslation().y = point.y;
tile.getLocalTranslation().z += point.z;
tile.getLocalTranslation().x += point.x;
tile.updateGeometricState(0, false);
MaterialState ms = DisplaySystem.getDisplaySystem().getRenderer().createMaterialState();
ms.setDiffuse( color );
ms.setEmissive( color );
ms.setAmbient( color );;
ms.setShininess(54f);
Is the object with the material state attached to root somewhere other than in simpleSetup (or similar) and if so, are you remembering to call update renderstate on it after you attach it?
Second basic question, what is your emmissive color? Emmisive can VERY EASILY saturate the object and make it look like a solid color. Try not setting emmissive as a test.
Try changing the diffuse color or ambient color of your light. if that does not affect what you are seeing, then you don't have a lightstate on that Quad. Also, trying calling tile.setSolidColor(ColorRGBA.red) If your tile turns red and your material state wasn't setup to use vert colors, you definitely are not getting light.