[SOLVED] Loaded model with white light

blender:

source:

skeletonControl = moveSpatial.getControl(SkeletonControl.class);

gunHand  = skeletonControl.getAttachmentsNode("palm.right");


Spatial gunSpatial = assetManager.loadModel("Models/" + gun.model + ".j3o");

gun.node_id        = gunHand.attachChild(gunSpatial);

gunSpatial.setLocalTranslation(gun.translationX, gun.translationY, gun.translationZ);

Could you upload the model file?

https://drive.google.com/open?id=0B-zv3i43GFAhV2E4dVdYODFsUVk

I think you have a light in your game that is summed to the light you have in the scene.

  1. light at game + light at character + light at gun?

ÂżYes?

no character not have light gun hot have light (lamp) 1

Then maybe you have too much light in your scene.

you can load it in the SS Editor and see what you have there

this?

I mean you can open your scene in the app:
https://hub.jmonkeyengine.org/t/jme3-spaceshift-editor/

Paste your source code that sets the directionalLight and/or ambientLight in your scene.
You have to weaken the intensity of the lights that you have attached to the scene.

1 Like

private void setUpLight() {
// We add light so we see the scene

AmbientLight al = new AmbientLight();
al.setColor(ColorRGBA.White.mult(0.8f));
rootNode.addLight(al);

DirectionalLight dl = new DirectionalLight();
dl.setColor(ColorRGBA.White);
dl.setDirection(new Vector3f(2.8f, -2.8f, -2.8f).normalizeLocal());
rootNode.addLight(dl);

}

What is the advantage of the editor?

Scene Editor, Model Editor and Material Editor are more advanced than the same compoments from SDK.

and there is russian localization :wink:

1 Like

Thanks don’t know how to uninstall editor… i use blender… good for rotate and translate.

The specular on your man model is to high for one thing, that’s why the clothes and skin look shiny.

Typically when I get white for a model like this I find it is due to forgetting to UV map the material.

1 Like

yes model don’t java uv map… what if I make it transparent.

if i add alpha texture? transparency?