Multithreading allows multiple threads to exist within the context of a single process sharing same resources but are able to execute independently.

learn more… | top users | synonyms

2
votes
1answer
630 views

What threading strategy does a game like Transport Tycoon use?

Transport Tycoon is a simulation game where you control a transport company, place railroad tracks and trains, airports, bus depots, boats etc. Now the game is about 15 years old and I remember ...
1
vote
1answer
7k views

Java 2D Tile Map and Moving Sprites with threads

I'm having difficulties understanding how to use threads and I'm not sure if my basic structure is right. This is my Board Class: package mortifera; import java.awt.Color; import java.awt.Graphics; ...
3
votes
3answers
560 views

State Changes in a Component Based Architecture [closed]

I'm currently working on a game and using the naive component based architecture thingie (Entities are a bag of components, entity.Update() calls Update on each updateable component), while the ...
2
votes
1answer
175 views

Audio Thread as daemon thread

I'm looking to set up two threads in my puzzle game, one for logic/graphics, and one for audio. Am I correct in thinking that the thread that handles the audio should be set as a daemon thread, ...
18
votes
2answers
6k views

How many threads should an Android game use?

At minimum, an OpenGL Android game has a UI thread and a Renderer thread created by GLSurfaceView. Renderer.onDrawFrame() should be doing a minimum of work to get the higest FPS. The physics, AI, ...
8
votes
3answers
994 views

Android threads trouble wrapping my head around design

I am having trouble wrapping my head around game design. On the android platform, I have an activity and set its content view with a custom surface view. The custom surface view acts as my panel and I ...
8
votes
3answers
708 views

How should I structure my classes to allow for multithreaded simulation?

In my game, there are plots of land with buildings (houses, resource centers). Buildings like houses have tenants, rooms, add-ons, et cetera, and there are several values that have to be simulated ...
20
votes
3answers
1k views

Multi-platform multi-threading: What are the real challenges?

While a library like SDL provides a cross-platform wrapper API for threading, I think it would be naive to assume that this leads directly to easy development of games across vastly different ...
1
vote
2answers
713 views

Cocos 2D putting things on the cocos thread or not?

We are using Cocos 2D for Android and are unsure if it's a good thing to execute our non-ui tasks on the Cocos thread as a way to get the animations in our game to pause. What is the recommended ...
1
vote
1answer
708 views

Tetris style game in java (for now) will I need to use threads?

I'm looking at developing a puzzle game, it might be like tetris or something similar, perhaps more like bejewelled in that the player will select objects with the mouse to manipulate them. I've ...
6
votes
3answers
552 views

When does parallel-tasks engine becomes a good solution?

I'm often tempted to break the game I'm working on to try a parallel-tasks based architecture, but that don't seem a big requirement for my project so I avoid this for the moment. I'm planning to just ...
12
votes
4answers
1k views

RTS Game AI Thread

I have a project to make a real-time strategy game from scratch. I am still at the early planning stage, but I have been programming a little to see the mechanics. I know how to program. I also have ...
2
votes
1answer
135 views

What causes my client's painting & input thread to stop?

I recently returned to face a problem I had with a game client of mine, i.e. the client's thread responsible for input & painting becomes unable to run after some while. I suspect that it has ...
11
votes
5answers
1k views

Sprites as Actors

I'm not experienced in Game Development questions, but as a programmer. In the language Scala, you can have scalable multi-tasking with Actors, very stable, as I hear. You can even have hundreds of ...
4
votes
4answers
1k views

One True Event Loop

Simple programs that collect data from only one system need only one (blocking) event loop. For example, Windows applications have the message loop, POSIX network programs usually have a ...
48
votes
6answers
10k views

Multi-threaded games best practices. One thread for 'logic', one for rendering, or more?

I'm aware there is immense slowing whenever data synchronization is required (let alone any mutex locks). I was thinking getting it to the extreme and doing threads for any subsystem conceivable. But ...
6
votes
2answers
459 views

How do you handle scripting in multithreaded environment

In my experience, two approaches are preferred when people want to handle scripting in multithreaded environment. Synchronize every accesses to scripting module with one coarse-grained lock. No ...
-1
votes
1answer
359 views

xna download website source code

I have to download the html code of a web site during the game. I am taking the poster url of a movie from the imdb web site by scrapping the html ( also other informations ). I have to do the ...
18
votes
6answers
1k views

Data structures for interpolation and threading?

I've been dealing with some frame-rate jittering issues with my game lately, and it seems that the best solution would be the one suggested by Glenn Fiedler (Gaffer on Games) in the classic Fix Your ...
3
votes
3answers
443 views

Get rid of the usual MUD cycles

I am working on a MUD engine and I want to do it a little differently then all the MUD games I played. I find a "cycle" system very boring. One of the idea I had is to make every clients socket ...
11
votes
1answer
1k views

Scene Graph in Separate Thread

I develop my own game engine for fun (but not profit). I have rendering in one thread and my scene graph updates (velocity, etc.) in another. When it's time to render, the render thread adds the ...
3
votes
1answer
406 views

What is the right process to get compatibility or at least a workaround for the ‘Threaded optimization’ feature of NVIDIA?

It's peculiar this issue is not well understood on NVIDIA forums and project forums. For example, the well known ioquake3 project based on id tech 3 requires to force 'Threaded optimization' off on ...
3
votes
2answers
314 views

Profiling code with threads and script interpreter

Basically, how I profile a game that have multithreading and script interpreter? (Lua in my case) I have no idea of where to look for that. Also it would be nice to be able to profile code that ...
8
votes
2answers
1k views

XNA: How does threading work?

I would like to implement threading in my XNA game but I'm not sure how things work when compiling for the XBOX 360. Could someone elaborate on this? For example, how many threads does XBOX support? ...
4
votes
3answers
838 views

Is it necessary to wait for rendering thread to terminate in surfaceDestroyed(…)

I just wrote a simple Android app that uses SurfaceHolder.Callback interface to communicate the state of the SurfaceView. In the Callback.surfaceDestroyed() method i just informed the rendering thread ...