An entity for organizing data in a specific way so it can be used efficiently. Examples are arrays, objects, records, structs.

learn more… | top users | synonyms

7
votes
2answers
1k views

Comparing two tree structures

I'm having a hard time trying to describe this in correct terms so I will just give as much detail as possible and hopefully someone knows what I'm trying to do =-) I am trying to compare two node ...
-2
votes
1answer
215 views

Game code structure using openGL / Android [closed]

My game will have 3 activities (splashscreen, options menu and main game). As it stands, each is a separate activity with it's own activity class and GLSurfaceview class. Is this structure the right ...
4
votes
4answers
432 views

Storing data for a pokemon like game

The game I'm developing is close to Pokemon. How should I store the data? I am currently thinking of text files where I save the map and have a corresponding textfile for the trainers and their teams ...
9
votes
4answers
841 views

Is there a way to make a dynamic world such as a MMORPG horizontally scalable?

Imagine a open-world of 500+ players with data changing as fast as 20 updates/player/second. Last time I worked in a similar MMORPG, it used SQL, so obvioulsy it couldn't query the DB all the time. ...
3
votes
1answer
150 views

What data structure to use to implement ocean currents and trade-winds

I'm creating an RPG/simulation game which is similar to the Uncharted Waters Series. The game allows the player to control a fleet to explore and navigate the world on the world map. My Game stores ...
5
votes
1answer
830 views

RPG game engine. Skill application calculations

Short preface I am a part of a small team which is entering game development. We're creating a new RPG setting with custom game system and mechanics based on dice rolls. I'm server-side java ...
0
votes
1answer
176 views

Good way to store entity data

I'm building an RPG style game, but i have some trouble with storing data from entities. These entities can carry data including but not limited to their location, their graphics, whether they are ...
2
votes
1answer
709 views

Storing items in external data files

My project, in its current state, keeps all of the info for each inventory item in script files. That means, inventory items and their properties are part of the codebase. This works well, but I'm ...
3
votes
5answers
573 views

Saving data in games?

I'm soon going to make a game for the iPhone as a school project. My idea was to make a TLOZ remake, with Tiled Maps. However, I'm not quite sure how save the data. In TLOZ you have a lot of ...
4
votes
1answer
1k views

Need info on creating a tile grid data structure in Java

I'm trying to create a game with a fixed size map (2D Tile array). I suppose I can inherit other tiles from this base Tile, e.g.: a BankTile. Placing and removing tiles is all too easy, but forming ...
16
votes
5answers
1k views

Why is chunk size often a power of two?

There are many Minecraft clones out there and I am working on my own implementation. A principle of terrain rendering is tiling the whole world in fixed size chunks to reduce the effort of localized ...
3
votes
1answer
970 views

Best practice for organizing/storing character/monster data in an RPG?

Synopsis: Attempting to build a cross-platform RPG app in Adobe Flash Builder and am trying to figure out the best class hierarchy and the best way to store the static data used to build each of the ...
4
votes
2answers
406 views

Space-efficient data structures for broad-phase collision detection

As far as I know, these are three types of data structures that can be used for collision detection broadphase: Unsorted arrays: Check every object againist every object - O(n^2) time; O(log n) ...
1
vote
1answer
602 views

Data structures for a 2D multi-layered and multi-region map?

I am working on a 2D world editor and a world format subsequently. If I were to handle the game "world" being created just as a layered set of structures, either in top or side views, it would be ...
1
vote
1answer
500 views

How do I simplify a 2D game grid for level management while keeping its by-pixel features?

(I cross-posted this from StackOverflow as this seems to be a more appropriate f̶o̶r̶u̶m̶ community. I've looked around a little here and I did not find an answer, so I hope this is not a recurring ...
0
votes
2answers
545 views

map data structure in pacman

i am trying to make a pacman game in c# using GDI+, i have done some basic work and i have previously replicated games like copter-it and minesweeper. but i am confused about how do i implement the ...
0
votes
1answer
210 views

Using NumPy arrays as 2D mathematical vectors?

Right now I'm using lists as position, velocity, and acceleration vectors in my game. Is that a better option than using NumPy's arrays (not the standard library's) as vectors (with float data ...
1
vote
1answer
167 views

Direct3d - Code structure

I'm learning directx in a master's degree and they taught us to have a GraphicsLayer class which is the one connecting with the direct3d library. That way this class is completly independent from the ...
2
votes
1answer
199 views

Ray Tracing concers: Efficient Data Structure and Photon Mapping

I'm trying to build a simple ray tracer for specific target scenes. An example of such scene can be seen below. I'm concerned as to what accelerating data structure would be most efficient in this ...
2
votes
1answer
116 views

Torque2D, Class vs Datablock

I'm scripting my first game with Torque2D and have not fully understood the difference between "Class" and Datablock. To me it seems like Datablock is similar to a struct in C/C++ or a Record in ...
1
vote
1answer
78 views

Data model for unlockable card collection

My game has a collection of cards (about 64) that are unlocked (one by one) provided that 4 items are collected/gained in the game. Right now the deck of cards is modeled with a plist file, like ...
-4
votes
2answers
244 views

Read only array, deep copy or retrieve copies one by one? (Performance and Memory) [closed]

The question is asked regarding an environment with garbage collection.(Java, AS3) I am writing a level editor using MVC and the view needs to have read only access to the data in the model for ...
2
votes
2answers
613 views

Game Database Connectivity Java

I'm developing a simple multi-player puzzle game in Java. Both players should be able to view the same game board on his own computer. Then, when one player makes an action in the game (ex. drags an ...
2
votes
2answers
971 views

Data structure for bubble shooter game

I'm starting to make a bubble shooter game for a mobile OS. Assume this is just the basic "three or more same-color bubbles that touch pop" and all bubbles that are separated from their group ...
2
votes
1answer
125 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
449 views

Object detection in bitmap JavaScript canvas

I want to detect clicks on canvas elements which are drawn using paths. So far I have stored element paths in a JavaScript data structure and then check the coordinates of hits which match the ...
1
vote
2answers
355 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 ...
6
votes
2answers
1k views

Custom extensible file format for 2d tiled maps

I have implemented much of my game logic right now, but still create my maps with nasty for-loops on-the-fly to be able to work with something. Now I wanted to move on and to do some research on how ...
7
votes
1answer
393 views

Settlers-like terrain representation

Remember this beauty? I'm playing it now on my old Amiga 1200. My question is: How do you think they represented the terrain, data structure wise? Obviously it's some kind of points, with a height. ...
0
votes
1answer
293 views

What data structure should I use for a 3D platformer game?

I am developing a platformer game with XNA framework like Metroid but in 3D. Now I have to draw models and I have the question of the title. I read many post and I know that the main data structures ...
2
votes
1answer
424 views

Which data structure should I use for dynamically generated platforms?

I'm creating a platform type of game with various types of platforms. Platforms that move, shake, rotate, etc. Multiple types and multiple of each type can be on the screen at once. The platforms will ...
0
votes
1answer
186 views

Design patterns for effects between actors and technology

I'm working on my first game, and taking the opportunity to brush up my C++ (I want to make as much of it as portable as I can.) Whilst working on the technology tree and how it affects actors ...
3
votes
1answer
508 views

Tic-Tac-Toe game AI

I'm looking into creating a simple tic tac toe/noughts and crosses game in Actionscript3 and am trying to understand the ideas behind the AI used in a game like this. I've seen some simplistic ...
0
votes
2answers
301 views

Storing and sending English word list using trie data structure

I was planning on making a word based game something like Scramble or Boggle. I searched on the internet and found that one of the best way to store the Word List is by using a trie. My question: Is ...
0
votes
2answers
867 views

Game Logic - Tree Based Game Design

I'm trying to write an easy to use and extremely modifiable game engine in C++. I was thinking about using a tree to store game data. All objects would inherit a from the Node class and would have ...
1
vote
2answers
143 views

Implementing an existing (but out of print) game electronically

One of my favorite games is the old Avalon Hill class, PanzerBlitz. I would like to implement it electronically, and have a couple questions related to that: Would I be in legal trouble if I do ...
-4
votes
1answer
225 views

Database structure for level packs, levels and level information

I have a game which shall consist of several level packs (and also be extended by additional level packs). Each level pack should contain some levels. Each level will have its own level information. ...
1
vote
1answer
761 views

game data structures

I am working on a game that will be a 3D-shooter (camera trailing player), and want to impose some architecture on the game being that a level is composed of rooms where each room can hold ...
3
votes
1answer
294 views

Storing game objects with generic object information

In a simple game object class, you might have something like this: public abstract class GameObject { protected String name; // other properties protected double x, y; public ...
9
votes
3answers
493 views

How to add a sound that an enemy AI can hear?

Given: a 2D top down game Tiles are stored just in a 2D array Every tile has a property - dampen (so bricks might be -50db, air might be -1) From this I want to add it so a sound is generated at ...
1
vote
2answers
251 views

How to track and find entities within radius in realtime game?

What is best approach to implement tracking in real time for, say, 1000 npcs? Every frame update simple a square grid (remove or insert into linked list) and every time check in square radius? I tried ...
4
votes
1answer
423 views

How does Starcraft 2 load its metadata?

Lets say you are playing Starcraft 2 melee map. The game loads the map. Melee maps have the following dependencies: Liberty (Mod) Liberty Multi (Mod) I think the game engine will load the data ...
2
votes
2answers
136 views

A decent design for handling large creation/deletion of random objects?

So I was attempting a 'Hit the X' game (e.g Toss the turtle, spank the monkey) in which an uncontrollable object travels across the screen in hopes of hitting certain objects and avoiding others. My ...
9
votes
1answer
759 views

How to represent cliff faces in terrain?

I'm trying to figure out the best way to programmatically represent terrain in my game. I've been considering using a heightmap (or grid of evenly spaced vertices) to represent the surface of the ...
8
votes
6answers
818 views

How can I store all my level data in a single file instead of spread out over many files?

I am currently generating my level data, and saving to disk to ensure that any modifications done to the level are saved. I am storing "chunks" of 2048x2048 pixels into a file. Whenever the player ...
3
votes
2answers
2k views

Why can't I get a bool packed and aligned into a D3D constant buffer?

Alright, I'm having a hard time getting a bool packed and aligned into a hlsl constant buffer and I'm not sure why. Here is the buffer in hlsl cbuffer MaterialBuffer : register(b1) { float3 ...
1
vote
2answers
892 views

Isometric game data structure and rendering

I'm starting development of a 2d isometric(tiled, roguelike) game and i'm brainstorming wich kind of data structure i would use to store runtime data like tiles and entities, but i don't want to use ...
0
votes
4answers
504 views

Is there an in memory data store that is feasible for real time, non-networked games?

I would like to know if anyone has recommendations or experience with using an in memory data store for a real time, non-networked game. This is not necessarily for loading levels or saving data, but ...
11
votes
4answers
3k views

How to continuously find all entities within a radius efficiently?

I have a very large number of entities (units). On each step, each unit needs to know the positions of all units near it (distance is less then given constant R). All units move continuously. This is ...
5
votes
2answers
4k views

Quad Tree with a lot of Moving Objects

I have a Quad Tree implementation that is very useful for what I am trying to do. My problem is that when my viewport has a lot of objects, the Update for the Quad Tree takes a very long time. It ...