Jump to content

Laurens

Members
  • Posts

    564
  • Joined

  • Last visited

Everything posted by Laurens

  1. Hi, I am currently facing a problem to which I see no other way out then multiple inheritance. I have never actually used it before but keep hearing from people you should probably stay far far away. The problem I have is this: I have class called Actor. This class is the base class for all other objects that have some sort of physical representation. It simply contains a TEntity. The class Tower inherits from Actor. The tower is an object that can establish a link with other towers over which it transfers energy. On a basic level this network of towers is a graph. I could implement a graph with a Graph class (the network), an Edge class (the links) and a Vertex class (the individual towers). I would then have the Tower inherit from the Vertex, but the tower already inherits from Actor. Is this situation a valid use for multiple inheritance or is it not, and more important, why? Would you perhaps solve this differently? Hope I made myself clear Thanks!
  2. I have not tried using my own shaders using Framework but this is probably a good place to start. http://leadwerks.com/wiki/index.php?title=Shaders
  3. Funny. Instead of EntityVisible I tried PointVisible passing the EntityPosition to see if it made any difference. It didn't. But when I hardcoded two positions in it did work. So I thought the source- and destination entity were actually preventing the visibility test. Now before calling EntityVisible again I hid both entities and showed them again afterwards. That did the trick. I can understand this behaviour for PointVisible but for EntityVisible it is a little weird I have to actually hide the entities for it to work. I know EntityVisible just calls PointVisible underwater but it would have been nicer if EntityVisible would have done the hiding for me. Josh? Perhaps this is something you can change in the next release. It would have saved me a lot of confusion Thanks everyone!
  4. Hi ZR, I have already tried that. It does not make any difference Which is what I expected though, visibility tests do not need to have collisions enabled.
  5. Laurens

    Zero Hour

    I have just played your game for a short while. Even while considering it's a beta I would include a playable map instead of a test map. Anyway. I liked the menu screens and the HUD layout although I would have used a different font for the ammo status (nitpicking). The starting area looked nice although the small wooden cabin was not scaled correctly and missed collisions. The AI did follow me around OK but found the walking animation a little to slow and they took to long to lift their gun and shoot me, which brings me to the sad fact I wasn't able to blow their heads of Performance was a little sub-par, running between 25 and 30 FPS on the specs in my signature. Otherwise nice to see you having progressed this far already! Cheers!
  6. Thanks for all the suggestions macklebee, sadly I have not been able to get it working. I tried the code in the Collisions and Raycasting tutorial which does not use collisions at all and it works flawlessly so the error must be something with me. Here is some more code: ForEachEntityInAABBDo(aabb, (BP)ForEachEntityInAABBDoCallback, (BP)entities); // Write all entities in AABB to a vector called "entities". for (vector<TEntity>::iterator i = entities->begin(); i < entities->end(); i++) { if (strcmp(GetEntityKey((*i), "type"), "Tower") == 0 && (*i) != node->GetEntity()) // If entity key "type" equals "Tower". { if (EntityVisible(node->GetEntity(), (*i)) == 1) // This does not work, always returns 0. { // Do stuff with the entity. } } } Hopefully someone can tell me where I went wrong. Thanks!
  7. Looks perfect on my ATI HD4870X2!
  8. Laurens

    Net Wars

    Could you post a screenshot? Perhaps we could give you some pointers on how to make it look better. I find your art style intriguing and think it would really benefit from subtle glow!
  9. Wow, I never knew BMax had that limitation. Good to hear it won't be a problem for LE3 though!
  10. Good to hear this is being fixed. I would love to see LE 3 to be object oriented out of the box though.
  11. I have tried setting all entity types to 1 for testing but still no luck. I have been over the tutorial on collisions and raycasting again (http://www.leadwerks.com/files/Tutorials/CPP/Collision_And_Raycasting.pdf) but the code is not using collisions at all. It does state that you can specify a collision type so only entities of that type will be tested, but it appears to be completely optional. Has anything changed since the tutorial was written that altered the behaviour perhaps?
  12. I have been looking for a way to pass the meshes to the EntityVisible command but there does not seem to be a GetMesh(entity) command or something similar. Is there such a command or did I went wrong elsewhere? Thanks!
  13. I love the design, can't wait to see the official docs this way.
  14. Thanks for your quick response DaDonik. I won't be in a position to try it out this weekend, but how does a mesh differ from an entity? In my testing code, I am actually creating both the source and the destination with the CreateSphere command, of which the wiki states returns a TMesh. I am however storing the sphere as a TEntity. Is this where I could be wrong? And if I were to eventually replace the CreateSphere with an actual object, how would I retrieve the mesh from the entity? Thanks!
  15. My system is modeled after the XNA Game State Management sample. I have a GameScreen class that in the constructor requires a mapname. The GameScreen then continues to load the specified level. If the level is over then I pop the GameScreen from a stack of Screens and push a screen with post-game statistics. When the player continues I just create a new GameScreen with a different mapname. http://creators.xna.com/en-US/samples/gamestatemanagement
  16. I can vaguely recall this review from DevMaster.net. Now tell me! Are you an actual SDK owner in hiding or did you pirate it?
  17. Hello, I have two entities that I need to perform a visibility test on. if (EntityVisible(source, destination) == 1) { // Do stuff with the source and the destination } The visibility test fails every time even though the source and the destination have a completely clear view of each other. A point visibility test using the position of the entities fails likewise. Do collisions need to be enabled for this? They weren't in any of the examples on the wiki. I got not results with collisions on either though so I am not entirely sure now. Anyone who can shed a light on this? Thanks!
  18. The database was rolled back as of a few hours ago. Perhaps you need to be reactived.
  19. Disregard that, decrementing the iterator did work. I was using this in a snippet of code that removed a GameScreen from a stack of screens. I removed the screen it was currently iterator over, then tried to get the previous one while there was only one screen left in the vector. Sorry to have wasted your time though!
  20. I was indeed hesitant to address it using an index because I was under the impression this was widely regarded as a bad practice. Guess it can't do any harm for this particular part of my application so I'll use it anyway then. Thanks!
  21. As Aggror said, the best way to learn is to teach others. So instead of creating boards for other languages we should maybe setup an english class
  22. Hi everyone, I have a vector with objects in my project that is iterated over. Depending on the state of the object iterated over, I need to get a reference to the object it previously iterated over. I have already tried i-- and (*(i--)) without result. Is this even possible? I would prefer it over just keeping a reference to the previous object in a seperate variable. Thanks!
  23. Having forums in different languages prohibit, say, german users from viewing questions and solutions on a dutch forum. Questions would be asked several times in different languages or others will go unanswered, simply because the person that holds the solution never visits the farsi forum. Having forums for multiple languages (or even one) would be a very bad thing IMHO.
  24. Hi, Last night I have been playing around to get CEGUI linked statically so I can get rid of all the DLL's in the working directory. I have it compiling and running just fine right now but there is one thing I worry about. I have changed the Code Generator from Multithreaded Debug DLL to Multithreaded Debug and I have the linker include the following dependencies: CEGUI and dependencies: - CEGUIBase_Static_d.lib - CEGUIOpenGLRenderer_Static_d.lib - CEGUITGAImageCodec_Static_d.lib - CEGUIExpatParser_Static_d.lib - CEGUIFalagardWRBase_Static_d.lib - expat_d.lib - freetype_d.lib - libpng_d.lib - jpeg_d.lib - zlib_d.lib - pcre_d.lib - winmm.lib Other required libraries: - opengl32.lib - glu32.lib It's fine that it is statically linking CEGUI and its dependencies but I doubt I need to statically link opengl32.lib and glu32.lib. Is this a problem or if not a problem, unwanted? Is there any way I can tell Visual Studio to exclude these from static linking? Thanks!
×
×
  • Create New...