Jump to content

reepblue

Developers
  • Posts

    2,491
  • Joined

  • Last visited

Everything posted by reepblue

  1. I was able to compile my project just fine with the delayload option, but it seems to be ignoring it. I'm probably going to refresh my projects being all the changes that happened recently.
  2. This has been updated so the header generated will now be named ComponentSystem.h instead of RegisterComponents.h.
  3. Can the installer create a System Environment Variable for where Ultra Engine is installed? I think this will help make installing tools and sharing C++ projects easier if we can just reference something like %ULTRAENGINEPATH% in batch scripts or the PropertiesSheet.props file. This is now more important as there's the Steam install and the standalone version.
  4. Noticed this too but I couldn't tell if this was intentional or a feature. I agree with you regardless. I don't like this.
  5. This looks like a huge time saver! With this enabled as a converter, no model will accidentally be left using png images.
  6. The code will remain C++ but in the future I plan to expose the more useful classes to Lua. The idea is that you can still have your game component code as Lua while the backend stuff is C++. I'm not sure how to manage/distribute something like this as I would be required to build the executables for all platforms on every release.
  7. Notice that components attached to entities with a parent don't save properly. I've ran into an issue where my camera (Which is a child of a pivot) rotation doesn't save automatically. I tried to patch this within the component, but then I noticed that the Load function is skipped when the scene is reloaded. Saving works fine. This example shows how the component load function is skipped on a scene reload call. #include "UltraEngine.h" using namespace UltraEngine; class TestComponent : public Component { public: TestComponent() { name = "TestComponent"; } void Start() { Print("Start"); } shared_ptr<Component> TestComponent::Copy() { return std::make_shared<TestComponent>(*this); } virtual bool Load(table& properties, shared_ptr<Stream> binstream, shared_ptr<Map> scene, const LoadFlags flags) { Print("Loading TestComponent"); return true; } virtual bool Save(table& properties, shared_ptr<Stream> binstream, shared_ptr<Map> scene, const SaveFlags flags) { Print("Saving TestComponent"); return true; } }; int main(int argc, const char* argv[]) { RegisterComponent<TestComponent>(); if (AllocConsole()) { freopen("conin$", "r", stdin); freopen("conout$", "w", stdout); freopen("conout$", "w", stderr); } //Get the displays auto displays = GetDisplays(); //Create a window auto window = CreateWindow("Ultra Engine", 0, 0, 1280, 720, displays[0], WINDOW_CENTER | WINDOW_TITLEBAR); //Create a world auto world = CreateWorld(); //Create a framebuffer auto framebuffer = CreateFramebuffer(window); //Load scene auto scene = CreateMap(); auto camera = CreateCamera(world); auto ent1 = CreatePivot(world); scene->entities.push_back(ent1); auto ent2 = CreatePivot(world); ent2->SetParent(ent1); ent2->AddComponent<TestComponent>(); scene->entities.push_back(ent2); //Main loop while (window->Closed() == false and window->KeyDown(KEY_ESCAPE) == false) { if (window->KeyHit(KEY_F5)) { //Save the starting scene to a file Print("Saving..."); scene->Save("game.sav"); } //Reload the starting scene when space key is pressed if (window->KeyHit(KEY_F6)) { Print("Loading...."); scene->Reload("game.sav"); } world->Update(); world->Render(framebuffer); } return 0; }
  8. As first mentioned here. Normals don't return the right value with GetWorld()->Pick() on brushes. It's fine with models. auto end = LoadModel(GetEntity()->GetWorld(),"Models/Developer/Widgets/normal.gltf"); auto p0 = GetEntity()->GetPosition(true); auto p1 = TransformPoint(0, 0, viewdistance, GetEntity(), NULL); pickinfo = GetEntity()->GetWorld()->Pick(p0, p1, radius, true); bool lookingatvoid = !pickinfo.success; if (!lookingatvoid) { // Set the end point to the position. end->SetPosition(pickinfo.position); end->SetRotation(0, GetEntity()->GetRotation(true).y, 0); end->AlignToVector(pickinfo.normal); } Wanted to make this it's own thread so it doesn't get forgotten.
  9. I've also seen files being identified as folders when a new file is added to the project when the editor is opened.
  10. On the subject of a widget, I think it's more important for the 3D viewport than the 2D viewports. I love moving things around in the 2D viewport, but in 3D, it can get a little sloppy. I mostly liked the widgets because they automatically showed the origin point and the entity's rotation (In local mode) without anything else being needed.
  11. I got to play with it and my first reaction was: The example models snap right into place where I want it to go. It feels so much better. For uniformed models, this is perfect, but I understand not every model is like this. Making brushes seems much better, but it might be a placebo effect. I'll have to play with it more. But I was the only one complaining about this, I guess let's see if anyone else finds this a step forward or backward.
  12. Maybe a small viewport should draw within the existing 3D viewport showing the camera render when the camera entity is selected.
  13. Most of the time, I place objects in the 2D view since it's closer to the File Browser panel. Maybe that should be more grid locked than the 3D view port? One of the few reasons I would use the 3D view to place objects would be to place objects on surfaces having the model's align to the surfaces normal which doesn't seem to be in the editor currently afaik. Also one feature (or bug) I don't like is when you place an object on the Top 2D grid view and the item gets placed on it's side. It's like the Top grid viewport is being handled the same way as Back/Side. I'll try to play with your changes tonight and get back to you.
  14. Here's the glass shader I used in Cyclone. You'll have to write code that'll replace texture slot 7 of the material with the probe's cubemap texture. LeadwerksGlass.zip
  15. Thought so (It's still a bug tho). This is why I thought it was the normal messing this up. Read this too fast. While the current system is correct I don't think it feels right. In Leadwerks, placing models in the scene snaps the model to the nearest grid point. This felt great especially when the model's origin accommodated the model. I don't want to manually type in the entity's position to get it back on the grid. This is what I want in the new editor with the option to turn it off for more natural placement of objects for rocks and such.
  16. Ok, this makes sense why it's not working as intended. I don't think the AlignToVector/pickinfo.normal on brushes is working as intended. This is my visual result on a model: Same code on the brush All I'm doing is: auto end = LoadModel(GetEntity()->GetWorld(),"Models/Developer/Widgets/normal.gltf"); auto p0 = GetEntity()->GetPosition(true); auto p1 = TransformPoint(0, 0, viewdistance, GetEntity(), NULL); pickinfo = GetEntity()->GetWorld()->Pick(p0, p1, radius, true, InteractionPickFilter); bool lookingatvoid = !pickinfo.success; if (!lookingatvoid) { // Set the end point to the position. end->SetPosition(pickinfo.position); end->SetRotation(0, GetEntity()->GetRotation(true).y, 0); end->AlignToVector(pickinfo.normal); } Edit: Maybe it doesn't have anything to do with it? It's a bug regardless..
  17. Cycles are fine since Leadwerks uses Blinn-Phong shading. I usually just bake the AO and everything else I do is in gimp. I'm not a professional artist! Also, you might find this helpful.
  18. Was this fixed in Build 201? I set my grid size to 2.56 and released my model exactly on the grid line and it's still off. This doesn't feel good.
  19. New build is up. This has the hands-off approach to pausing and the new SetActionSetCursor function for the game controller. Bug fixes and other small adjustments have are also included. There is also commented code for the Console as I was experimenting with how it should work. I've reached the conclusion that the Console Window will be enabled by a macro define by default. The next step regarding this is to restructure how UI Elements can work. You should be able to draw the same UIElement with the Interface or in Vulkan. This will also be useful for the settings too. Last, the Preprocessor application is the UAK version cutting down in file sizes.
  20. So far, I've found: Camera's Clear Color doesn't save within the map. Material's color (In the asset browser) will show a gray in the preview no matter what color it is. The Probe's color resets after a Global Illumination rebuild.
  21. Here are some materials, models, and textures you may use. Sources included. Github
  22. Well, the git repo is open to anyone. Maybe people will contribute to it. I personally just need Acheivements/Stats, Leaderboards, and Steam Input and I'm happy, but I get that people might need more. I can look into porting some of your code into this in the future.
  23. I was looking for this command too until I found the mesh pointer. Maybe this should exist?
×
×
  • Create New...