Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

The tag has no usage guidance.

1
vote
1answer
69 views

Network limitation in multiplayer game

I have a multiplayer cooperative game (PVE) in where there can be up to 200 enemies at a time (somewhere around that) and I was wondering how devs generally synchronize these? I already have packets ...
0
votes
1answer
84 views

Java - Entity Collision only working for last index of the Entity Array

I am in the early stages of creating a Java 2d platformer / sidescroller game where the Entity class requires (at this point) basic Rectangle bounds collision detection. In my code I check to see if ...
2
votes
1answer
111 views

How would a server handle sending entity updates to clients?

Lately I've been looking into networking and sockets and made small test programs to get the basics down. So far I've made a TCP turn-based game from where I learnt a lot and helped me getting some ...
0
votes
2answers
539 views

Should entities auto-register to systems based on their component signature?

I see all the upside in entities registering automatically for basic components. If an entity has a Renderable component, it should be registered to a list that's used by a Renderable System. If an ...
1
vote
0answers
158 views

Nested Entities in Entity Component Systems (ECS) [duplicate]

Say I have an entity that has these components: -Transformation -Visual Imagine that these components can nest: If I have a parent transformation component, a child transformation relies on the ...
0
votes
2answers
186 views

The most correct/efficient way to update millions of entities that change over time in an mmo?

We have a server and a database in the cloud. We have a game where each player can grow a farm on a massive x,y grid. Each hour is a grow cycle. All players can harvest anyone's plants. Player A ...
0
votes
1answer
186 views

Creating Multiple Render System to Draw Different Entities in Entity-Component-System

When creating ECS based game engine, do you (or can I) create multiple rendering systems? Let's say I have an Entity class which is the basic unit in my engine, all it can do is add, remove and get ...
1
vote
2answers
154 views

How to convert and handle (controlling) OOP game objects via ECS?

I'm having hard time converting OOP game objects to Ashley ECS framework. I have a character, gun & a bullet class. The character uses the gun as weapon, the gun class has a fire method that ...
4
votes
1answer
590 views

Handling data logic on libgdx ai state machine or in ashley system?

In this below example, I've combined libgdx ashley and AI state machine. Do you think it's a good idea to handle the logic in state machine or stick on handling the data logic on System? ...
1
vote
0answers
227 views

What is the proper way of creating bullet in libgdx ashley ecs framework?

I'm still thinking, how do I properly pool a bullet in libgdx ashley? Because the PooledEngine is available, which the Entities, ...
2
votes
2answers
744 views

Entity System and “composite” entities

I'm new to the Entity Component System pattern and there's something I cannot figure out. Let's say I have the following entity: ...
2
votes
0answers
216 views

When NOT to use ECS architecture? [closed]

I'm familiar with the notion of entity-component-system architecture, and its advantages over traditional class trees. That being said, are there scenarios where one wouldn't want to use entity-...
2
votes
1answer
2k views

Updating a multithreaded Entity-Component-System

I am currently trying to implement an (sort-of) Entity-Component-System. I've got the gist of it, that is, how an ECS is supposed to work. So far i have 4 classes in my design (not yet fully ...
3
votes
1answer
151 views

How to propagate component updates? (Changing components at runtime)

Whenever an entity is being added to an entity controller (which is essentially just a bag of entities), I scan through it's components to figure out if I need to register additional entity processors ...
1
vote
0answers
129 views

XNA Collision In An Entity Part System

I've hit a loss in creating a "game engine" in XNA, I'm extremely confused over how to approach collision in an Entity-Part System ( following this as a reference ). I can make all the entities with a ...
0
votes
2answers
149 views

entity component - get object from entity system without knowing it's ID

Ive been building a game using a Entity Component system, but im having a bit of an issue finding a specific object in my entity system without knowing the Entity's Id. My game is organized in ...
0
votes
1answer
93 views

How to read a custom map format [closed]

I am trying to create a custom map format for my own little 2D RPG, so my question is rather how do I manage reading and creating a custom map format properly and flexible. First off, I am writing my ...
6
votes
1answer
3k views

Intersystem communication in a ECS game

Apologies if this question has been answered before, but after relentless searching I couldn't find anything. As many, I've recently jumped on the ECS-bandwagon, and I am currently killing some time ...
3
votes
1answer
187 views

How can I derive hierarchical draw ordering for entities in an entity system?

How do you implement hierarchical render order in an entity system? For example: two player entities each carry a gun entity. If you set the player entities to zindex = 0 and the gun entities to ...
2
votes
2answers
377 views

Data model design using Core Data and Spritekit

I have a entity called Item, and every item can have two or three bonuses... What would be a good model design in this situation. I can think of something like: To have many optional attributes ...
0
votes
1answer
226 views

How do I efficiently deal with entities moving between chunks?

I am working on a game in which entities need to be stored in chunks. This is the basic chunk format: public static Entity [row][column][entities] chunkEntities; ...
0
votes
1answer
196 views

Handle Entities & Collision in large numbers [closed]

I am creating a simple 2D maze game and I am a little confused about entities & collision detection. At the moment, my entity class is an abstract class containing position, velocity, sprite and ...
0
votes
2answers
1k views

Undefined reference error when trying to access a component using ECS [closed]

I'm trying to access the x and y values from PositionComponent in my MovementComponent but I get this error and I just can't ...
2
votes
1answer
886 views

Where should I put the SDL_Renderer* using the ECS with SDL2 and C++?

So I'm still learning about ECS (Entity Component System) and whenever I'm thinking about the architecture and actual implementation, I just can't figure out where should I put the SDL_Renderer*. So ...
15
votes
4answers
3k views

Cache misses and usability in Entity Systems

Lately I have been researching and implementing an Entity System for my framework. I think I read most articles, reddits and questions about it that I could find, and so far I think I am grasping the ...
1
vote
1answer
173 views

How can I resolve component types in a way that supports adding new types relatively easily?

I am trying to build an Entity Component System for an interactive application developed using C++ and OpenGL. My question is quite simple. In my GameObject class I have a collection of Components. I ...
2
votes
4answers
1k views

Executing Components in an Entity Component System

Ok so I am just starting to grasp the whole ECS paradigm right now and I need clarification on a few things. For the record, I am trying to develop a game using C++ and OpenGL and I'm relatively new ...
0
votes
1answer
258 views

How to send components in an ECS System?

I'm trying to send a CreateEntity packet from a server to client, but I can't figure out how to send the information about components over the network. I gave each component an ID, but then I realized ...
3
votes
2answers
270 views

Should entities store other other entities that they spawned?

How should a game entity add another game entity to the game world? For example, an entity shooting a missile (which is another entity), means the new Missile will ...
1
vote
1answer
662 views

Where to put my entity component messaging functionality?

I've done my research and read as many articles and posts on messaging and ECS's as I could find to help me get mine working. However, I'm at a roadblock on how to get my messag functionality to be ...
0
votes
1answer
177 views

Entity System handle graphics/textures [duplicate]

I use in Java Artemis(entity system library) and Slick2D(graphics library) for a game. Now I wonder me, how I should handle graphics(sprites, textures...). In the demos of the page from Artemis it was ...
2
votes
1answer
330 views

Making more complicated systems(entity-component-system model question)

I'm using a model where entities are collections of components and components are just data. All the logic goes into systems which operate on components. Making basic systems(for Rendering and ...
0
votes
2answers
1k views

Slick2D - Entities and rendering

I have been trying to create my very first game for quite a while, followed some tutorials and stuff, but I am stuck at creating my entity system. I have made a class that extends the Entity class and ...
2
votes
2answers
1k views

Why do my update and draw loops throw a concurrent access exception?

I've taken up the challenge of creating a basic 2D side-scrolling monster truck game for my little brother. It seems easy enough in theory, but jumping into Java out of XNA feels strange. My game ...
3
votes
3answers
2k views

Effective way to check if an Entity/Player enters a region/trigger

I was wondering how multiplayer games detect if you enter a special region. Let's assume there is a huge map that is so big that simply checking it would become a huge performance issue. I've seen ...
8
votes
3answers
3k views

How to progress an entity-component gamestate in a turn-based game?

So far the entity component systems I've used have worked mostly like Java's artemis: All data in components Stateless independent systems (at least to the degree that they don't require input on ...
2
votes
1answer
744 views

Collision Resolution: How to avoid Interpenetration/Tunneling Caused by Prior Collision Handling? [duplicate]

My game processes world collisions followed by entity collisions. The problem here is that entities can break through walls the next frame when world checks are run again as a result of the prior ...
12
votes
2answers
709 views

How to handle entity path-finding and movement in a large networked world?

Considering the image above with tiles split into 32x32 boxes, I have an entity which is marked to 'aggro' nearby players that come close to it. I'd like this monster to ideally chase the player (and ...