Engine-design related questions. How code is structured.

learn more… | top users | synonyms (2)

6
votes
1answer
512 views

What structure is best used to model maps for games like Bard's Tale / Dungeon Hack?

I would like to create or use an existing JavaScript engine to build a game in the spirit of Dungeon Hack, Eye of the Beholder and older Might & Magic games. Going off my memory playing these ...
2
votes
2answers
499 views

How do I design a game framework for fast reaction to user input?

I've played some games at cca 30 fps and some of them had low reaction time - cca 0.1sec. I hadn't knew why. Now when I'm designing my framework for crossplatform game, I know why. Probably they've ...
3
votes
3answers
694 views

Why large builder classes rather than separate clases in component-based entity systems?

I was reading about component-based entity systems and I was wondering why there is usually a large EntityBuilder class with methods like CreatePlayer(), CreateEnemySpaceship(), and CreatePowerup(), ...
10
votes
5answers
3k views

How to properly handle collision in a component-based game?

Trying to wrap my head around the ways to properly handle collision in a game designed around components. I see many examples have some sort of PhysicsComponent that gets added to the entity's list ...
9
votes
2answers
2k views

What's the difference between XNA Game Services and glorified global variables?

The Microsoft.Xna.Framework.Game class has a Services property that allows the programmer to add a service to their game by providing the type of the class and an instance of the class to the Add ...
7
votes
4answers
891 views

How can I improve this enemy database implementation?

I'm developing an RPG and I'm at the point where I need to start building an enemy database. There's a couple challenges associated with this and a few solutions I've been considering. Here's what I ...
1
vote
1answer
637 views

Is my technique for client-side character movement in an MMORPG reasonable?

I started an MMORPG game, and I can already make a character move around the map and see other characters. But I have doubts about my architecture. I have a loop which, every x milliseconds, request ...
3
votes
2answers
345 views

Starting a Game Dev Incubator - Engines to Start With?

I'm currently in the process of developing a technology incubator in my region to cater to game development professionals and aspiring devs and I'm curious about what engines are best to use, with ...
7
votes
2answers
1k views

Is Domain Driven Design good for games?

I've just read about Domain models and it enlightened me since I've been developing a game that has a class which only holds data (few behaviors/methods). I assigned the job of handling these classes ...
11
votes
2answers
3k views

Is this the right architecture for our MMORPG mobile game?

These days I am trying to design architecture of a new MMORPG mobile game for my company. This game is similar to Mafia Wars, iMobsters, or RISK. Basic idea is to prepare an army to battle your ...
4
votes
2answers
911 views

How do I store Items in MySQL?

I'm working to my first game containing items (built a small one before, strategy type but not very complicated). I was thinking something like this for the db design since it will be almost the same ...
4
votes
2answers
294 views

Writing a wrapper vs not writting a wrapper?

So the question is I am going to use Ogre3D as the rendering engine for our 3D software, I am not sure if I need to use the engine as it is vs writing a wrapper for the parts I want to use, what are ...
19
votes
2answers
2k views

If “ResourceManager” classes are considered bad, what are the alternatives?

I'm hearing conflicting opinions such as: "Dedicated Manager classes are almost never the right engineering tool" "Dedicated Manager classes are (currently) the best way to survive a large project ...
2
votes
3answers
1k views

Question about “Entity System” design

I am developing a top down 'thing' in SFML and C++ and was wondering about how best to handle so called Entities in my game. An entity, for example is defined by me as an object in-game, such as a ...
6
votes
4answers
714 views

How should I go about abstracting away the graphics device?

I would like to be able to move my game from using a XNA graphics device to possibly an OpenGL device in the future. So I'd like to have a somewhat abstract interface to submit polygons to. Its ok if ...
1
vote
2answers
638 views

Enemy class architecture

I'm developing a game for Android in Java. I would like to know how a good Enemy class architecture could be implemented. I've created an abstract class called Enemy. It stores common properties like ...
9
votes
9answers
6k views

What's a good Open Source game to learn from? [closed]

I want to download the source code of an Open Source game, so I can get familiar with game architecture. Does any one know of a game with source code that's legible, and easily understandable? Edit: ...
26
votes
3answers
1k views

How to handle multiple story threads in a RPG game?

I designed an RPG game that has multiple story threads, meaning that, depending on the user's choice some things may or may not happen, you can achieve the same thing in several ways, the ending can ...
15
votes
3answers
3k views

Game engine and data driven design

I've heard about data driven design and have been researching about it for a while. So, I've read several articles to get the concepts. One of the article is Data Driven Design written by Kyle ...
-2
votes
3answers
416 views

The best open source CMS for developing a statistic based football game? [closed]

I want to decide between Drupal and Joomla for building a football prediction game which automatically updates results from football matches and then user leagues with points based on the users ...
0
votes
2answers
223 views

Which parts of my game should be Activity objects?

Currently my game has an Activity for the splash screen then it starts the main class activity then it starts a menu activity then from the menu there is an activity for each option (only two at the ...
4
votes
3answers
1k views

How would you structure a weapon class such that it works for many types of weapons?

How would you go around creating a reusable weapon class? I can't really wrap my head around creating a class, which will work for both melee and ranged weapons. Example given, that you have a knife, ...
7
votes
3answers
332 views

How does the camera/UI know who the player is?

I'm in a bit of a dilemma regarding how certain engine components — like camera and UI — know who to follow, whose health and other attributes to represent on the screen. How do you ...
4
votes
4answers
2k views

How do you organize your game files and classes? [closed]

Although it isn't necessary to exclude things like graphics and audio packages, I'm most interested in the organization of the folders for classes that deal with AI and game state. I'm thinking ...
8
votes
7answers
435 views

Object updates, internal vs external?

The title is a bit confusing, but I couln't think of how to explain my question in a short phrase. So here it is: Whenever I'm writing game engines, wheter it's physics/tilebased etc, I always get to ...
5
votes
2answers
790 views

How can I implement shader lookups for my material system?

I have been working on a material system and for the most part everything works just fine, however, I hard code the shader that will be used. Obviously this causes a problem when I want to have the ...
10
votes
2answers
586 views

Correct way to abstract an XBox Controller

I've got a XBox360 controller which I'd like to use as input for an application. What I can't work out is the best-practice way to expose this via an interface. Behind the scenes, the class which ...
7
votes
3answers
468 views

Events, Posting vs Queuing

I'm implementing a messaging system and I'm wondering about how I should handle events. Should I post them and send them to the appropriate listeners as soon as I receive them, or should I queue them ...
5
votes
2answers
798 views

Handling collisions with ground

How do you usually solve collisions between entities and the ground? Sending collision events hardly seems appropriate since almost everything touches the ground at almost all points in time. Calling ...
12
votes
2answers
892 views

XNA: Questions regarding games architecture

So I've finally got around to playing around with XNA and have been toying around with making a 2D game (I have a bunch of art assets from a friend who developed it on iOS) A lot of things seem to be ...
2
votes
2answers
431 views

handling errors in a framework

I'm writing a D3D11 framework and I'm trying to clean it up a little, and I'm unsure how to handle errors and return codes in my classes/code. What is the "best" and cleanest way to implement error ...
1
vote
2answers
549 views

3D game: is a spatial index necessary?

I'm working on a 3D space simulation game in C++. I've read that in many cases games use spatial indexing (hashing) that allows to quickly detect collisions, find out what entities to draw and so ...
12
votes
2answers
3k views

Inheritance vs Composition

I make my money in C# Generally in that language I like to decouple everything to the high heavens using interfaces. This has served me well in enterprise code but in writing games in C# I find myself ...
0
votes
1answer
558 views

Want to develop my own primitive physics engine, don't know how to start with its high-level architecture. Suggestions? [closed]

Few years ago I tried to make a simple 3D game - billiards. Completed like 50%, stuck with physics. Basically, I only need to calculate balls rolling over flat surface, but it would be nice to make ...
4
votes
3answers
723 views

Designing the main classes in a solar system simulation game in C++

If this is not the right place for this question, could you please direct me to a more suitable site/forum? I'm a beginner in game development (and in the use of this site). I've worked with C++ only ...
1
vote
3answers
1k views

XNA Entity Component Design: Lost on how to include Sprite Animation

I've been reading about Entity Component design and thought it's pretty neat. I've been trying to write a quick 2D engine in XNA. I think I've laid the proper groundwork for registering and updating ...
-1
votes
1answer
291 views

What engines and tools do high end games use? [closed]

First of all, I am a beginner developer so please don't get me wrong. I just want to know what programs do high end games use. By high end I mean games that me and you would buy, say Splinter Cell, ...
2
votes
3answers
2k views

Using SQL for a Realtime Multiplayer Game Server's Working Data (Fast Enough?)

The game I'm working on currently has a Client in Flash AS3, and a Server in C# (multithreaded). Currently I use mySQL to handle logins (Raw access: no middleman for accessing the database) which ...
2
votes
3answers
733 views

Design pattern on class level, how to do separation of concerns through mvc or alike?

Say i had a Monster class public class Monster { } Now this class has a set of properties like int health int speed int weaponDamage which details the core information about the monster. in ...
5
votes
1answer
707 views

Separating Sprites from Models with PyGame

So I'm trying to code a game using the Model-View-Controller pattern, and therefore have a need to separate the models for my game objects with their sprite representations. The problem that I'm ...
13
votes
3answers
1k views

Avoiding singleton pattern for Event Scheduler?

I want to make an Event scheduler for my Game, I basically want to be able to schedule the triggering of a Game Event. This can be a one time trigger, or a periodic trigger (trigger event ...
17
votes
4answers
1k views

Game engine: a decent way, architecture-wise, to implement scripting support?

I am developing a simple game engine (in C#, if it matters), and I can't think of a decent enough way to implement scripting in terms of architecture. It's a simple turn-based strategy with custom, ...
8
votes
2answers
428 views

Manage a large number of independent actors in real-time

I am working on a large scale real-time strategy game - ideally with thousands of units active at once - but I am having trouble managing all of the units at once without it becoming astonishingly ...
4
votes
2answers
1k views

Container classes in tile-based games.

I've recently begun working on a tile-based tactical game, and I have questions regarding a couple of key moments. Is it feasible to organize the tilemap as an array of containers, which can hold the ...
11
votes
3answers
706 views

I want to get rid of my make-everything-static-and-global design pattern, but how?

I'm making a little dungeon crawler in space, and I'd like to hear some advice on how to make the backend of the engine nicer. Basically, currently everything is based on a crapload of managers: ...
8
votes
3answers
730 views

I would like to know how an OpenGL driver will be implemented to learn opengl internals?

I'm learning OpenGL and really like to know how the interaction with the Graphics card will be. I feel understanding how it was implemented in the Graphics driver, will let me know complete internals ...
3
votes
1answer
459 views

Engine Design for Rendering Reflections

I have a very simple game engine. A GameObjectManager stores a collection of all the GameObjects. When I want to render, I just call GameObjectManager.render() from the rendering context. This works ...
0
votes
2answers
334 views

Obtaining a certain type of object with component based design

I'm trying to design my game to be component based rather than overly hierarchical. Essentially, every high level object in the game (like gun, or whatever) inherits and implements the interfaces that ...
5
votes
1answer
778 views

How do particle systems work?

I want to implement a particle system in my game, but I've never programmed a particle system and don't know where to start. I only want to display pixels (GL_POINTs) with different sizes in ...
6
votes
3answers
559 views

How can I have my game engine track player history?

I'm in the very early stages of designing a browser-based text RPG. The project is basically just something I'm doing for fun and as a learning experience. I'm starting to wrap my head around the ...