0
votes
1answer
71 views

Why does my SDL code crash when I move the mouse over the window?

Whenever I move my mouse below where the image renders in my game, the SDL window crashes and closes down. I have narrowed the crash down to the bit of code where I check to see if the Escape key ...
2
votes
1answer
114 views

How to convert a SDL window to a SDL surface? SDL 2

I am trying to make a paint program and there is a sdl function called IMG_SavePNG() which requires a surface and destination file. How can I turn what I see in the window to a surface?
9
votes
3answers
381 views

Flexible alternatives to many many small polymorphic classes (for use as properties or messages or events) C++

There are two classes in my game that are really useful, but slowly becoming a pain. Message and Property (property is essentially a component). They both derive from a base class and contain a ...
0
votes
1answer
138 views

Enumerating full game tree for small board game

I am trying to list all the possible positions in a small board game (nannon) (using C++) So far I have decided to split it into two parts, the pieces that are in home positions and end positions ...
14
votes
2answers
924 views

Best way to gain C++ working experience for a job in games (coming from C#) [closed]

I am a software developer, experienced with C# (5 years experience) alongside a few other languages. My "dream job" is working in video games as a developer. Most jobs require knowledge of C++, ...
-2
votes
4answers
300 views

Making 2D Games [closed]

I am starting out on making my own games. I am very interested in making 2D side scrolling games, such as SNES/Mega Drive games and eventually I want to create my own Metroid/Cave Story inspired game. ...
8
votes
5answers
503 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 ...
1
vote
2answers
517 views

My SDL Game executable cannot run outside codeblocks

After compiling and running SDL programs successfully inside CodeBlocks, when I run them outside CodeBlocks (by clicking .exe file) my program does not run. Instead, it says that libstdc++6.dll is ...
-3
votes
2answers
251 views

Need help with game development. (I know C++ and I need to learn an API) [closed]

I know C++ but I don't know an API looking at Directx. I can't find any good tutorials and really need some help to start 2D game development. I'm doing an game development focused Art course that ...
-2
votes
2answers
926 views

making a game in 2D(C++). SDL or openGL? Or, why not both? [closed]

I'm trying to make a platform game in 2D and I want to know what tool should I use to make it happen. I understand that I can use SDL with openGL. However, if I want to make a solid 2D platform game, ...
20
votes
5answers
2k views

Try-catch or ifs for error handling in C++

Are exceptions used widely in game engine design or it is more preferable using pure if statements? For example with exceptions: try { m_fpsTextId = m_statistics->createText( "FPS: 0", 16, 20, ...
2
votes
1answer
172 views

Should I wrap a template function with another template function, or…?

I'm currently making an Entity System, using C++, and I've questioned myself about how I should interface some methods. Specifically in my Entity and ComponentManager classes. The ComponentManager, ...
-2
votes
2answers
91 views

How to Contact prominent game devs for discussion and queries? [closed]

What is the medium to contact and discuss problems with Game devs, and engine hackers? Any irc, forum, mailing list? Note : Somehow, I did not like gamedev.net
7
votes
3answers
842 views

Game Asset Storage: Archive vs Individual files

As I am in the process of creating a 3D c++ game and I was wondering what would be more beneficial when dealing with game assets with regards to storage. I have seen some games have a single asset ...
1
vote
0answers
81 views

Audio Panning using RtAudio

I use Rtaudio library. I would like to implement an audio program where I can control the panning (e.g. shifting the sound from the left channel to the right channel). In my specific case, I use a ...
-1
votes
3answers
5k views

How to begin serious game development (in C++) [closed]

I would like to start developing games. I have tried before Game Maker 8, which was a very easy way to start creating games, if you were new in game development. Then, I tried Unity 3D, which was a ...
-1
votes
2answers
481 views

Making a game engine or using Unity3D? [closed]

I was wondering, which one would benefit me the most? I have as much time as I need to make a game engine and rapid development does not appeal to me. Unity3D is easy, but how much will mastering ...
-2
votes
4answers
2k views

Lua or C# beneficial over C++ for small, single person project? [closed]

I plan to do a fairly small game development project as a single programmer. I have read that alternatives to C++ such as C# or integrating Lua scripts is more time and effort efficient in ...
0
votes
1answer
697 views

Rotating around a non origin point

I've been looking around the forums for some answers to the question I have. I've found some answer that seem to help but nothing that answers my specific question. That question being how to rotate ...
3
votes
1answer
495 views

Design patterns in Game Physics

In the frames of a number crunching compatible programming language (say.. C++), what would be an elegant solution for adding self collision, external collision and integration step (Euler, etc.) ...
2
votes
3answers
381 views

C++ Namespace vs Reference passed around like crazy - Implement a quest journal

May sound funny, but that's what the question is about. Suppose you have this situation: http://i48.tinypic.com/whl6pk.jpg Red squares are data types. Hexagons are methods and Journal is the main ...
6
votes
2answers
3k views

C++ entity component system framework [closed]

I have found several entity system frameworks for other languages besides C++, like Ash and Rush for ActionScript and Artemis for Java and C#. My question is whether there exists a framework like one ...
2
votes
1answer
1k views

C++/SDL Getting Multiple Bullets On-Screen

I've finally gotten this laser thing to work for my Space Shooter, and so far I've come across a slight problem. I've gotten the laser to position itself at the starting position correctly and move ...
17
votes
3answers
2k views

How does one do unit testing in a game engine?

Much to my shame, I have never written a proper unit test, only small unorganized test programs that I would then dispose of after the test succeeded. I don't really have a clear idea of how unit ...
17
votes
7answers
1k views

How important do you find exception safety to be in your C++ code?

Every time I consider making my code strongly exception safe, I justify not doing it because it would be so time consuming. Consider this relatively simple snippet: Level::Entity* entity = new ...
2
votes
4answers
465 views

What is a right datatype in C++ for OpenGL scene representation with use of GLSL

I am programming in C++ OpenGl with GLSL. Until now I have been using a data structure that is composed of std::vector filled with structures of vertexes and with their parameters (position , normal, ...
5
votes
2answers
652 views

How can I make the switch from immediate mode to VBOs?

I've been using OpenGL for a short time now- and I'd like some clarification on VBOs. As I understand it, a VBO is an object stored on VRAM. In immediate mode, to apply a texture we simply bind it and ...
1
vote
2answers
344 views

Are C and Objective-C sufficient for creating games on the iOS?

These days, I'm focusing on games development on the iOS. C++ is the lingua franca for games development but seriously, I prefer to code in C programming language, not in C++. So for iOS games ...
1
vote
1answer
778 views

Networking SFML Berkley Sockets

So I'm starting work on a multi-player space shooter. And I've run into some issues. As I type this, my system is currently: //Main While Loop Gather Input Update Own Sprites Based on Input Send ...
3
votes
3answers
499 views

Should our group try to make a game? [closed]

I am a second year, learning C/C++ and Java. In our first year of university we did basic C++, no classes. This year we have been introduced to classes and inheritance. We have not yet done pointers, ...
7
votes
5answers
570 views

Graphics module: Am I going the right way?

I'm trying to write the graphics module of my engine. That is, this part of the code only provides an interface through which to load images, fonts, etc and draw them on the screen. It is also a ...
2
votes
2answers
846 views

Collision Resolution

Hey all, I'm making a simple side-scrolling game, and I would appreciate some input! My collision detection system is a simple bounding box detection, so it's really easy to implement. However my ...
0
votes
4answers
537 views

What's next to learn? [closed]

I am self-learning programming for video games. I have learned: Basics (variables, loops, branching, etc.) Object Oriented (classes, objects) Functions Dynamic Memory Allocation Operator Overloading ...
13
votes
3answers
3k views

Logging library for (c++) games

I know a lot of logging libraries but didn't test a lot of them. (GoogleLog, Pantheios, the coming boost::log library...) In games, especially in remote multiplayer and multithreaded games, logging ...
12
votes
5answers
7k views

Complete Math Library for use in OpenGL ES 2.0 Game? [closed]

Are you aware of a complete (or almost complete) cross platform math library for use in OpenGL ES 2.0 games? The library should contain: Matrix2x2, Matrix 3x3, Matrix4x4 classes Quaternions ...
3
votes
2answers
310 views

What happens to allocated video memory when the program terminates?

Using OpenGL it is possible to load textures, buffer arrays, compiled shaders and more to the video memory. When a C++ program exits, heap memory that was allocated by it is cleaned. What happens to ...
1
vote
2answers
356 views

Cyclic Dependencies

Are cyclic dependencies a common thing in games dev? I ask as I keep getting into situation where I'm using and have been told more than once that they should be avoided. I am wondering if this is ...
15
votes
3answers
4k views

Finite state machine in C++

So, I've read a lot about using FSMs to do game state management, things like what an FSM is, and using a stack or set of states for building one. I've gone through all that. But I'm stuck at writing ...
16
votes
7answers
3k views

What scripting language would you recommend for a C++ game project?

By scripting here I mean not just putting config data in a script, but scripting parts of the project like some class methods, test specific game loop, etc. This would be not just to accelerate ...
74
votes
9answers
26k views

What are some programming design patterns that are useful in game development? [closed]

I have a few books on Design Patterns, and have read some articles, but cannot intuitively figure out which programming design patterns would be useful in game development. For example, I have a book ...
9
votes
6answers
2k views

Throwing Exceptions in C++ game DLL's? Pros and Cons

What are the pros and cons of using Exceptions in C++ in relation to game development. Google style guide says that they don't use Exceptions for a variety of reasons. Are the same reasons ...
37
votes
9answers
9k views

C++: Smart pointers, Raw pointers, No Pointers?

Within the scope of developing games in C++, what are your preferred patterns in regard to use of pointers (be it none, raw, scoped, shared, or otherwise in between smart and dumb)? You might ...
5
votes
2answers
711 views

Atmospheric Scattering

I want to add some nice atmospheric scattering to my 3D game engine but I am very concerned with conserving resources. I am not very familiar with how its done but can someone please give me some ...
7
votes
1answer
2k views

OpenAL - alGetSourcei and AL_BUFFERS_PROCESSED gives junk

Posted this question on SO but got no answers. Maybe somebody can help me here. I recently had a well-working program which streamed WAV and Ogg sounds with OpenAL. I then decided to abstract the ...