Jump to content

SpiderPig

Members
  • Posts

    2,347
  • Joined

  • Last visited

Everything posted by SpiderPig

  1. Pretty sure. I know there are optimizations made by the compiler (I'm not sure exactly what they are) but making that change to a few of my large loops made a massive difference. Mainly for Vec3 variables.
  2. No worries Also, (not sure if LUA is the same) but even things as simple as declaring a variable out side of a large loop can help. for(int id=0;id<1000;id++){ Vec3 pos = entity->GetPosition(); } The above will be slower than the loop below; Vec3 pos; for(int id=0;id<1000;id++){ pos = entity->GetPosition(); }
  3. I would think that the simple checking of a few variables would have a small effect compared to executing a lot of code in your function. It depends also on what type of code your executing, but the later would be more efficient. It's also what I do in C++ to gain better performance.
  4. You could not model the inside of the scope. That way you can see through the backfaces of the outside mesh. Might look okay... ?
  5. Another nice feature would be the ability to re-save a Texture as a .tex. Something like Texture->Save(string filename) perhaps.
  6. I can't seem to adjust the radius of my players character controller; physicsPivot->SetGravityMode(false); physicsPivot->SetDamping(0.0f, 0.0f); physicsPivot->SetPhysicsMode(Entity::CharacterPhysics); physicsPivot->SetCollisionType(COLLISION::PLAYER); physicsPivot->SetMass(1.0f); physicsPivot->charactercontroller->SetMaxSlope(80.0f); physicsPivot->charactercontroller->SetRadius(0.2f); float r = physicsPivot->charactercontroller->GetRadius(); The change is being detected in the variable "r" but in game there is no difference. Any suggestions?
  7. I find that sometimes it'd be nice to have multiple actors per entity. There are ways around it but involves a lot of coding. Something like AddActor() and RemoveActor(int index) would be useful.
  8. When loading models, by default each one is unique as if copied through entity:Copy() ?
  9. I'm not too sure... might need Josh to clarify...
  10. Instancing An instance of an entity will use the same geometry data within the GPU. You load one main mesh, then instance it to create hundreds more, rather than copying each objects data. The GPU still has to render each object, but its data is gathered from one place rather than several. The terrain vegetation system uses instancing as to not use huge amounts of memory.
  11. If you're not already, you can also use instancing, that may help.
  12. How does the PlayAnimation() time each frame? Is a speed of 1 dependent on FPS? If I have an animation that needs to run at 30 FPS, what would speed need to be?
  13. Not a problem mate Hope it helps. To get my game working on my other PC I had to install only openAL and vc_redist.x86.exe 2017
  14. I've tested it on my main PC that I use Leadwerks on and no issues. I'll try my other PC tomorrow too. On the your PC that its not running on, you can run the EXE via a BAT with this code. It'll print out the log to log.txt so if its crashing on map load it may show up something. Waffles.exe > log.txt I also noticed steam was installing PhysX? it was only on for a second so maybe it didn't... does Leadwerks need that? I didn't think it did but I might be wrong...
  15. No worries. I'll be on for a few hours yet so send when ready.
  16. Ridged Body should be okay for mode. The type won't change any physics properties, it's just a way of identifying different objects. If you could show small animation of what you have it might help. You may need to change friction values and lower the mass.
  17. Hi, what mass are you giving the balls?
  18. I can try it too if you like.
  19. Also are you including the right vs_redistributable.exe?
  20. Are you using lua or c++? I had issues with memory usage exceeding 2gb in c++, they were hard to track and seemed random, but I'm not sure how LUA handles it.
  21. Is there a chance there are files not being packaged with the game? Are you publishing with the "only include used files" option? Could try publishing without that checked and see if that works any different.
  22. Is your game downloadable from Steam? I can give it a go if you like.
  23. Does steam have its own installer where you can include additional dependencies? Or can we use our own to install OpenAL?
  24. if (Time::Millisecs() > lastTime + 1000L) { velChange = entity->GetVelocity(true) - lastVelocity; lastVelocity = entity->GetVelocity(true); lastTime = Time::Millisecs(); } I used this code to verify how fast it was accelerating per second, after setting Damping to 0 the change in velocity was a constant 9.8ms per second. So the original code works now. float _force = -9.8f * entity->GetMass(); entity->AddForce(0.0f, _force, 0,0f); Though it still seems too slow. The object just isn't falling fast enough. I could make it higher to it look right but I'd like to know why 9.8ms isn't enough...
×
×
  • Create New...