Jump to content

george68

Members
  • Posts

    50
  • Joined

  • Last visited

Everything posted by george68

  1. Hi, Is there any rule that I can use in order to calculate the relevancy between the movement speed of a character and the speed of the walk animation in order to make the walk look as much better as it can be?
  2. I am not a pro but Debug is not only for troubleshooting but for developing also. Anyway, I noticed from the console output that the most of the time is spent on specific .tex file
  3. Hi, I noticed that the loading time for a map consisting of 4 models (one is animated) is too long. Leadwerks::Map::Load(getLevelName()) The code above runs on a Microsoft Visual Studio Community 2013 project, in the Debug configuration and it needs approximately 11 secs In the Release configuration the loading time is considerably shorter.
  4. @Rick & @Charrua: It works! This is what I needed.
  5. Oh I see.. I hoped that I could use the editor as my level editor for a game I want to develop it with C++ For example my game has many types of boxes with different properties. Placing these boxes in the editor is a piece of cake, but I'd like to have the ability to give different behaviors using custom properties for each one.
  6. No I don't Yes, that is what I was thinking. Here is the script: Script.ID = 1 --int "ID" Script.Owner = 1 --int "Owner ID" Script.Type = "BlockNM" --string "Type" Script.Dir = 1 --int "Direction" Yap, exactly. How I can do it? [EDIT] Thank you all for your time
  7. I created the world using the editor and I loaded the world using the C++. The cpp world is not empty because I found the entity with the name "block".
  8. I've placed a model into a map and attached to it a script with properties: using the code below I cannot access any key value: if (Leadwerks::Map::Load(getLevelName(iLevelCur))) { for (std::list<Leadwerks::Entity *>::iterator it=world->entities.begin(); it!=world->entities.end(); it++) { Leadwerks::Entity *ent = *it; if (ent) { std::string s = ent->GetKeyValue("name"); if (!ent->GetKeyValue("name").compare("block")) { ent->SetGravityMode(false); s = ent->GetKeyValue("ID"); Leadwerks::System::Print(s); } } } }
  9. Hi, I am trying to find a way of setting up custom properties for a model using the editor. One way is to create script properties but I don't know how I can access them using C++ Any help will be appreciated
  10. hmmm... strange I call the Clear() method: bool App::Loop() { if (window->Closed() || window->KeyDown(Leadwerks::Key::Escape)) return false; if (camera) { if (window->KeyDown(Leadwerks::Key::Space)) { camera->Release(); camera = NULL; context->Clear(); } } model->Turn(0, Leadwerks::Time::GetSpeed(), 0); Leadwerks::Time::Update(); world->Update(); world->Render(); context->Sync(); return true; } but the screen is flashing
  11. It sounds logical. I am wondering why it is not included in the 'Leadwerks.h' file.
  12. It didn't cross my mind. I am new to the Leadwerks That makes the job simple. Thanks
  13. In this case I have to draw all the 2D stuff again
  14. Please consider this piece of code: #include "App.h" App::App() : window(NULL), context(NULL), world(NULL), camera(NULL) { } App::~App() { delete world; delete window; } Leadwerks::Model *model = NULL; bool App::Start() { window = Leadwerks::Window::Create(); context = Leadwerks::Context::Create(window); world = Leadwerks::World::Create(); camera = Leadwerks::Camera::Create(); camera->Move(0, 0, -3); Leadwerks::Light *light = Leadwerks::DirectionalLight::Create(); light->SetRotation(35, 35, 0); model = Leadwerks::Model::Box(); model->SetColor(0.0, 0.0, 1.0); return true; } bool App::Loop() { if (window->Closed() || window->KeyDown(Leadwerks::Key::Escape)) return false; if (camera) if (window->KeyDown(Leadwerks::Key::Space)) { camera->Release(); // or camera->Hide() camera = NULL; } model->Turn(0, Leadwerks::Time::GetSpeed(), 0); Leadwerks::Time::Update(); world->Update(); world->Render(); context->Sync(); return true; } After pressing the space key, only a blank black screen should be visible. But strangely the cube is still visible, without rotating. How I can have the 3D world invisible when the camera is deleted?
  15. The statement '#undef GetFileType' there is in the App.h file In what does it serve for?
  16. Hi, Should I call the 'release' method for the world, context & window members which are members of the app object? What I should do specifically for the world pointer? Should I call the 'clear' method before the 'release' method? here is the d-ctor of the app object: CApp::~CApp() { world->Clear(); world->Release(); context->Release(); window->Release(); } Thanks in advance
  17. Its clear now. It works as expect it. Thank you both
  18. They are brushes. I don't know how to convert them to meshes using the editor. I am new to the editor and the leadwerks in general. I don't think they are one model. It is the map that comes with the default installation.
  19. Hi, I cannot access all the entities in the start.map file using the following code: . . . bool App::Start() { window = Window::Create("Hello World", 100, 100, 1024, 768, Window::Titlebar); context = Context::Create(window); world = World::Create(); if (Map::Load("Maps/start.map")) { for (std::list<Entity *>::iterator it=world->entities.begin(); it != world->entities.end(); it++) { Entity *ent = *it; if (ent) { int class_id=ent->GetClass(); std::string class_name=ent->GetClassName(); std::string keyval=ent->GetKeyValue("name"); } } } return true; } . . . Although the class_name is "Model" the keyval is an empty string "" Also iterating the Map I found only one model instead of two, a directional light and a camera I don't know what I am doing wrong.
  20. It seems that the editor cannot start without the Steam application running. I tried running the application: Leadwerks.exe from within C:\Program Files (x86)\Steam\steamapps\common\Leadwerks folder. A modal dialog box appears, with the following: Can't initilize program. Please start Steam I cannot understand why Steam is the only option. Thank you very much for the answers and the .pdf documentation
  21. Hello from new kid in town, Consider a scenario where there is no Internet connection or a Steam account (or website) is down for any reason. In that case I cannot install the Leadwerks engine even if I've already paid for this. I also would like to know, if I can have the API Reference available offline. Thanks
×
×
  • Create New...