Jump to content
  • Advertisement

lockandstrike

Member
  • Content Count

    5
  • Joined

  • Last visited

Community Reputation

129 Neutral

About lockandstrike

  • Rank
    Newbie
  1. lockandstrike

    Polymorphism with C++/Lua

    @Hodgman or @Alberth , could you give an example of how you would implement such a thing, I'm very new to Lua so I'm not sure how I could do that.   @Mike2343 , yeah, but my component system is a map as such: std::unordered_map<std::type_index, std::shared_ptr<Component>>; And I want the component types to be expandable through Lua
  2. So I'm trying to design an ECS system and I want to use Lua as my scripting language since it's regarded as very powerful and its widely adopted so its easier to maintain. Right now I want my component interface to be exposed to Lua and expandable. What I mean is, having the very simple following code:  struct Component { virtual ~Component(); }; How can I make it so that a Lua script can create child components uppon that struct?   Thank you.
  3. lockandstrike

    Runtime Error With Opengl App

    Thank you both @Kylotan and @frob, got it working for now
  4. lockandstrike

    Runtime Error With Opengl App

    Ok, I've commited what I think are the changes that reflect what you said we're the possible bugs but now I'm still getting a segfault in the same call.   The backtrace is   "#0  0xabababab in ?? () #1  0x004021b3 in StateManager::Loop (this=0x6bfeec) at src/StateManager.cpp:89 #2  0x004014b9 in main () at src/Main.cpp:19"   and if I step into the  (*it)->Event (); and continually step until the program crashes, this is the log:   https://gist.github.com/lockandstrike/af392b9ab4230a28a509e548e0cccfc1   So, aparently it's crashing in the same spot but now the memory address is way bigger, 0xabababab, and I'm not sure what that means.
  5. So I'm trying to create a sort of game engine in c++ with opengl, using glew and glfw but my very first steps aren't going very well. First off, before I get the usual, you don't need to create your own engine because there are plenty good engines out there, I know, but this is a learning project. That said, I got the program to compile and now I'm running into runtime errors that I'm not being able to fix.   The code is in this repository: https://github.com/lockandstrike/GameEngine   When I run it through gdb it says    "Program received signal SIGSEV, Segmentation fault. 0x00000320 in ?? ()"   and the backtrace is   "#0  0x00000320 in ?? () #1  0x004020cb in StateManager::Loop (this=0x6bfeec) at src/StateManager.cpp:81 #2  0x004014b9 in main () at src/Main.cpp:19"   I've spent hours looking through it and I cant find the cause of the problem, I would be tremendously happy if someone could help me out.
  6. lockandstrike

    2D Terrain Random Generation

    It is a straight top view and the player can only certain blocks, being these the ores or the trees in the random terrain. Anything inside the cities is utterly unbreakble.   Many thanks in advance, GreyGameStudio
  7. So I'm writing an 2D RPG in Java and my idea is somewhat different from the normal. There will be cities that will always be the same and placed in the same area and the rest of the world is randomnly generated with ores and other resources so the player can mine and then pay the artisans of the city to craft what he wants.    My question is: how do I do the random terrain generation(I've been looking into perl noise algorithms) and then place the cities?     Many thanks in advance, GreyGameStudio
  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!