Computer programming is the process of designing, writing, testing, debugging, and maintaining the source code of computer programs.

learn more… | top users | synonyms

0
votes
0answers
28 views

mini-games for teaching web programming [on hold]

I will teach a web programming & database design class next semester. I want to make programming a fun experience for students. I have several ideas but not sure how good they areand may need ...
-1
votes
0answers
69 views

If developers had a talent tree, what skills would it have? [closed]

We have seen talent trees in almost every game we played. So if we could make a talent tree of our development skills, how should we classify it, by languages, engines, tools? What should every tree ...
1
vote
1answer
41 views

Stat Multipliers: from Base Value or Iterative

I'm aware similar questions have been asked before but this time I'm asking about a specific issue with the maths of stat modifiers. I have a stat system that applies a list of modifiers to a stat, ...
0
votes
1answer
48 views

Gravity: Slow down on ground approach

I'm looking for some math, nothing language dependant. "Standard" gravity for a character in a 2D game would go something like this: if player.y > ground.y { player.velocity.y = ...
2
votes
1answer
100 views

How can I access a script variable from another script in Unity?

I'm creating a space shooter (think Space Invaders or Galaga) where the GameManager persists between scenes but the player and enemies don't. I need to access a boolean value from the player and ...
0
votes
1answer
69 views

Possible to create 3-D or accelerated graphics on Windows using your own library/API?

Say I want to come up with a way to replace what OpenGL and DirectX specifications do: communicate with GPU to get some functions done that help hardware-acceleration and rapid drawing of screen data. ...
1
vote
2answers
41 views

How to make gravity in Blitz3D?

I am making a game in Blitz3d and I made simple gravity, however once the object falls on the ground, it goes through it very slowly. The ground is a plane and I have collision on it. This is a ...
2
votes
0answers
75 views

Problems with instaling SFML [closed]

I've followed the instructions on installing SFML on the website to the letter. But, I get this when I try to build the sample program on the same page using Code::Blocks. ...
1
vote
0answers
55 views

A problem with collision when a sprite changes size (Phaser framework)

I have a sprite in my game that changes size at certain points in the game. It changes size via the sprite.body.setSize method. Unfortunately, it seems that the sprite is unaffected by objects that it ...
0
votes
1answer
35 views

XNA tiling a sprite with a camera.viewmatrix in the Draw method

I'm looking for help fixing a small problem that I have with my XNA game project. I currently have: spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.AlphaBlend, null, null, null, ...
0
votes
0answers
22 views

360-degree rotation/movement inside a tube [duplicate]

I'm trying to implement in UE4 the same gameplay mechanic Ballistics had: https://www.youtube.com/watch?v=UaJiPpLzbNg Working with splines doesn't quite cut it, because they have to be done ...
0
votes
0answers
35 views

Displaying range around a unit [duplicate]

I'm looking to highlight a set of square tiles around a unit to signify its movable range. The concept should be quite familiar to those who have experienced the Fire Emblem series of game. I have ...
0
votes
1answer
69 views

Are there any advantages to different programming paradigms specifically releated to game programming? [closed]

I have been researching three different programming paradigms namely procedural, object oriented and functional. So far I have been able to find a lot of good information regarding general differences ...
1
vote
2answers
150 views

How to do collision detection on marching cubes terrain?

I'm writing the physics part of my game engine. The world uses the marching cubes algorithm on a 3d perlin noise to make the terrain. How do I do collision detection on the resulting mesh? I can't ...
0
votes
2answers
157 views

Recommended approach for event system in Java

What are the recommended approaches for an event system of a turn-based RPG's battle engine? The system I'm currently working on has a runEvent method that sorts the actions queue based on their ...
0
votes
1answer
96 views

Enemy spawning problem [closed]

I've been trying to get my characters to spawn at random points through out the map. I have a camera which is following my main character (2D RPG Style) around the screen, but I want these "enemies" ...
1
vote
1answer
148 views

Vehicle: Boat accelerating and turning in Unity

I'm trying to make a player-controllable boat in Unity and I'm running into problems with my code. 1) I want to make the boat to accelerate and decelerate steadily instead of simply moving the speed ...
5
votes
1answer
144 views

Is there a good alternative to a world state data structure?

How do you avoid one big data structure containing all the current world state ? Let's pretend we're in a real-time strategy game, how would you code a skill that decrease mana of units around it ? ...
-5
votes
1answer
89 views

Do total conversion mods require absolutely no programming or scripting skills? [closed]

I tried to look up total conversion and other mods as examples (Counter-Strike, Defense of the Ancients, Gunman Chronicles, Dear Esther, Natural Selection) but it is a bit difficult to find out if ...
1
vote
1answer
114 views

GLSL Processed Image to OpenGL

I've tried wording and rewording this question in various forms of search and can't seem to find an answer to it. If I'm wording it wrong and/or just not finding the right information, feel free to ...
1
vote
1answer
67 views

How was/is playback of music handled on consoles such as the NES, Master System, Gameboy, etc? [closed]

So, I deliberately left out the SNES because AFAIK the music subsystem is basically entirely self-contained. However, on systems like the NES and Gameboy, while there are sound chips, there isn't any ...
0
votes
3answers
106 views

Proper way for Player object to communicate with Map object?

I'm writing my first game (in javascript / node over websockets) and am running into a bit of chicken and egg problem, and am afraid how I'm doing it right now won't scale once the game gets more ...
0
votes
4answers
444 views

What is the point in using API such as Open GL or DirectX when there are game engines? [duplicate]

I was wondering why today programmers place so much emphasis on API like DirectX, and even OpenGl. As far as I know, you'd need thousands of lines of code to make a simple 3D game using one of the ...
0
votes
2answers
195 views

How to write “Hello World” for N64 purely from scratch?

As an experiment I want to code a "Hello World" program for N64 using only assembly code, using no headers, tools, helper files, etc. I just want to write the assembly code bare bones from absolute ...
0
votes
1answer
195 views

The sprite will not move in libGDX

When I ran the android application, The sprite image will not move when I press the input keys. I followed a tutorial based on input keys and wish to know what's wrong. Can anyone see what's wrong? ...
2
votes
2answers
102 views

Decoupling the entity from whatever controls it

In a lot of games the player can choose whether an entity will be controlled by the AI or by the player. For example in the game Little Fighter 2, the player can choose how many of a maximum of 8 ...
-1
votes
1answer
443 views

Game code difference between consoles (PS3/PS4) and PC [closed]

I'm interested in game development and have some very curious questions. Im a newbie in game dev so pardon my silly mistakes and question and repetition if any. I hope biggies here will guide me and ...
0
votes
1answer
51 views

How can I avoid type checking in the physics side of collision handling?

I have a class responsible for handling the physics side of collisions. When the collision detector spots a collision, it notifies both entities in the collision to take care of gameplay. It also ...
0
votes
2answers
146 views

How to set HUD elements position and size depending of resolution [duplicate]

How can I set HUD elements' position and size when changing resolution and maintain the desired layout? All HUD elements (including menu items such as play button, setting button etc) need to get some ...
5
votes
5answers
1k views

Technical differences between square and hexagon for a grid?

I'm developing a 2D city-building game and trying to decide on the type of grid. There will be vehicles, so the unit movement is important too. I know there are visual differences for using Squares ...
0
votes
1answer
90 views

How to make player rotate towards mouse [duplicate]

I'm making a top down shooter with Three.js and Box2d. I'm displaying all of the graphics in 3d, but all of the physics are done in 2d, so it's sort of like super smash bros in a way. Anyway, how can ...
1
vote
1answer
91 views

How do I draw text once a countdown ends?

I created a countdown in Game Maker using a variable of time. The countdown works properly and is displayed at the proper coordinates. However, when the countdown reaches zero, I want to make the ...
-1
votes
2answers
186 views

Changing a Sprite When Hit in GameMaker

I am making a simple little Galaga style game. I want the objects sprite to change whenever it is hit. For example if a laser hits an alien then the sprite takes 1 out of 4 damage to its health ...
0
votes
0answers
146 views

How do I combine multiple squares into one Tetris block?

I am learning Phaser by making a simple game—Tetris. I'm having difficulties: Can I use simple rectangles as tetrominoes or they should be sprites? I don't know how make the figure's block ...
1
vote
0answers
111 views

How to write a global GameState manager for a game in Java [closed]

My implementation is written in Java: public class GameState { public static String state = ""; public static void setState(String state) { GameState.state = state; } ...
3
votes
2answers
3k views

Update vs. FixedUpdate in Unity

I was told to use Update() for graphics and FixedUpdate() for physics, but sometimes my inputs won't register when I use FixedUpdate(). It works fine if I use Update() for everything though. Should I ...
10
votes
2answers
726 views

What are the benefits of using an entity ID system?

I'm currently reading the book Programming Game AI By Example. The book mentions assigning unique ID numbers to each entity in the game. Often when entity A needs to contact entity B, A gets a ...
-1
votes
1answer
101 views

Match-3 Shuffle Required?

How can I detect if there are no more potential matches possible and therefore a shuffle is required?
8
votes
4answers
880 views

Infinite 3D Cave in Unity

A friend and I are hoping to make a game in Unity in which you fly through an infinite 3D cave that can twist and wind in any direction (though obviously not to the point that the turns are impossible ...
15
votes
1answer
2k views

How can I mock Google Play purchases?

I would like to know what best practices should I do for testing the functionality when a user buy an item/power-ups via Google Play and purchased with real money? For example, basically, creating a ...
2
votes
2answers
811 views

How does the Unity3D entity system work?

I saw the Java Artemis Entity Component System and thought of the entity system in Unity3D. In Artemis for example you can only add one component type to each entity and the logic is not in the ...
0
votes
1answer
48 views

How to find the right direction to plug a sword into a rig's hand after projecting it?

I've downloaded BVH animations and projected it following a book. I can now see a 3D moving rig and it looks alright. The problem is, now I want to plug a sword on the hand of the rig, but I don't ...
1
vote
1answer
2k views

Basic hierarchical component access in Unity: GetComponent vs. Find

I'm just learning to develop in Unity. One simple thing I'd like to do is change the colors of objects programmatically. I have a compound asteroid prefab object, in which the meshrenderer and ...
0
votes
1answer
84 views

Get Facebook Picture in Cocos2d-iphone V3

I'm trying to get the profile picture from Facebook, but I'm getting the following error: Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[UIImage ...
0
votes
1answer
193 views

try to create CCSpriteFrame but get nil values

I'm trying to animate a CCSprite in cocos2d v3 following this question, but I'm getting the following error message in Log: Terminating app due to uncaught exception 'NSInvalidArgumentException', ...
1
vote
1answer
65 views

Clay Jam continuous path/tap

I saw this game Clay Jam, that the user can create a path in the sand. The path is a continuous one, and it can varies from a single point to curves. How one can develop smooth and continuous paths? ...
-1
votes
1answer
131 views

Size of modern games [closed]

As a non-game developer, I'm always stunned by the sheer size of modern games. For example, last night I downloaded Killzone for my PS4 and it clocked in at over 30GBs, which to me is absolutely ...
5
votes
1answer
225 views

Best way to organize models with multiple meshes and textures?

I have character models which have different parts, ex: upper body, head, lower body; each part is a separate mesh in the same model. Each part has several textures associated with it (diffuse, ...
2
votes
2answers
243 views

Expandable 2d environment by spawning and controlling individual tiles

what is the best way to implement an environment that is "expandable" in every direction so that when the player moves in any direction a new row or column of tiles that can be manipulated ...
3
votes
4answers
1k views

How to make a game without OOP? [closed]

I am currenty studying game development and practicing making games. I use a lot of OOP in my games. For example, each missile that is shot is an instance of a Missile object, and added to a list of ...