Jump to content

MoustafaChamli

Members
  • Posts

    32
  • Joined

  • Last visited

Everything posted by MoustafaChamli

  1. *headdesks* After having changed with how the jump mechanic was working (as originally programmed), I came to the realization that this calculation wasn't needed. I think we can consider this topic closed.
  2. I think gamecreator is on to something. If I use this: float Velocity = _model[currentWorld]->GetVelocity().z; It seems to work, up to a point. When we reach maximum speed, the character actually jumps backwards! If I try to compile with the following, though: float Velocity = _model[currentWorld]->GetVelocity().z; float Speed = Velocity->Length(); It returns that the base operand of '->' (on the second line) is not a pointer.
  3. Thanks for your answers guys, but this is a C++ question.
  4. We're making some motion changes due to the nature of the game, and one of them affects jumping. Right now, it's set up to use a static variable called "JUMPBOOST". We'd like to change that to use the character's current velocity to affect his jump distance (as we have three moving speeds). if (inputInfo->jumpDown && !_model[currentWorld]->GetAirborne()) { jump = JUMPFORCE; homeBaseMovement->z = homeBaseMovement->z * JUMPBOOST; anim = Animation_type::run_jump_rise; isJumping = true; moveType = Move_type::jumping; } We've looked into using GetVelocity, but can't seem to figure what's missing to apply it properly.
  5. I'm having the same issue. But my cbp line already had <Add library="../../libsteam_api.so" /> I'm looking over the other thread you started (this one) for answers, but I'm not sure I get how you got it working. I'll add a further explanation on that thread.
  6. Correction: The Leadwerks exporter does get the animations. From what I can tell, the model exports just fine. It's the moment any textures are applied, whether they were the correct ones we made, or ones available from the engine, bits of the character would fail to display, or the face will distort. Here'a screenshot with lighting enabled: http://studioslune.com/wp-content/uploads/2014/09/screenshot14.jpg Here's one without: http://studioslune.com/wp-content/uploads/2014/09/screenshot15.jpg Any ideas?
  7. Exporting with the Blender Exporter seems to ignore the embedded animations, even when I select the rig on export.
  8. More information: I'm using Blender's ASCII-based FBX exporter, as the Blender exporter and the FBX binary exporter don't seem to produce usable results with my setup. This might have something to do with the issue I'm seeing.
  9. I think I managed to get something decently close to what I was looking for, using a combination of shader scripting, post-processing, and general illumination. It's not quite what I had in Blender but it'll do for now.
  10. When I apply a material to one of the imported models, the models stop being displayed in the Textured+Lighting render mode. I've tried this on my own machine and one of my colleague's, and the issue is reproducible. Additionally, it would seem any characters that have a face rig get deformed when in Textured+Lightning render. Is threre any reason why this might happen?
  11. I'm getting "couldn't find any exportable objects" when I tell it to only export what's selected. Is that an expected behaviour?
  12. That doesn't quite work, as this makes the model go completely black. I ended up doing this: vec3 color = ambientmat + df*ex_diffuse + sf*specmat; fragColor = vec4(color, 1.0) + texture(texture0,ex_texcoords) * 1.0; But that doesn't take into account the "toon" shading. I'll take a look at your code for the post-effects shader, see if I can use bits of it. I'm not looking for something that's like Borderlands (see screenshot above).
  13. Actually, initial OGL4 support is arriving on Linux, although it might take some time before most distros adopt it (http://www.phoronix.com/scan.php?page=news_item&px=MTcyNzI) That said, I'm getting close to a working solution, having looked around the web for some guides. Right now, I'm mostly stuck with an invalid operand on line 88 of the fragment code. Here's a link to the Fragment: http://pastebin.com/nDtDFnLx I figure that if I can get this, I should be able to get a working "toon" shader for the game. Just note that there are a lot of commented functions, as I'm still messing around with the code.
  14. I'm getting a better grasp at GLSL overall, and it would seem I'd need to update the code to work with OpenGL4 as it seems Blender mostly uses OpenGL2.1 Getting a 3.3 and OGL2.1 fallback would be great overall, to be quite honest. I know Josh is working on a OGL3.3 fallback, so there's that.
  15. I've tried that, and it wouldn't read them correctly. But now that I'm a bit more familiar with how it works, I'll try again to see the results, and what needs to be corrected.
  16. I've been having trouble getting SDL to work with Leadwerks on Linux. It builds fine on Windows, but I've been getting the following error: ‘SDL_GameControllerAxis’ is not a class or namespace I set up Code::Blocks to use these: Compiler search directories: /usr/include/SDL2 Link libraries: /usr/lib/i386-linux-gnu/libSDL2.so Options: -lSDL2 -lSDL2main Am I missing anything? Could I be pointed in the right direction? I have installed the libsdl2-2.0-0 and libsdl2-dev (with the ":i386" option) packages. Thanks!
  17. It got me started in the right direction. It would seem Leadwerks mostly looks at the @OpenGL4.vertex and @OpenGL4.fragment sections, so I'll fiddle with those.
  18. Sorry to resurrect this thread, but I've been having trouble getting SDL to work with Leadwerks on Linux. It builds fine on Windows, but I've been getting the following error: ‘SDL_GameControllerAxis’ is not a class or namespace I set up Code::Blocks to use these: Compiler search directories: /usr/include/SDL2 Link libraries: /usr/lib/i386-linux-gnu/libSDL2.so Options: -lSDL2 -lSDL2main Am I missing anything? Could I be pointed in the right direction? I have installed the libsdl2-2.0-0 and libsdl2-dev (with the ":i386" option) packages. Thanks!
  19. That corrected it. I was (still am) having trouble compiling SDL2 with Leadwerks on Linux, and it would seem that in my attempts to correct this, I removed libGLU.
  20. It seems like I have a missing file when compiling. I looked in the directory where it's supposed to be (Leadwerks/Include/Libraries/glew-1.6.0/include/GL/) and I can't seem to find it. This occurs when compiling on Ubuntu.
  21. I'm trying to get an understanding as to how I would go about to do this, but it would seem the documentation for this is either sparse, or outdated. I don't seem to find any shaders.pak file, and there's no indication as to how I'm supposed to use a .vert and .frag file to get a Leadwerks compatible shader. Please note that I'm essentially doing this to assist our programmer. My actual skills are still in the early stages, so not knowing where what goes in which directory/file is a bit problematic. Even just a base "put file in this directory and compile" would be a good start. Thanks.
  22. It's from an add-on script. And seeing the length of the script really made me think there was a lot of cruft in there. Is there something specific I can take from the .frag to make it more manageable?
  23. Here's what I currently have. It likely has a lot of cruft in there, so any advice as to what to remove would be appreciated: http://pastebin.com/x1H6G9WW
  24. Non-photorealistic shading. This is a real-time render taken directly in Blender: I can also provide the .vert and .frag files if that helps.
×
×
  • Create New...