Мой код
private Node enemies;
private void initEnemies(){
enemies = new Node();
Box boxMesh = new Box(1f, 1f, 1f);
Geometry boxGeo = new Geometry("Colored Box", boxMesh);
Material boxMat = new Material(getAssetManager(), "Common/MatDefs/Light/Lighting.j3md");
boxMat.setBoolean("UseMaterialColors", true);
boxMat.setColor("Ambient", ColorRGBA.Blue);
boxMat.setColor("Diffuse", ColorRGBA.Blue);
boxGeo.setMaterial(boxMat);
boxGeo.setLocalTranslation(playerNode.getLocalTranslation());
boxGeo.setUserData("Health", 100);
enemies.attachChild(boxGeo);
rootNode.attachChild(enemies);
}
@Override
public void simpleInitApp() {
initAsset();
initState();
initThis();
flyCam.setEnabled(false);
stateManager.detach(stateManager.getState(FlyCamAppState.class));
MyCamera myCam = new MyCamera(cam);
myCam.registerWithInput(inputManager);
stateManager.attach(new GunState());
bulletAppState = new BulletAppState();
stateManager.attach(bulletAppState);
initTerrain();
initLight();
initHUD();
initPlayer();
initEnemies();
}
И не показывает :( Ошибок нет Нет краша консоли Нет выхода из игры Кто знает как починить? Все работает а вот это враги нет :(
Мне это нужно для моей 3D-игры с jmonkeyengine 3
Спасибо за любую помощь