3D Entity System [DE]

Previous topic - Next topic

Quentin

naja, war ja wohl so gewollt von dir :)

Vorschlag:

Neues Attribut "deleted"

EntityEnable --> setzt Enabled auf true/false --> wird bei false duch EntityAddInternal NICHT ?berschrieben
EntityFree --> setzt deleted auf true --> kann ?berschrieben werden.

bigsofty

Did this come out of beta, anyone been using it?

I noticed when "[""]" are used it crashed the demo?
Cheers,

Ian.

"It is practically impossible to teach good programming style to students that have had prior exposure to BASIC.  As potential programmers, they are mentally mutilated beyond hope of regeneration."
(E. W. Dijkstra)

Kitty Hello

Does it crash, still?

bigsofty

Yep, maybe I used the wrong link? I used the one at the beginning of this thread?
Cheers,

Ian.

"It is practically impossible to teach good programming style to students that have had prior exposure to BASIC.  As potential programmers, they are mentally mutilated beyond hope of regeneration."
(E. W. Dijkstra)

Moru

I used it when it was still fresh and it was very easy to use but I haven't tried it since then except for trying to add X_sprites. That test failed since they are displayed centered on the lower middle of the sprite.

Hemlos

Quote from: Kitty Hello on 2010-Feb-05
Does it crash, still?

3des crashes on me when i use the button commands ][
Bing ChatGpt is pretty smart :O

codegit

Is the link at the start of this thread the correct and latest version?  :)
------------------------------------------
1 X Acer TravelMate 4270, laptop, XP PRO
1 X Dell Studio 17 laptop, Windows 7
1 X MacBook Pro 2,2 GHz Core 2 Duo, 2 GB RAM, 160 GB HDD, 9400M
2 X iTouch
1 X HTC Desire (Android 2.1)
iPad soon to be added

Kitty Hello

OK - my fault. It was a mixture of several bugs. I fixed them all.

I'll update the sample in post #1 and will provide an update for GLBasic tonight, that fixes the crash (and also memory consumption. The GENX_OBJ did not use free slots when you loaded an object "" or X_OBJSTART; X_OBJEND).

bigsofty

Thanks Gernot  :good:, downloaded the new sample, it still crashes but this is down to not having the new update, I'll re-try it after I get the GLB update.
Cheers,

Ian.

"It is practically impossible to teach good programming style to students that have had prior exposure to BASIC.  As potential programmers, they are mentally mutilated beyond hope of regeneration."
(E. W. Dijkstra)

bigsofty

No update last night, problems?
Cheers,

Ian.

"It is practically impossible to teach good programming style to students that have had prior exposure to BASIC.  As potential programmers, they are mentally mutilated beyond hope of regeneration."
(E. W. Dijkstra)

codegit

I gave this a quick test. I had problems with EntityLoadTexture and EntityApplyTexture. I was unable to load a .png and then texture a cube.  :(
------------------------------------------
1 X Acer TravelMate 4270, laptop, XP PRO
1 X Dell Studio 17 laptop, Windows 7
1 X MacBook Pro 2,2 GHz Core 2 Duo, 2 GB RAM, 160 GB HDD, 9400M
2 X iTouch
1 X HTC Desire (Android 2.1)
iPad soon to be added

Kitty Hello

Small example, please?

Quentin

for me it works as expected. Where did you get a crash? And about the .png file. Are you able to display it with DRAWSPRITE?

codegit

#313
SETCURRENTDIR("Media") /// NOTE bump.png is in the MEDIA directory
TestJim()

FUNCTION TestJim:

   camera=EntityCreateCamera()
   EntityEnable(camera, TRUE)
   EntitySetCameraRange(camera,1,4000)


   light = EntityCreateLight(RGB(255,255,255) )
   cube = EntityCreateCube(1)

   EntitySetPosition(camera,0,0,-10)
   EntityParent(light, camera)
   jtex = EntityLoadTexture("bump.png")
   notex=EntityMakeNullTexture()
   EntityApplyTexture(cube,jtex,notex)
   //EntitySetAlpha(cube,0.5)

   WHILE TRUE
      // Draw all entites, using entity camera
      IF (KEY(200))
         EntityMove(camera,0,0,0.2)

      ENDIF
      IF (KEY(208))
         EntityMove(camera,0,0,-0.2)

      ENDIF
      IF (KEY(203))

         EntityRotate(camera,0,1,0)

      ENDIF
      IF (KEY(205))

         EntityRotate(camera,0,-1,0)

      ENDIF
      EntityRotate(cube,1,0,0)
      EntityDrawSystem()
      SHOWSCREEN

   WEND

ENDFUNCTION
------------------------------------------
1 X Acer TravelMate 4270, laptop, XP PRO
1 X Dell Studio 17 laptop, Windows 7
1 X MacBook Pro 2,2 GHz Core 2 Duo, 2 GB RAM, 160 GB HDD, 9400M
2 X iTouch
1 X HTC Desire (Android 2.1)
iPad soon to be added

codegit

#314
Quote from: Quentin on 2010-Feb-11
Are you able to display it with DRAWSPRITE?

YES ....  8)

SETCURRENTDIR("Media")

LOADSPRITE "bump.png",1
DRAWSPRITE 1,20,20
SHOWSCREEN
WHILE TRUE
WEND
------------------------------------------
1 X Acer TravelMate 4270, laptop, XP PRO
1 X Dell Studio 17 laptop, Windows 7
1 X MacBook Pro 2,2 GHz Core 2 Duo, 2 GB RAM, 160 GB HDD, 9400M
2 X iTouch
1 X HTC Desire (Android 2.1)
iPad soon to be added