Jump to content

Josh

Staff
  • Posts

    23,140
  • Joined

  • Last visited

Everything posted by Josh

  1. I need to trim some things down in order to focus and make progress. The Quake plugin will be removed from the distribution and will no longer be supported, but the source code is available here: https://github.com/UltraEngine/PluginSDK/tree/master/Plugins/Quake Loader
  2. I think I am going to rewrite this using this lib: https://github.com/zlib-ng/minizip-ng
  3. It's a bug. I am not sure right now if ZIP should even be used, or if ziplib should be swapped for libzip...
  4. #1 won't be changed. Environment maps have to be set for older map files. #2 will be fixed in the next build.
  5. #3 and 4 are already fixed.
  6. 0.9.5 Implemented specular / gloss shader family IMPORTANT: You must delete your C:\ProgramData\Ultra Engine\settings.json file, or at least open the file up and remove the currently opened folder setting. You must update any project's shaders before opening it, because the material structure in the shaders has added members and is no longer the same size. If you don't do this, you will get no rendering and your graphics driver may crash.
  7. Are you using the standalone or Steam build?
  8. It seems this will happen with any model, with any component, but does not occur with brushes...
  9. face.size is the number of vertices in that face. Each face can have any number of vertices, so it can combine quads, triangles, or anything else with three or more vertices. Most of the time this will just be triangles.
  10. I recommend uploading your project so we can take a look at it.
  11. Fix is incoming. Sketchfab models use this a lot.
  12. Josh

    Converting

    The collider file contains parts that are convex hulls with zero vertices. I did not realize this was even possible. I added some checks to prevent this from causing a problem in the future.
  13. 0.9.5 Added a good SSAO post-processing effect that handles antialiasing.
  14. 0.9.5 Post-processing effects now use a regular 2D texture for PREVPASS and auxillary buffers, but use a 2DMS texture for the original color, normal, and depth buffers. Post-processing shaders must be updated in your project. Temporarily removed SSAO post-effect. Added antialias option in editor viewport settings. Fixes for AMD compatibility with SPIR-V.
  15. 0.9.5 Fixed remaining issues with SPIR-V that were causing problems on AMD card with terrain. Only editor is updated, rest will come tomorrow.
  16. Yes, I have not written the spec/gloss shader.
  17. 0.9.5 Got rid of a nasty bug in terrain sculpting that could cause a crash after a few moments of continuous use.
  18. 0.9.5 World properties have been moved into a new dialog, available with the Edit > World Settings menu. Editor now supports a single directional light, in the world settings dialog. No changes were made to the way directional lights work in the engine / API. They are still just a normal entity. Fog settings are available in world settings. Post-processing effects are available in world settings. Some of my post-processing shaders are not very good and need work. Some environment settings like the cubemaps used need to be set again, as they will not be loaded from existing maps. All these types of properties have been moved into an "Environment" block in the JSON structure. Fog and post-effects will be applied to all cameras that are created inside a call to LoadMap, whether the camera is loaded from the map or created in code with a component.
  19. Sure. It's a JSON string followed by byte 0, and then any binary data follows that. All offsets are relative to the start of the binary data, not its absolute position in the file. bool Collider::Save(const WString& path, const SaveFlags flags) { auto binstream = CreateBufferStream(); auto stream = WriteFile(path); if (stream == NULL) return false; nlohmann::json j3 = nlohmann::json::object(); if (shapeid == COLLIDER_COMPOUND) { j3["collider"]["parts"] = nlohmann::json::array(); for (int n = 0; n < this->subshapes.size(); ++n) { nlohmann::json subshape; switch (subshapes[n]->shapeid) { case COLLIDER_BOX: subshape["shape"] = "BOX"; break; case COLLIDER_CYLINDER: subshape["shape"] = "CYLINDER"; break; case COLLIDER_SPHERE: subshape["shape"] = "SPHERE"; break; case COLLIDER_CONE: subshape["shape"] = "CONE"; break; case COLLIDER_MESH: subshape["shape"] = "MESH"; j3["collider"]["optimized"] = subshapes[n]->optimizemesh; break; case COLLIDER_CONVEXHULL: subshape["shape"] = "CONVEXHULL"; j3["collider"]["tolerance"] = subshapes[n]->tolerance; break; } if (subshapes[n]->shapeid == COLLIDER_CONVEXHULL) { subshape["vertices"] = subshapes[n]->finalvertices.size(); subshape["data"] = binstream->GetSize(); for (const auto v : subshapes[n]->finalvertices) { binstream->WriteFloat(v.x); binstream->WriteFloat(v.y); binstream->WriteFloat(v.z); } } else if (subshapes[n]->shapeid == COLLIDER_MESH) { subshape["faces"] = subshapes[n]->meshfaces.size(); subshape["data"] = binstream->GetSize(); for (const auto& face : subshapes[n]->meshfaces) { binstream->WriteInt(face.size()); for (const auto& pos : face) { binstream->WriteFloat(pos.x); binstream->WriteFloat(pos.y); binstream->WriteFloat(pos.z); } } } else { subshape["size"] = { subshapes[n]->size.x, subshapes[n]->size.y, subshapes[n]->size.z }; subshape["offset"] = { subshapes[n]->position.x, subshapes[n]->position.y, subshapes[n]->position.z }; subshape["rotation"] = { subshapes[n]->rotation.x, subshapes[n]->rotation.y, subshapes[n]->rotation.z }; } j3["collider"]["parts"].push_back(subshape); } } else { j3["collider"]["parts"] = nlohmann::json::array(); j3["collider"]["parts"].push_back({}); switch (shapeid) { case COLLIDER_BOX: j3["collider"]["parts"][0]["shape"] = "BOX"; break; case COLLIDER_CYLINDER: j3["collider"]["parts"][0]["shape"] = "CYLINDER"; break; case COLLIDER_CHAMFERCYLINDER: j3["collider"]["parts"][0]["shape"] = "CHAMFERCYLINDER"; break; case COLLIDER_CAPSULE: j3["collider"]["parts"][0]["shape"] = "CAPSULE"; break; case COLLIDER_SPHERE: j3["collider"]["parts"][0]["shape"] = "SPHERE"; break; case COLLIDER_CONE: j3["collider"]["parts"][0]["shape"] = "CONE"; break; case COLLIDER_MESH: j3["collider"]["optimized"] = optimizemesh; j3["collider"]["parts"][0]["shape"] = "MESH"; break; case COLLIDER_CONVEXHULL: j3["collider"]["tolerance"] = tolerance; j3["collider"]["parts"][0]["shape"] = "CONVEXHULL"; break; } if (shapeid == COLLIDER_MESH) { j3["collider"]["parts"][0]["faces"] = meshfaces.size(); j3["collider"]["parts"][0]["data"] = binstream->GetSize(); for (const auto& face : meshfaces) { binstream->WriteInt(face.size()); for (const auto& pos : face) { binstream->WriteFloat(pos.x); binstream->WriteFloat(pos.y); binstream->WriteFloat(pos.z); } } } else if (shapeid == COLLIDER_CONVEXHULL) { j3["collider"]["parts"][0]["vertices"] = finalvertices.size(); j3["collider"]["parts"][0]["data"] = binstream->GetSize(); for (const auto v : finalvertices) { binstream->WriteFloat(v.x); binstream->WriteFloat(v.y); binstream->WriteFloat(v.z); } } else { j3["collider"]["parts"][0]["size"] = { size.x, size.y, size.z }; j3["collider"]["parts"][0]["offset"] = { position.x, position.y, position.z }; j3["collider"]["parts"][0]["rotation"] = { rotation.x, rotation.y, rotation.z }; } } if (not properties.empty()) j3["extras"] = properties; stream->WriteString(j3.dump(1, ' '), false); if (binstream->GetSize()) { stream->WriteByte(0); stream->Write(binstream->data->Data(), binstream->GetSize()); } stream->Close(); return true; }
  20. You might want to just use the Steam build if you have any other problems.
×
×
  • Create New...