Engine-design related questions. How code is structured.

learn more… | top users | synonyms (2)

0
votes
2answers
130 views

Where to implement storable items

I'm creating a multiplayer online trading game. The things that are traded range from raw items to complex products. For example Steel is a raw item. Mechanical Assembly is a more complex item that ...
3
votes
2answers
143 views

knowing all available entity types

I'm making a game where at some point the game will create enemies of random types. Each type of enemy available is defined on its own class derived from an enemy superclass. To do this, obviously the ...
3
votes
1answer
467 views

Should components have sub-components in a component-based system like Artemis?

I am designing a game using Artemis, although this is more of philosophical question about component-based design in general. Let's say I have non-primitive data which applies to a given component (a ...
1
vote
1answer
126 views

How to model / where to store relational data between classes

I'm trying to figure out the best design here, and I can see multiple approaches, but none that seems "right." There are three relevant classes here: Base, TradingPost, and Resource. Each Base has a ...
8
votes
1answer
272 views

Architectural approaches to creating a game menu/shell overlay on PC/Linux?

I'm am working on a collection of games for a custom digital tabletop installation (similar to Microsoft Surface tables). Each game will be an individual executable that runs full-screen. In addition, ...
1
vote
2answers
1k views

References about Game Engine Architecture in AAA Games [closed]

Last weeks I focused on game engine architecture and learned a lot about different approaches like component based, data driven, and so on. I used them in test applications and understand their ...
2
votes
3answers
1k views

Snake Game Help

I am making a snake game and learning XNA at the same time. I have 3 classes : Game.cs, Snake.cs and Apple.cs My problem is more of a conceptual problem, I want to know which class is really ...
4
votes
2answers
2k views

Use a SQL Database for a Desktop Game

Developing a Game Engine I am planning a computer game and its engine. There will be a 3 dimensional world with first person view and it will be single player for now. The programming language is C++ ...
9
votes
4answers
755 views

How can I use multiple meshes per entity without breaking one component of a single type per entity?

We are just switching from a hierarchy based game engine to a component based game engine. My problem is that when I load a model which has has a hierarchy of meshes and the way I understand is that a ...
16
votes
6answers
1k views

Should Vector3 inherit from Vector2?

I'm creating a couple of classes Vector2 (X & Y) and Vector3 (X, Y & Z), but I don't know whether to make Vector3 inherit from Vector2, or whether to re-implement the member variables m_x and ...
4
votes
3answers
246 views

Debugging-Setting Consoles in Games

Right now I have the graphical and input portions of a console for my game (command parsing hasn't been implemented yet). I was wondering how you would go about making changes to properties in game ...
7
votes
4answers
2k views

Game Messaging System Design

I'm making a simple game, and have decided to try to implement a messaging system. The system basically looks like this: Entity generates message -> message is posted to global message queue -> ...
3
votes
1answer
228 views

Music Rhythm Game Difficulty Question

I have curious question about music rhythm based genre while I'm making a code for the game. Is it really better if I set a random pattern encountered on every music played or there is a specific ...
5
votes
1answer
259 views

Dynamic Components

I am attempting to design a component-based architecture that allows Components to be dynamically enabled and disabled, much like the system employed by Unity3D. For example, all Components are ...
6
votes
4answers
1k views

Pros and cons of using dlls

I wonder about create every game engine module (render, input, sound, etc...) into dlls (renderer.dll, input.dll, etc...). What are pros and cons in your opinion of divide game into set of dlls ? I ...
1
vote
2answers
208 views

Is 2 lines of push/pop code for each pre-draw-state too many?

I'm trying to simplify vector graphics management in XNA; currently by incorporating state preservation. 2X lines of push/pop code for X states feels like too many, and it just feels wrong to have 2 ...
15
votes
4answers
1k views

How does one save a procedural world?

I have recently read about how to create procedural worlds... but how do I save one? In games like Terraria or Minecraft users can freely modify the landscape, but that world can't be recreated from ...
-2
votes
3answers
2k views

C++ Game Engine Book/Tutorial/Anything recent? [closed]

Before I get flamed, please understand that I have been looking for a while now. Yes, I have found a good amount of game engine tutorials...except filled with errors, out of date syntax, missing ...
6
votes
4answers
3k views

Entity System and rendering

Okey, what I know so far; The entity contains a component(data-storage) which holds information like; - Texture/sprite - Shader - etc And then I have a renderer system which draws all this. But ...
2
votes
1answer
122 views

Managing different utility classes between engine and libraries

I'm currently in updating some engine code (which does not work, so it is more like creating a engine). I've decided to swap over to SFML (instead of my own crappy renderer, window manager, and ...
2
votes
1answer
292 views

2D scene graph not transforming relative to parent

I am currently in the process of coding my own 2D Scene graph, which is basically a port of flash's render engine. The problem I have right now is my rendering doesn't seem to be working properly. ...
0
votes
4answers
501 views

Programming Paradigm for Games [closed]

Which programming paradigm resembles or best suits the Game design or game engine programming? by paradigm I mean the Imperative, Object oriented, Functional, etc. I came to know that functional ...
0
votes
2answers
309 views

Designing a “Grid” like object that contains game objects

I am working on a 2D game, where there's a game "board" on which other game objects are placed. This this is 2D, my starting point was to design a class that will internally use a 2d array for the ...
1
vote
2answers
334 views

Best practice for designing a risk-style board game

I'm just trying to figure out how to set up the code for a game like risk... I would like it to be extensible, so that I can have multiple maps (ie- World, North America, Eurasia, Africa) so ...
2
votes
1answer
312 views

Techniques for separating game model from presentation

I am creating a simple 2D game using XNA. The elements that make up the game world are what i refer to as the "model". For instance, in a board game, i would have a GameBoard class that stores ...
11
votes
3answers
1k views

How to code UI / HUD in Entity System?

I think I already got the idea of the Entity System inspired by Adam Martin (t-machine). I want to start using this for my next project. I already know the basic of Entity, Components, and Systems. ...
3
votes
2answers
568 views

Adding sub-entities to existing entities. Should it be done in the Entity and Component classes?

I'm in a situation where a player can be given the control of small parts of an entity (i.e. Left missile battery). Therefore I started implementing sub entities as follow. Entities are Objects with ...
1
vote
4answers
2k views

SDL - Getting a single keypress event instead of a keystate?

Right now I'm working on a simple SDL project, but I've hit an issue when trying to get a single keypress event to skip past a splash screen. Right now, there are 4 start-up splash screens that I ...
-4
votes
1answer
214 views

What technologies are used for Game development now days? [closed]

Whenever I ask a question about game development in an online forum I always get suggestions like learning line drawing algorithms, bit level image manipulation and video decompression etc. However ...
2
votes
3answers
2k views

Entity System with C++

I'm working on a game engine using the Entity System and I have some questions. How I see Entity System : Components : A class with attributs, set and get. Sprite Physicbody SpaceShip ... System ...
3
votes
1answer
185 views

Using MVC with a retained mode renderer

I am using a retained mode renderer similar to the display lists in Flash. In other words, I have a scene graph data structure called the Stage to which I add the graphical primitives I would like to ...
6
votes
2answers
1k views

Low-level game engine renderer design

I'm piecing together the beginnings of an extremely basic engine which will let me draw arbitrary objects (SceneObject). I've got to the point where I'm creating a few sensible sounding classes, but ...
1
vote
2answers
530 views

Sharing VBO with multiple objects and fixed size buffer data

I'm just messing around with OpenGL and getting some basic structures in place and my first attempt resulted in each SceneObject class (just contains vertex information right now) having it's own VBO ...
11
votes
3answers
1k views

The reasons behind Unity3D engine design (game object/transform component)

I'm trying to understand the reasoning behind Unity3D engine design and this is something I can't get my head around yet: why is transform data stored in a separate component, instead of being a part ...
1
vote
1answer
298 views

Adjusting server-side tickrate dynamically

I know nothing of game development/this site, so I apologise if this is completely foobar. Today I experimented with building a small game loop for a network game (think MW3, CSGO etc). I was ...
9
votes
3answers
2k views

Component-based design: handling objects interaction

I'm not sure how exactly objects do things to other objects in a component based design. Say I have an Obj class. I do: Obj obj; obj.add(new Position()); obj.add(new Physics()); How could I then ...
0
votes
1answer
223 views

How to make smooth animations

Say I want to write a card game. I have a hand of cards and I want to be able to draw a smooth animation of a card moving from the hand to the table. I am looking for suggestions on how to elegantly ...
0
votes
2answers
200 views

Java applet game design no keyboard focus

THIS IS PROBABLY THE WRONG PLACE. POSTED ITHERE (STACKOVERFLOW) I'm making an applet game and it is rendering, the game loop is running, the animations are updating, but the keyboard input is not ...
6
votes
4answers
4k views

Why has the industry switched from C to C++?

First of all i would like to have a real answer, i'm always trying to get more from various sources and articles, and when I read things like C++ is slow because it has virtual functions and because ...
-5
votes
1answer
224 views

Should I use reference counting on entities in component-based entity system? [closed]

In component-based entity system, should game objects be reference counted? What about components? Tell me please your pro and contra.
1
vote
0answers
128 views

Saving/loading code structure

I have a tree of game entities composed of components. I want to save/load everything to xml file, where my saving/loading code must be located: Scene class containing root node and functions ...
2
votes
1answer
994 views

Managing the user input

I'm studying a good number of articles about this topic and seems to me that there is just one way to do this: a signal/slot design. I was also looking at some more complex async examples but I don't ...
1
vote
1answer
194 views

Game Engine Collision Handler

I'm making a collision handler for a Java game engine. I made an interface called Collidable. I have a method called onCollision which takes the parameter of my Engine Game Object. public void ...
2
votes
2answers
313 views

Should a 4x game use one class per planet type?

I'm try to make a small 4x game for my own educational purposes. Currently I have interfaces like IStarSystem which contains a list of IPlanets. My next step was to make classes implementing those ...
1
vote
2answers
693 views

Is there any option other than Component Based for game architecture?

Having read a lot recently on Component Based systems (for games), i find it hard to go back to my earlier state of mind. If static object hierarchies fail to model "objects with a dynamic set of ...
16
votes
1answer
1k views

How should I structure an extensible asset loading system?

For a hobby game engine in Java, I want to code a simple but flexible asset/resource manager. Assets are sounds, images, animation, models, textures, et cetera. After a few hours of browsing and some ...
4
votes
4answers
5k views

What is the most efficient container to store dynamic game objects in? [closed]

I am making a first person shooter and I know about about a lot of different container types but I would like to find the container that is the most efficient for storing dynamic objects that will be ...
0
votes
3answers
293 views

Central renderer for a given scene

When creating a central rendering system for all game objects in a given scene I am trying to work out the best way to go about passing the scene to the render system to be rendered. If I have a ...
2
votes
1answer
332 views

Efficient manager/controller for uniform and/or attribute variables in a rendering engine

Most engines on the market have their drawbacks and it's difficult to find a simple/light-weight one that's open-source and doesn't have to put you through a rather complex learning process. Writing ...
4
votes
0answers
240 views

What engine/technology should I work with to accomplish my unique design goal? [closed]

I'm looking to begin a procedurally generated open-ended sandbox game and would like some educated opinions on a good starting point. (Take a look at the "Engine Specifications" if you don't want to ...