Author Topic: problem to create object3d model  (Read 667 times)

Offline ashunkhs

  • byte
  • *
  • Posts: 24
    • View Profile
problem to create object3d model
« on: May 09, 2013, 02:10:57 pm »
hi

 i have to create  Object3D model  with object ID 0.
 but when i start app  line1 print object ID->0 but again reopen the app it print ID-->1....and increase one by one .
 so, how to set the object ID ,which always print 0.

Object3D cube_lm= null
cube_up_rt = Primitives.getPlane(9, 9);
         System.out.println("cube_up_rt id-------->"+cube_up_rt.getID());......................line 1
         cube_up_rt.setTexture("eng_text");
         cube_up_rt.rotateY(-60);
         //cube_up_rt.strip();
         cube_up_rt.build();
         cube_up_rt.setCollisionMode(Object3D.COLLISION_CHECK_OTHERS);
         cube_up_rt.translate(380, 160, 0);

when i do in
onDestry()
{
world.removeObject(cube_up_rt);
cube_up_rt=null;
tm.removeTexture("hebrew_text");
world.dispose();
world = null;
fb.freeMemory();
fb.dispose();
fb = null;
}               and i got the same result.pls help me out.
« Last Edit: May 09, 2013, 02:32:50 pm by ashunkhs »

Offline ashunkhs

  • byte
  • *
  • Posts: 24
    • View Profile
Re: problem to create object3d model
« Reply #1 on: May 09, 2013, 03:15:53 pm »

i got it .
cube.setName("1"); and
TextureNumber(Integer.parseInt(obj.getName()));

now i am getting always right ID.


thanks......
« Last Edit: May 10, 2013, 07:34:06 am by ashunkhs »