instruction
stringlengths
33
29.4k
I am looking for a good method to determine which objects will be considered for collision with other objects. My current idea is that each object has the following properties: alwaysCollidesWith = [list of objects that will always trigger a collision check] neverCollidesWith = [lost of objects that will never be consi...
Suppose I've a picture, which want to achieve day/light mode by changing 8bpp color palette. If I want the pixel index of my picture is always fixed for both day mode and night mode. For example, the 1st pixel index is 100. Which I can look up index 100 in day mode palette and night mode palette. How can I use GIMP to...
I'm slightly confused about how Direct3D rendering works. Basically, as long as I render to one surface, everything is fine. But when I try rendering to multiple surfaces, it seems like everything is still rendered to one surface. I think there's something wrong with my calls. For each update cycle this is what I do 1....
Which is more efficient using OpenGL's transformation stack or applying the transformations by hand. I've often heard that you should minimize the number of state transitions in your graphics pipeline. Pushing and popping translation matrices seem like a big change. However, I wonder if the graphics card might be abl...
I posted this on StackOverlow, but of course it should be posted here. I am maintaining a multiplatform codebase for Xbox360 and WinXP. I am seeing an issue on the XP side that appears to be related to D3DRS_VIEWPORTENABLE on the Xbox360 version not having an equivalent on WinXP D3D9. This article had an interesting id...
As I understand it, potentially visible sets (PVS) are used to determine 2 things; 1. which objects are inside the camera's view volume 2. which objects are not occluded (hidden) from the camera's point of view. I understand that things like octtrees & BSP trees have been used for PVS calculation in the past, but how ...
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 download process many times during the game for different movies. I can download and scrap the html but downloading the html ta...
I want to packing image files(png, jpg) into swf, then game can load files easily. But I want to do this by a Makefile, not FLASH CS. Do you know any command line swf tool set can do that? And can I packing XML files into it as well?
I have just been reviewing Frenet Frame math. It is an interesting geometrical issue. I know that common applications are: camera movement along a curve tube and ribbons surface Can someone suggest other interesting applications?
I am trying to make a simple pong game using opengl-es. I have checked out some of the tutorials/samples, but most of them are pre-dated to 2009. I am familiar with game programming, and consider pong to be the hello-world! Right now, I intend to make it using their supplied SDK (2.3), but eventually I want to make it ...
Let me get this out there before anything else: this is a learning exercise for me. I am not a game developer by trade or hobby (at least, not seriously) and am purely delving into some AI- and 3D-related topics to broaden my horizons a bit. As part of the learning experience, I thought I'd have a go at developing a ba...
A while ago, I picked up a copy of the OpenGL SuperBible fifth edition and slowly and painfully started teaching myself OpenGL the 3.3 way, after having been used to the 1.0 way from school way back when. Making things more challenging, I am primarily a .NET developer, so I was working in Mono with the OpenTK OpenGL wr...
I want to try creating a custom Starcraft 2 map with a third-person camera following a unit. A few custom maps with this feature exist already, so I know it's possible. How do I do this? Do I need a custom mods file, or can everything be done in the map file?
Possible Duplicate: How closely can a game resemble another game without legal problems I want make a game similar to Pocket Tanks but for Android and then sell it. Since I am not directly copying anything from Pocket Tanks, but simply using it to give me ideas, I should be allowed to make it. I don't want to finish...
Well during this week I have deciding about implementation of my entity system. It is a big topic so it has been difficult to take one option from the whole. This has been my decision: 1) I don't have an entity class it is just an id. 2) I have systems that contain a list of components (the list is homegenous, I mean, ...
I am working on a Windows game and while rendering, some computers will experience intermittent pauses ("hitches" for lack of a better term). When profiled they appear in seemingly random places in the code. Eventually I noticed that it wasn't just my process that was affected, but (seemingly) every process on the syst...
I'm having problems making a simple sprite rendering. I load 2 different textures. Then, I bind these textures and draw 2 squares, one with each texture. But only the texture of the first rendered object is drawn in both squares. Its like if I'd only use a texture or as if glBindTexture don't work properly. I know that...
I'm having problems drawing a simple sprite. When I draw: void CSprite2D::render() { CHECKGL(glLoadIdentity()); CHECKGL(glEnable(GL_TEXTURE_2D)); CHECKGL(glEnable(GL_BLEND)); CHECKGL(glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA)); m_texture->bind(); //CHECKGL(g...
Minecraft server comes as a single jar. How are mods developed? How do they interact with the original jar? What is there under the hood? What technologies are involved there? I'm mostly a C++/Python guy, but I'd like to learn something about mods development.
I am an indie developer and I need some detailed artwork. How much is reasonable to pay an artist for say 20 character designs? I know it depends on the artist's skills, etc, but I am wondering what to expect so that I can budget it. Edit: Let's say cartoon-ish art (Example - not necessarily in that level of detail but...
I'm having a go at creating a very simple text based game and I'm wondering how I can design the entities (characters, sentient scenery) with regards to the actions those entities can perform. As an example, I have an entity that is a 'person' with various properties such as age, gender, height, etc. This 'person' can ...
A friend of mine has had his Flash game stolen and published on the iPhone app store without his consent. What is the best way to get Apple's attention about this?
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 create instances of all classes and do all the drawing and calculation in there. Question: Should I instead create the ...
Sorry if the question is not worded well, I'm a new to both 3D and OpenGL. How could I go about obtaining the 3D coordinates of the occluding object, at the point where occlusion is happening (i.e. the 'intersection' of the object in front/closest to the screen)? Just to offer a [very] rudimentary, visual, example, if...
LittleBigPlanet2 just came out. I've worked with the original LBP level editor a bit and really enjoyed it. I've read that LBP2's featureset in the game is much richer; is it possible to use these advanced features to create different sorts of game other than just a regular platformer? I imagine that something along th...
I have a very old adult (e.g. boobs and stuff) arcade game (think Delphi 7/DirectX 8 age), that currently is backported to Droid. Can the game be published to Android Market? Are there any age restrictions?
I'm trying to learn a little about OpenGL, so I'm making a simple 2D game (with OpenTK), and so far it's coming along well. I thought it would be fun to give it that, for lack of a better word, retropixelated look of games from the early nineties. I figured it would be an easy thing to do -- simply draw everything at h...
Possible Duplicate: How do I build a 2D physics engine? If we take the game Angry Birds that had big success lately I were thinking how do they implement the physics in a game like that? Your are shooting of your birds and they hit something that will fall off and in turn creating a chain reaction of things either f...
I have heard that textures consumes lot of memory but I am surprised how much.... I have 7 textures 1024 16 bit each. And while I will run my app it consumes 57MB of memory. I think that this is "a bit" too much. I am writing 2D application (no cocos or other framework) Strange is that while I will compile my app with ...
I assume that when texturing environments, one or several textures will be used, and the UVs of the environment geometry will likely overlap on these textures, so that e.g. a tiling brick texture can be used by many parts of the environment, rather than UV unwrapping the entire thing, and having several areas of the te...
What Are some Game Development publications (electronic or otherwise) that aren't so large that there is no chance to potentially get included in the publication after a few well-written articles sent their way. Looking for publications geared towards developers, not gamers, and can be any aspect of the game process, d...
I'm an experienced programmer that recently got into iOS development by working through the big nerd ranch book by Aaron Hillegass and Joe Conway. I loved the way the book was structured in terms of typing in the code and doing the challenges. I'm interested in learning more about iOS gaming and cocos2d, but am a compl...
I am currently working on a project with a few friends, and I am trying to get frustum culling working. Every single tutorial or article I go to shows that my math is correct and that this should be working. I thought maybe posting here, somebody would catch something I could not. Thank you. Here are the important c...
My main goal is avoid using an external program like SpriteSheetPacker. I would like to just use sequenced PNGs and have the sprite sheets be made, updated, and saved automatically when I build my game. Edit: The old answers I upvoted, but I updated the question and specifically asked how to do this automatically with ...
I’m currently planning to develop an RPG. It will be a project I do in my free time. No pres-sure behind it. I’ll probably be doing it together with a friend and it’s just supposed to be a fun project, something we just work on, if we like to. Although it is a private fun project, I will make arrangements for this proj...
I've noticed sprite sheets are used more and more in Flash games and I don't fully understand what are the advantages over an image sequence/flash timeline - MovieClip. I've read this related question: 2D graphics - why use spritesheets? and that makes sense for hardware accelerated games, but that's not the case for ...
I have developed a game for iOS that has had a decent amount of downloads, but I think I would get significantly more revenue if I were to convert the game to free to play, with in app purchases (especially since some competitors products are now free to download with in app purchases). My question is what is the best ...
An example of offline skilling would be EvE Online. Your character (pilot) does not gain skills by getting experience. Instead, your character gains skillpoints towards a skill you are training whether you are in or out of game. Also, I am fairly certain that skills continue to build even when the game servers are down...
I have been writing GLSL shaders for over a year but this is the first time I have run into this problem. I am on the iOS platform - if that matters. In a vertex shader I have this: uniform mediump mat4 projectionViewModelMatrix; In a fragment shader I have been using for months I have the following uniforms: unifor...
I'm using Three.JS to render some objects. I'm struggling with some very simple object rendering and translation. The scenario is that I spawn an object at 0,0,0 in world space with 0,0,0 rotation. var scene, camera, cube; ... function change() { var degrees = 90 var zTranslation = 5; cube.rotation.y = degrees...
The <audio> tag and the <object> tag are (somewhat hard to use) ways to embed audio on a page... ...but what about creating sound effects in a browser-based game? E.g. if the game becomes aware you died, I plan to have some music play on the "you're dead" page. But what about some kind of fighting sound when people c...
I'm making a small game in Unity, and some models are displaying very ugly shading. The shading usually looks funky along the edges between triangles. I'm pretty new to working in 3D; I bet this is an artifact of vertex lighting, but I'm not sure, and I'm not sure how to fix it. Here you can see the worst example of ...
I'm working on a little text based console game for a bit of fun and am starting work on the user commands entered into the console. Are there some good design patterns for deciding what to do with the commands the user enters into the console window? My thoughts so far: I've createed a basic query structure for obtain...
I've come across games that are 3D that are playable in a browser. They require a plugin to be installed to work. I guess the plugin creates a D3D window inside the browser. How would I go about implementing something similar?
I have to make a tank that sits still but moves his turret and shoots missiles. As this is my first Android application ever and I haven't done any game development either, I've come across a few problems... Now, I did the tank and the moving turret once I read the Android tutorial for the LunarLander sample code. So t...
Possible Duplicate: What are some programming design patterns that are useful in game development? Is there any literature on game design patterns? I'm taking a software design class and would like to learn how some of these design patterns would apply to game development.
I dont know much about finite state machine in AI or other game behaviors in game, except this quick tutorial with a Miner: http://www.ai-junkie.com/architecture/state_driven/tut_state1.html which is object oriented. I don't really know if this tutorial describes the State pattern or not, what do you think ? I'm not sp...
I am porting an AGS game to iPhone, and was wondering what the best approach to the port would be? How best would you structure your code and assets? More specifically, how would you deal with say 100+ scenes. My initial approach is to create a scene superclass with things common between all scenes, like backgrounds, m...
I am making a first-person computer game in the style of Carmen Sandiego or The Cluefinders. My game company is just starting up, so we have no spare money. My animator and I decided that the best way to get movement throughout the game would be to create 640x480 videos that would serve as backdrops, and would hold eve...
I have a problem with my XNA Game, I have a function where I need my sprite to face towards an enemy, using this code: Vector2 currentPosition = Position; Vector2 nearestEnemy = gameObjectManager.GetNearestEnemy(Position, GameObjectTypes.Zombie); Orientation = (float)Math.Atan2(nearestEnemy.Y -...
To make a real-world example, lets assume I want to build an animated sprite for an explosion. The duration of the animation should last ~1 second, and we'll say exactly one second to make the math a bit more simple. And lets assume I'm using XNA and my goal is to target both XBox (60fps), PC (60fps), and Windows Phone...
Possible Duplicate: How do I find rotation in 3D based on a vector/normal? My models are axis-aligned. I know the normal of the surface I want to draw them on. How do I compute the rotations or rotation matrix that I should use to draw the model perpendicular to the surface?
I'm creating a game where the enemies spawn randomly on a map then move towards the player every frame at a random speed. The map has no obstacles so the enemies should always move in a straight line. I wrote the movement function a few times but no matter what the enemies always hit 0, 45, 90, 135, 180, 225, 270, 315 ...
Is there a good tutorial that shows the difference between OpenGL 1.* and 2.*? It would be very helpful to know which functions I should not be calling (like glBegin(), I assume).
I have been away from XNA for a couple months and want to get back into it. I had a game I was currently working on, but it was done in XNA 3.1. What are the differences between the two, and is it worth updating?
There are 4 moving physical nodes in 3D space. They are paired with two elastic line segments / strings (1 <-> 2; 3 <-> 4). Part I: How to detect the collision of two segments? Part II: On the moment of collision, fifth node is created at the intersection point and here you have the force-based graph. 5-th node (bend p...
I'd like to add an online leaderboard to my iPhone game. Upon discovering the time and effort required to create a Game Center account I started considering other options. What do you use for online leaderboards? Why? I'm open to a variety of options including App Engine, using EC2, Open Feint, PlusPlus etc. -- I'd...
I am having problems while rendering in Maya 2008. 1 frame is taking 1 hr. My 5 computers have config of : core i3 , 1 gb ATI radeon graphics card, 8 GB Ram. OS: win Xp pro 32 bit. I am giving render from command prompt. What should be my page file size ? How to diagnose if any problem ? suggest tips to improve rende...
I'm about to pick up computer graphics once again for an university project. For a previous project I used a library called FTGL that didn't leave me quite satisfied as it felt kind of heavy (I tried lots of rendering techniques, text rendering didn't scale very well). My question is, is there a good and efficient libr...
Does anyone the GL frame rate for iPad and iPhone 4 under the follow conditions: Unlit Non supersampled GLSL texture mapped with two textures. Single quad, 4 vertices Thanks, Doug
I'd like to create beams of electricity between two points very similar to this video: http://www.youtube.com/watch?v=eMJ8-56L3Lc. The effect is so dynamic, with varying lengths and pseudo-random movement in-between the points, that I'm having trouble imagining how I'd accomplish such a thing. Is there any helpful info...
I am wondering how to creat a mini-game like "Diner Dash" or like "Big Fish Games". I want my game to be 2d, but it looks like 3d: see this image. http://www.topxgames.com/bigfish/diner-dash-flo-through-time/screen1.jpg Also, if you know some good game-engine to create games like those then thanks a lot in advance.
I have a 2D tile-based strategy in the works. I'm wandering how to handle the relationship between the map and the units on the map. Given a tile coordinate I'll need to be able to get the unit standing on it, if any. At the same time, if given a unit I'll want to be able to get the unit's coordinate. I've seen two s...
I am working with an XNA content loader sample. In the references for the project (VS 2010 Express) there are: Microsoft.Build Microsoft.Build.Framework //as well as the standard XNA framework and graphics references To emulate this project, I am trying to first add a reference to Microsoft.Build.dll. But Visual Stud...
Are there any free/affordable systems/libraries out there for adding online features to a small PC game? (most likely, for a small primarily-Windows-based indie game) I'm not concerned about matchmaking or online multiplayer - but I'm interested in leaderboards, and maybe slightly more advanced features, such as the up...
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 Synchronization - Scripting module should be used by just one logic thread. Of course, both solutions are not scalable in mu...
We need to make a zombie videogame for a semester project and I was wondering about what are considered nice algorithms/techniques for implementing zombie AI that don't take too long to implement. The project is a videogame product, involving other stuff as physics and multiplayer, so we have limited time, so what I'm ...
My scene consists of individual meshes. At the moment each mesh has its associated light map texture, I was able to implement the light mapping using these many small textures. 1) Of course, I want to create an atlas, but how do you split atlases to pages, I mean do you group the lm's of objects that are close to each...
I've created some simple Phong shading code from a sample. The issue is that the sample only handles one light. If I wanted a variable number of lights set at the start of each frame, how could I specify in the effect file that I need to pass a variable number of e.g. light positions and etc to render from?
How do you pros out there implement footstep sounds in so that they're synced with character animation? I have an idea in mind: an FMOD event that has two footstep playback triggers, and a parameter that controls how fast each plays back in sequence, and the event is triggered as soon as the animation is on a frame (as...
Is there any good documented and simple Game engine for RTS games, especially for building DotA-like game? I know I can use Crystal Space, Irrlicht or another Game Engine. But I need most similar game or engine to DotA gameplay.
I am considering different game server architectures that use GAE. The types of games I am considering are turn-based where the world status would need to be updated about once per minute. I am looking for an answer that persuades me to either perform the world update on the google servers OR an authoritative server t...
I came up with a method for recursively generating simple dungeon maps by starting with one room and recursively connecting new adjacent rooms randomly to it. Maps are represented as two dimensional arrays where each cell contains a value of 0-15. 0 represents no room while each direction is represented by north=1, eas...
I would like to make a game that amalgamates Homeworld and Freespace with inspirations from the novel Ender's game. This is probably not a new idea, but I haven't seen anything that did anything like it. It would be team based and allows players to control units in an RTS (Homeworld) or first person fashion (Freespace...
I know php and some python, but not much c. Where should I start to learn iphone game development? Is there some recommended books/tutorials for beginners? I'm looking at using cocos2d but I'm open to anything that isn't too limited.
I've found a question for visual script editing software tool for creating game behavior logic, but I am looking for something more flexible. I would like to configure the tool to make it produce code that I need. I use Lua for creating quests in my mmorpg game, but every time there is need of creating a new quest I fe...
So I've been playing Mass Effect 2 (PC) and one of the things I've noticed is that you can only save your game when you're not engaged in combat. As soon as the first enemy shows up on your radar, the save button is disabled. Once combat is over, save functionality reappears. It seems reasonable to assume that Mass E...
Many game development companies are less formal in terms of workplace attire than other types of software development houses. For example, I know that one place at which I will be interviewing soon has a predominant workplace culture of jeans and polos or t-shirts. Should I wear a suit? Shirt and tie? Shirt and sport ...
I'm trying to get basic frustum culling against an AABB working, and I'm having a bit of trouble figuring out how to extract the frustum planes from my camera's transform matrix. All the example code I've found expects position, look, and up vectors, as you'd pass to gluLookAt. My camera matrix can be transformed by a ...
I'm investigating about virtual machines and their use in Games. I'm looking for something cross-platform (at least win/mac/linux, mobile and consoles are a nice to have but not mandatory) and it would be nice if it could be binded to the usual things that you need for a game, like a graphics and sound lib. If it had a...
The venerable shortest-path graph theoretic algorithm A* and subsequent improvements (e.g., Hierarchical Annotated A*) is clearly the technique of choice for pathfinding in game development. Instead, it just seems to me that RL is a more natural paradigm to move a character around a game space. And yet I'm not aware o...
I've been planning for a long time to mix data from OpenStreetMap, some digital elevation model (heightmap), satellite imagery for textures, and cook a racing/cruising game where I could drive around familiar parts of the city. OpenStreetMap contains very nice and detailed maps of all the locations I've checked, so I ...
I'm actually an industrial systems developer with knowledge of .NET C# and VB.NET, C/C++, Delphi, and an intermediate knowledge of 80286 Intel assembly language. I would be interested to learn how to develop games while taking as fully as possible advantage of my already acquired experience. My first objective is to le...
I am no graphics designer, but I'm a good developer with lots of experience. So, my question is the following: Are any 3D design skills required for game development? If not, how does one write a game with 3D characters without having to design them?
I'm developing a Real-Time game which should hold thousands of players in real-time (FPS like. max 1s lag). What would be the best infrastructure for this? My idea was using 2 server clusters - one for the Server End (all the computing side) and one for the Database end, where a load balancer is "responsible" for each ...
I'm currently writing a 2D AI simulation, but I'm not completely certain how to check whether the position of an agent is within the field of view of another. Currently, my world partitioning is simple cell-space partitioning (a grid). I want to use a triangle to represent the field of view, but how can I calculate the...
I've got a 2D game that I'm working on that is in a single aspect ratio. When I switch it to fullscreen mode on my widescreen monitor it stretches. I tried using two viewports to give a black background to where the game shouldn't stretch to, but that left the game in the same size as before. I couldn't get it to fill ...
I've already looked at some examples from StackOverflow, but I'd like to know if any of you could show concrete examples of job interview questions... Are they different with a job related to game development?
Edit: My goal is to have it function like this: Ball hits 1st Quarter = rebounds higher (aka Y++) Ball hits 2nd Quarter = rebounds higher (using random value) Ball hits 3rd Quarter = rebounds lower (using random value) Ball hits 4th Quarter = rebounds lower (aka Y--) I'm currently using Rectangle Collision for my colli...
If I have a downloadable game or in-game item that I need to sell for a fixed amount in all countries, how do I work out how to set the price? My local currency is UK pounds. Would I come up with a round number figure in £ and let customers in other countries deal with the currency fluctuations? Should I try to display...
I want to render some text over a mesh in my DirectX app. It will have a similar application to health bars for units in games, just as text rather than a bar. I'm looking for the simplest way to do this. It's a Win32 app, I'm using DirectX 9 and I need it to be in 3D (i.e. when the unit is moving around the Z-axis, th...
I am reading one great book, Game Coding Complete, and that book strongly recommends using MVC (Model-View-Controller) approach, with three key layers: Game Application Layer Game Logic Game View To me, this approach looks like an overkill for a mobile computer game. What is your opinion, please? Is it worth of impl...
What heuristics do programmers use in A* pathfinding for NavMeshes? NavMesh = Navigation Mesh, its a type of pathfinding that uses meshes instead of waypoints.
I am reading Game Coding Complete and the author recommends Event Driven communication among game objects and modules. Basically, all living game actors should communicate with the key modules (Physics, AI, Game Logic, Game View, etc.) via an internal event messaging system. This means having to design an efficient eve...
As being Scrum certified, I tend to prone for Agile methodologies while developping a system, and even use some canvas from the Scrum framework to manage my day-to-day work. Besides, I am wondering whether TDD is an option in game development, if it is viable? If I believe this GD question, TDD is not much of a use in ...
I have a polygon (sometimes convex, but often concave), and a bunch of circles with different radii. How can I find out if a circle is intersecting/overlapping with the polygon? I could split my concave polygon into convex pieces. Would that help?
The traditional game design, as I know it, uses polymorphism and virtual functions to update game objects states. In other words, the same set of virtual functions are called in regular(ex: per-frame) intervals on every object in the game. Recently, I discovered, that there is another - event driven messaging system a...
if I want to build a game for web, facebook, and iphone, do I need to build 3 completely different versions? I know there is a new company that is "build once, launch anywhere," but I'm asking about current best/practice and methodology in doing this.
What are the standard alternatives for the mechanics of attaching turrets and such to 3D models for use in-game? I don't mean the logic, but rather the graphics aspects. My naive approach is to extend the MD2-like format that I'm using (blender-exported using a script) to include a new set of properties for a mesh tha...
I'm currently looking into XNA game development with the C# language. I have two classes: the main game handler and a "sprite" class. Following is some basic pseudo-code which I hope adequately describes the issue. Game.cs class game { sprite the_sprite; void update(time) { var mouse = mouse.state if(mouse....