Tag Info

New answers tagged

1

I dont know what kind of simulation you are aiming for so it is difficult to give a specific answer. Inflation is usually defined when well, inflation is >0% and deflation is when inflation is negative. In many countries, the central bank aims to keep the inflation at a steady 2-3% per year through the use of monetary policy. Note however, inflation tends ...


1

You could use an ArrayList to store all your stars in. When collision is detected you remove star from array so the star is no longer updated. So : create : ArrayList <Star> stars= new ArrayList<Star>();4 add the stars : stars.add (new Star (param1, param2)); update : for (int i = 0; i < stars.size(); i++) { ...


0

There was a great quote from Eisenhower: "The plan is nothing; planning is everything." Obviously he wasn't talking about videogames, but his advice applies to any sort of project planning. What he meant was: The process of analyzing the situation and thinking through your plan of attack is crucial, but the specific plan you come up with is likely to change ...


1

You might want to consider an algorithmic solution that matches the situation. That is, consider why there are diminishing returns in your game situation, and model those. Multiple facilities of the same type might have diminishing returns is that there might be other resources or facilities which they depend on, or which result in bottlenecks, or other ...


4

In general, a linear equation will start with y = mx + b, where b is your starting value, and mx is how you adjust the starting value as x increases. So the first part of your equation, the b, will be 10 because you want farms to start at 10 food. y = mx + 10 Next, in your case, you want to adjust the food by produced by every ten farms. So you will ...


15

Diminishing returns = decreasing derivative Since you still want some returns even at higher levels means that the derivative should be positive, otherwise building more farms would decrease the food production (which might even make sense if you take into account logistics and upkeep costs) It should approach zero assymptotically, if it goes towards a ...


26

For formulating a diminishing returns equation, I'd immediately think fractions. This is a graph of y=1/F y will get smaller as F gets larger. This will give you a steady drop-off that never reaches 0. From this you can transform it to get the sort of curve that you want. Using numbers > 0 will always give positive output that is never 0. Honestly, I'd ...


0

Put simply, you only have the bare bones of a WinForms XNA based game. Your going to have to port your games code across from your XNA game project into your WinForms project. You'll have to create the MainLoop, and use it to call your MissileDisplay's Update and Invalidate Methods to simulate XNA's Update, and to call the GraphicsDeviceControl's Draw ...


4

Would a linear diminishing return do? production per farm = (1 - (0.05 * (f/10)) ) * production rate. This gives a total production (rate * # of farms) peak at f = 100.


-3

How do you become a game programmer? Just like you become any other kind of programmer. Either you apply to a position at a company or you start your own project. Formal qualifications and references are a plus. How is the work as a game programmer? This is a really broad question, but in general it is not much different than any other software ...


3

UI and HUD is better managed elsewhere. the GameManager is supposed to manage the game state and transitions between game states and nothing else. Possible states could be title, menu, loading or ingame. Note that there are not states for every level like levelXY. See the scene/level as the data for a state. You might come into a situation where need to ...


0

I think you might be able to achieve this in a 2D space by using multiple box colliders - or just just a range of x & y values, really. I spent a few hours in GIMP editing this up: Depicted is an open manhole that the turtles can fall in. Just a singular box collider would work for pits, but I used the screen wide colliders for illustration. For ...


1

You need to think with Portals :-) Make the playing field large enough that a player can't see from one end to the other (e.g. using fog). That way, a player can never see two instances of the same opponent. Of course weapon ranges need to be limited appropriately as well. Then, when a player nears the edge of the playing field, just draw a second copy of ...


3

3d terrain always comes with a cost: Objects get obscured behind cliffs, so the player needs to rotate the camera to maintain situational awareness. This takes time and disorients the player. They end up fighting the camera more than they fight the enemy. So before you add height levels just for the heck of it, consider how much it adds to your game in ...


0

An Elo-type system is designed to reflect a game where the #1 person is not expected to win every single match. A #1 ranked chess player might only beat the #10 ranked player 8 out of 10 times. The #1 ranked player is still better than the #10 ranked player but if you happen to observe only one of the 2 in 10 that the #10 ranked player won you wouldn't know ...


3

You have only two main options, both of which have serious pros and cons: Use normalized positioning, so that the X and Y coordinates are expressed effectively as a percentage of the available width and height. Use absolute positioning, so the X and Y coordinates are exactly the pixel or point coordinates of the sprite on the screen. Relative positioning ...


2

No. While the details of copyright law varies by jurisdiction (US versus Europe for example), the general thrust is basically the same: copyright gives the author of the work the control over who can use the work and how. It is only okay to use somebody's copywritten work if they have explicitly permitted you to do so. "Giving the author credit" or "not ...



Top 50 recent answers are included