Engine-design related questions. How code is structured.

learn more… | top users | synonyms (2)

3
votes
1answer
818 views

Movement & Physics in an entity-component system

I'm currently playing around with entity-components systems and got started on the movement/collision/physics parts and would like to have some pointers! It's a basic 2D sidescrolling game, with the ...
2
votes
1answer
353 views

Combining 2D and 3D in game engine

I've implemented basic 3D functionality and made little "2.5D" demo in orthographic projection using OpenGL ES 2 and Box2D. Now I want to make completely two-dimensional game (using sprites) and ...
1
vote
1answer
116 views

Picking game entities

What is the preferred methods for doing so, performance-wise? For example I want to pick certain objects in an area around a given point. What I have thought off so far is using invisible objects as ...
5
votes
1answer
681 views

What underlying character stats would you put into your “character” object in an RPG engine

basically I'm making my own RPG/TBS engine named Uruk (making an rpg themed about the epic of gilgamesh) and I am thinking of a combat system similar to the Disgaea franchise or the Super Robot Wars ...
0
votes
1answer
76 views

Object generation from an existing object in a game engine

To simplify, let's say in en engine I'm coding for a game, I have the Main class an Object class. In the Main class' update method, I loop through the array of all Objects in the game. I also have a ...
3
votes
2answers
3k views

OpenGL - Understanding the relationship between Model, View and World Matrix

I am having a bit of trouble understanding how these matrixes work and how to set them up in relation to one another to get a proper system running. In my understanding the Model Matrix is the matrix ...
0
votes
0answers
504 views

Component based architecture - Rendering approach?

I'm planning to use a component based architecture for a new 3D game engine I plan to work on, however I don't know how to approach the rendering side of things. I can see two options here: Every ...
1
vote
0answers
44 views

Export matrices or IPOs?

I'm currently working on an exporter for Blender and corresponding importer for my engine, but I believe the same concepts apply to any other 3D animation software. When it comes to export animation ...
1
vote
1answer
186 views

When to use GameComponents?

I know what it is and I'm using it as a frame counter for example. But when should I use it? Does it make sense to say "I make all the input handling happen in a gamecomponent"? Is it flexible enough ...
2
votes
1answer
268 views

Where to put common System functionality in Entity-System Design?

I am working on an Entity System design based largely off of Adam Martin's design and Ray Wenderlich's Objective-C Implementation. I am working on the AI system using a state machine with a System ...
1
vote
2answers
642 views

How to make a “GUI In Game”?

My game is very GUI based, the way how it works is that I have a GUI class, which contains the basic GUI elements, a parent GUI object, and a copy of the main game's class object. The game starts out ...
1
vote
0answers
112 views

Events with Entity Component Systems [duplicate]

I'm currently working on an HTML5 top-down simple RPG game, and as a learning experience I'm building my own little engine from scratch. After reading around a little I decided to go with the Entity ...
3
votes
2answers
297 views

Using a programmable pipeline in a game engine

As a learning experience, I'm developing my own 3D game engine using OpenGL. I'm a little confused as to how to implement my rendering engine such that it uses a programmable pipeline while still ...
16
votes
6answers
3k views

Do you actually use diagrams to model games? [closed]

I mean mostly UML but any method that works is viable. So - do you actually model your games with UML/other diagrams or different methods? I had a subject at my university about modelling with UML and ...
2
votes
1answer
308 views

Different kinds of movement in component based entity system

I am writing a pong clone with a component based entity system. But I am having trouble with the different kinds of movement in the game. The problem is the following: My paddles will just move up ...
4
votes
2answers
337 views

Separate classes communication

Lets say I have a key and door. My third class (player) needs to pick up a key and open the doors. How should those objects communicate without making too much dependencies between them?
2
votes
1answer
974 views

Tilemap collision in component based entity system

I am trying to set up a collision system for a tilemap in my component based entity system, but having trouble with figuring out how to do so. Currently I have the following approach: My tilemap ...
2
votes
2answers
247 views

Correct utilisation of gameloop (Android)

When using a gameloop like (much simplified)............ updateLogic(); render(); How does one perform 'single' operations? I mean, things like triggering sounds (which will only be played once), ...
8
votes
5answers
592 views

How can I update Display settings from an Options screen without restarting?

I'm currently creating a 2D RPG in C++11 with Allegro 5 and boost. My goal is to somehow update my game settings when an option is changed in the Options Menu. I don't want to force the user to ...
2
votes
0answers
50 views

User interaction and Component based architecture [duplicate]

I'm working at my first game and I've decided to build a simple component based engine. I found really useful to work in that way but I still miss some fundamentals probably. Let say that I have a ...
0
votes
2answers
121 views

making different kind of bullets [closed]

I have an enemy which shoots 3 different kind of bullets. They are of different sizes, speed, and representation (rectangle, oval, and a more classic bullet). Should they be 3 separate classes or ...
4
votes
1answer
147 views

Game State and Configuration via Events

Often "singletons" are problematic for testing, so with my next game I'm trying my best to avoid them. But there is bunch of data (configuration or game state information) that different parts of my ...
4
votes
2answers
966 views

Manage VBO/VAO in a graphic engine

I'm trying to make a 2D Graphic engine for training me. I've actually made it with immediate draw and I've made the renderer outside (so I can switch between OpenGL and DirectX). How can I manage ...
2
votes
1answer
126 views

How do I generate paylines and pay dots for a slot game?

I'm working on a HTML5 slot game and am completely stuck on the pay lines and the dots that produce the lines from 1 end to the other. What's the logic behind generating a random number of dots ...
18
votes
4answers
2k views

Game architecture / design question - building an efficient engine while avoiding global instances (C++ game)

I had a question about game architecture: What is the best way to have different components communicate with each other? I do really apologize if this question has already been asked a million times, ...
1
vote
1answer
61 views

Resynchronize game state on reconnect

Suppose in a multiplayer first person shooter game that a player loses their connection. On reconnect they need to synchronize with the current game state. But while they are getting a snapshot of the ...
5
votes
2answers
1k views

Component based game engine and dependencies - singletons [closed]

I am thinking about how to create component based game engine. I understand that all things should be very similar as in Data Oriented Design (each object is a collection of various structures as ...
3
votes
1answer
263 views

Making up everything from single pixels

I recently saw a game which looked a bit like minecraft, but it was a RPG. The enemies in this game consist completely of voxels and if they die, they collaps and every single voxels falls down, ...
1
vote
1answer
160 views

General Sequence of Events for a 2D shooter

I'm having some trouble understanding ways to sequence events in my game. Assume the game is data driven, what is the best way to control the events? Do I have some sort of EventSequencer that loads ...
1
vote
1answer
948 views

CPU usage, game loop and sleep()

I've read about this topic on numerous discussion sites, but I can't seem to find a clear definitive (up-to-date) answer, and hopefully this will me some more insight: I've read the excellent game ...
1
vote
1answer
760 views

UML Class Diagrams for 2D platformer Games? [closed]

I have to develop a small arcade game in C++ for a college assignment using a 2D Game Engine my teacher coded. What would be the best way to make a UML class diagram for it? It's very basic stuff but ...
2
votes
3answers
515 views

Event-driven vs state synchronizing networking model

I was going through the Tribes network model and the network model used in Quake3. What I understand is that Tribes is more of an event based model where as the Quake model uses game states and delta ...
1
vote
0answers
226 views

Game editor architecture [closed]

I'm looking in to developing a game editor - essentially a level editor for my game but a little more advanced i.e edit menus and loading screens and what not. So far, I have come up with a ...
5
votes
1answer
414 views

How do you parameterize turn based AI?

I would like to create/find an AI algorithm/process that can be parameterized such that a change in the parameters causes a change in the AI behavior. I am specifically looking to apply this to a turn ...
1
vote
2answers
811 views

Packet handling system architecture?

I'm working on a multiplayer Flash game (ActionScript 3) with an accompanying server written in Python and I'd like some tips regarding networking, and specifically, the handling of packets and ...
2
votes
1answer
1k views

Making efficeint voxel engines using “chunks”

Concept I'm currently looking in to how voxel engines work with a view to possibly making one myself. I see a lot of stuff like this ... ...
2
votes
1answer
491 views

Creating Input layouts for different vertex types

I'm still in the planning phase for a hobby abstract renderer, and i'm wondering how i should handle multiple vertex types and different shader inputs. (This is my first graphics project, so cut me ...
0
votes
1answer
195 views

xna creating game stage management contrls

I am under planning stage of my game where I am creating controls for my game. I have create below control for stages but have no idea how this we can achieve in xna. Please also help me with your ...
1
vote
1answer
167 views

Application design for specific points on image

Hi guys I am starting a simple hobby app in Unity, its a 2D app, which have some alphabets like A,B,C..Z (images) . There ll be specific paths where user touch one by one to complete drawing the ...
-8
votes
1answer
186 views

What kinds of 3D objects should a game engine have? [closed]

I know this is a pretty general question. But I've been looking for different kinds of 3D objects and their names to implement in my engine to boost its speed. Static meshes, dynamic(?) meshes and ...
3
votes
1answer
241 views

Where should I put my mob rendering code?

I'm making a simple LWJGL game. However, I'm a bit confused about rendering. So I have a Mob class and a TriangleMob is a basic enemy. package daniel.entity.Mob; public class TriangleMob { ...
2
votes
1answer
315 views

Not repeating background in platformer [closed]

I need to make not repeating background for platformer. I can't find any description of implementation and I developed algorithm but I'm not sure that it's right. I can't load one big texture per ...
5
votes
1answer
485 views

Character Movement in 3D games

I'm either not searching correctly or there is really not a lot of material on Character Movement in 3D games. I'm mostly interested in how people usually implement character movement in games like ...
10
votes
3answers
1k views

EXTREMELY Confused Over “Constant Game Speed Maximum FPS” Game Loop

I recently read this article on Game Loops: http://www.koonsolo.com/news/dewitters-gameloop/ And the recommended last implementation is confusing me deeply. I don't understand how it works, and it ...
0
votes
1answer
238 views

Xna “Game.Run” method appears to be using up a lot of resources in my game, is this normal?

The question really is in the heading, but i have been using the visual studio profiler to optmisie my game, i have noticed that the game.run method is eating through 93.6% of the overall game ...
0
votes
2answers
311 views

Attribute ownership in Entity Component systems

How do you typically handle data ownership in these systems? Right now I just have a map that maps type(std::string or hashed int)->void* where outside sources can add attributes via a simple ...
0
votes
0answers
71 views

What's the most efficient way to manage auras & buffs? [duplicate]

I would like to know, for a game that does NOT use a grid (1-dimensional movement, in fact); what is the cleanest way to manage buffs that change a unit's variables? My current system is going to be ...
3
votes
2answers
647 views

Does it make sense to use Lua scripting in a game developed in Python?

Well for C++ written games using Lua scripts for easy changing ai, quets etc is very reasonable and it's common. However now I'm going to write a game in pure python and I don't know if I should use ...
1
vote
2answers
474 views

Powerup Best practices [duplicate]

In a turn based game each player has a set of properties, e.g attack, defence, speed and these can all be used to work out who should go first and how much damage should be dealt. That all works fine, ...
1
vote
1answer
331 views

How can you implement Lua into your game? [closed]

I am trying to implement Lua into my game, but am having trouble. Say I have a weapon class, which is just a hollow shell, lacking real functions. I was thinking of creating an onFire function, which ...