Jump to content

cocopino

Members
  • Posts

    201
  • Joined

  • Last visited

Everything posted by cocopino

  1. Since it's a light, you'll probably need update() instead of draw() because draw() will only rotate the light when the light itself is being rendered. This will mean that it's not casting shadows and such when off screen. (I haven't tested this though)
  2. Thanks Aggror, but the total number of items always stays 10 using classnametable? I searched for "classnametable" and found objecttable instead, this is working. Thanks for pointing me in the right direction!
  3. Thanks, the "Where will it land?" formula looks exactly like what I need.
  4. Hi, I have a model that I can drag inside the editor, this model has a script (model.lua) How does one iterate through all instances of this model inside model.lua? Thanks!
  5. You can find out if it worked by using Findchild()
  6. Your code in #8: Local start:Int = 0 Local stop:Int = 9999 Local t1:Long Local t2:Long Local tt:Long Local ttt:Double Local tti:Long=0 Local ttx:Double While Not KeyHit(KEY_ESCAPE) t1 = MilliSecs() For Local i:Int = start To stop PositionEntity(cam, Vec3(1, 1, 1)) Next t2 = MilliSecs() Local tt:Float = t2 - t1 tti:+1 ttt:+tt ttx=ttt/tti Print "tt=" + tt + ", ttx=" + ttx UpdateWorld(); RenderWorld(); Flip(0); Wend You're calling MoveEntity(cube,vec3(1,1,1)) 9999 times and then updating once. This will make the cube move, not 9999 times (vec3(9999,9999,9999)) but only one time (vec3(1,1,1)) Don't get me wrong, the idea of doing a test like this can be very useful, but comparing commands like in your test isn't. These are not relevant speed tests: In a game, using MoveEntity more than once before an update is simply a design flaw.
  7. But it doesn't make any sense to run moveEntity twice (or a 1000 times) without updating. It's faster without updating because the command doesn't do anything. Run your code, then show your scene with a camera: your cube is still in the same spot (moved only once, not 10000 times)
  8. Strict Framework leadwerks.engine Graphics 800,600 RegisterAbstractPath AppDir If Not CreateWorld() RuntimeError "Failed to create world." Local cam:TCamera=CreateCamera() Local start:Int = 1 Local stop:Int = 50000 Local starttime:Long = MilliSecs() Local totaltime:Long For Local i:Int = start To stop MoveEntity(cam, Vec3(1, 1, 1)) UpdateWorld RenderWorld Next Local movetime:Float = (MilliSecs() - starttime) starttime = MilliSecs() For Local i:Int = start To stop PositionEntity(cam, Vec3(1, 1, 1)) UpdateWorld RenderWorld Next Local positiontime:Float = (MilliSecs() - starttime) Notify("move: " + movetime + ", position: " + positiontime) Running above Bmax code, PositionEntity is just a tiny little bit faster than MoveEntity (as I would expect) on my machine.
  9. MoveEntity : 16ms PositionEntity : 18ms This can't be right, can it?
  10. Here's what I've got so far: http://cocopino.eu/download/Cable.zip (unpack in your LESDK/models folder) Obvious problems are that the cables are gone when saving & loading the scene and that the texture shouldn't scale. Does anybody know if there's a LUA function that is triggered when loading/dragging an instance of an object into the scene? I would guess "Spawn" but this doesn't do anything for me.
  11. Ok, Michael. I'll give it a go. Have to start doing things with LUA anyway sooner or later. It will cost you... a couple of 3d trees. But since you already gave some of those to the community earlier I'll let you off the hook this time.
  12. Many thanks for sharing this with the community NA, very generous! Out of curiosity: what will happen with "semi-open" meshes (houses with doors, walls/fences etc.), will your algorithm find the entrance?
  13. Hi, A projectile with mass=1 is traveling from origin vec3(0,0,0) with velocity vec3(a,b,c) Does anybody know the formula to calculate where (point in 3D space) it will hit the ground (meaning y equals 0)? Assuming there's no air resistance and we're on earth (g=9.8) Thanks!
  14. UU3D = Ultimate Unwrap 3D www.unwrap3d.com
  15. It depends on your coding background. If you're proficient with C++ or .NET, stick with that and visual studio. If not, try BlitzMax: I had never touched it until I used Leadwerks but it will make you code like the wind. @mumbles (we're slightly derailing the thread here - my fault): Next time your grandpa/aunt/anyone else who uses their computer as a luxurious typewriter with email/internet asks for help, just install Ubuntu. Linux will never emerge from the shadows if only embraced by the "spotty nerds".
  16. I expected Lumooja to come up with wine sooner or later, you beat him to it! Yes, we'll probably never see the true power of OpenGL on Windows as we can on Linux. It just might be a little bit of a problem to convince the buyers/gamers to have a Linux machine ready for your game and run it with a Windows compatibility program (not an emulator)...
  17. - no windows XP: nope, see above - no nVidia card: is this a "wrong configuration"? (doesn't matter anyway, since the 10% is the same on both ATI & nVidia) - badly written engine: Ogre badly written?
  18. But then they would lose the ability to say: Look, our API is much better!
  19. No need for another flame war It depends on what you're doing with it of course, but at this point in time, when creating a windows/xbox only game, DX is the faster (FPS) choice.
  20. Yep, Microsoft plays a big part in this of course, they're not going out of their way to optimize for OpenGL when DirectX is their baby. But LE is Windows only... Ogre can render in both, but also pre-windows 7 (XP) running the same scene in Ogre, DirectX beats OpenGL by 10% or so.
  21. Ultimate Unwrap has been named already, it converts anything to anything. Well worth the purchase. An exporter has been written for 3D Max, and several converters exist to achieve the Leadwerks GMF format (fbx,dae,obj etc.) so it's safe to say you can just use the modeler you're comfortable with. What may be confusing at first is that all textures should be in DDS format and that all textured models need material files (which is just a text file stating the path to the texture and the shader it will use) @Lumooja: I've seen you state this several times now but unfortunately, DirectX is faster than OpenGL.
  22. Looking forward to seeing your game NA! I have several other machines to test it on besides the ones in my specs, should you be interested.
  23. Hi, haven't tried your code but I'm guessing you're parenting to the whole model when instead you only need a small part of it rotating. You can create a pivot (invisible entity) by using something like lampPivot = CreatePivot() then attach lights to it by light = createSpotLight(10,lampPivot) now you can turnEntity(lampPivot,vec3(0,1,0)) on every update
  24. Yes, very handy feature. If this is impossible, please at least consider a refresh button to reload assets.
  25. Radeon HD 4650 is the best low budget card according to this list: http://www.gizmodo.com.au/2010/06/the-best-graphics-cards-at-every-price/ Shader model 4.1 so I see no hurdles there.
×
×
  • Create New...