8

Let's look at your particular suggestion for a formula and what range of values it is able to handle: attack_speed = 1.8 - (1.8 * (x / 100)) What if x is larger than 100? Now you have a negative attack speed. What is that even supposed to mean mechanics-wise? Adding a 1 when calculating a divisor ensures that the division will always reduce the value ...


6

First of all, you don't have breaks in your switch statement, that means that if your random number is for example 1, after subtracting the speed value from the position, the program will keep running inside the switch statement executing the case 2 and 3, so the case 3 will be always executed, making the object move to the bottom and the case 1 will be more ...


5

As game designer, that is up to you. The End. Alright, alright... Ask yourself how do you want the game to be played. Ask yourself how should the player react with the results of combat. Then, for each aspect of your combat mechanic consider how it supports those play styles and whatever or not it justifies reactions you do not want. It can be helpful to ...


4

To answer your question succinctly, RYB (red, yellow, blue) would be most intuitive and closest to mixing physical colors, aka pigments, which blend subtractively. To understand the mixing behavior of RYB color-space, see both the color wheel diagram in the question, as well as the color tree below. For your use case it seems to me it would be simplest to ...


3

How do we fix this? I'm not sure there is anything to fix, but if you really want an answer: You make good difficulty levels. Not all players want to have a dynamic difficulty level, and not all games would allow such a feature (not to mention that it could be much harder to get right). You have to identify the challenge the player wants to face. For ...


3

A dynamic difficulty system has the purpose to adjust to challenge of the game to the skill level of the player. But you can use the difficulty setting chosen by the player as a guide for the level of relative challenge the dynamic difficulty should aim for. On "Hard", make it adjust in a way that the player is always slightly overburdened to keep them in a ...


3

The wind that pushes the player back into the navigation volume is a very good solution. Bespoke games like Sky and Journey by Thatgamecompany are examples where it is used nicely. Alternatively to that, you could have the player being caught by some flying something (like an eagle) to be taken back on track or you could have a lightning suddenly strike and ...


3

You could look into finding a control scheme which allows the player to control the whole party as one single entity. One game which went this route was Legend of Zelda: Four Swords Adventure. The player controls a party of four characters which move and fight in a close formation. When the player moves the thumbstick, the whole formation moves. When the ...


3

As a native English speaker, Trait sounds much more accurate in this case. Affix is much less used and so harder to understand. Calling them traits makes it clear that they are properties of the item. Other options could be Property, or Modifier, but Trait still sounds best in my opinion. "Affix" sounds like something you learn in school and never worry ...


2

An alternative method which I've used with some success is to apply a percentage of remaining armor as absolute mitigation. Example: Mitigation factor: 10% HP: 1000 Armor: 800 Effective Mitigation: 800 * 10% = 80 Ship is hit for 80 damage, armor is reduced by 80 HP: 1000 Armor: 720 Effective Mitigation: 720 * 10% = 72 Ship is hit for 80 damage, armor is ...


2

I never played that game myself. It looks like it has a state machine. If the horizontal offset between player and boss is high enough, it moves in a horizontal + sinus movement. If it is near the player, it moves up to evade the player, abandoning the sinus. After it avoided the player, it keeps doing a slightly larger sinus above the player, and sometimes ...


2

As pointed out in other answers, the colour wheel most of us are familiar with doesn't match the way that pure light mixes - which is what's easiest to model with our usual representations of colours in a computer program. With pure light wavelengths, yellow and blue are complimentary in our vision system, and blending them yields black (if subtractively ...


2

Difficulty curve How a game difficulty changes over time is commonly called a "difficulty curve", which you can probably find some more resources about online. The basic idea is the game should get more difficult over time as the player gets more comfortable with the mechanics to constantly keep the game challenging. This doesn't have to be dynamic ...


2

The +1 is in there because Attack_speed is actually a cooldown stat, where half as much Attack_speed makes you attack twice as fast. If you have a "+100% increase" to your attack speed with the WoW formula, you get outputs like Attack_speed = 1.8 / ( (100 / 100) + 1 ) = 0.9. Similarly, if you have a "-99% decrease" to your attack speed with the WoW formula, ...


2

Common wisdom when it comes to MMO economics is to just let players decide at what prices they are willing to trade resources and equipment between each other. Create a trade platform where sellers can offer items or resources for any price and where buyers can then accept those offers if they find them fair (often called "auction house"). Some games also ...


1

There is never a best solution. Only the solution which is best for your game and your personal workflow. However, I would suggest a third solution. One scene only Store every map as a prefab (The Grid object with the tilemaps and all the objects on the map) When the player switches maps, destroy the old map and instantiate the new one. Why only one scene?...


1

Put your objects into a std::vector (or even std::array) and then use std::sort with a custom comparator. After that, if necessary, you can assign the indices in the list to the corresponding objects. std::sort(objects.begin(), objects.end(), [](const auto& a, const auto& b) { return a.score > b.score; }); Now objects contains the items ...


1

This code appears to be JavaScript. Since ECMA-262, JavaScript has a native BigInt class. It works with all the basic math operators +, -, *, /, % and ** (division will round to 0). It also works with the comparison operators like ==, >, <= etc. It can be expressed as a literal by using the suffix n. (const ONE_NONILLION = ...


1

Avoid having big dips or spikes in difficulty, and make it so easy challenges can be beaten faster by being more reckless. If you have big dips and spikes in difficulty, like a bunch of easy fights followed by a difficult boss, then any player will either be bored by the easy fights or find the boss frustratingly difficult. But if the fights before the boss ...


1

Basically what you are asking for are rougelike / rougelite game elements. While rougelike games tend to have a permadeath with none to only a bit next game benefits, rougelite games tend to give more options for the next play session, based an your last one. Rougelike games often also lets you keep some of your progress, like the dungeon you already ...


1

The red-yellow-blue color circle invented by Le Blon in the 1720s is incorrect. You can't create perfect green by mixing equal parts blue and yellow. Creating a perfect magenta with red and blue is even harder - you usually end up with a muddy purple. And if you mix all three, you don't get grey, you get brown. People already noticed that in the 18th ...


1

I solved this problem in many different ways in the past. Unfortunately there is no silver bullet here. Every architecture has advantages and drawbacks. So I am going to describe several approaches here so you can choose which one is most appropriate for the game you want to create. First of all, such mechanics usually requires that a modifiable character ...


1

I was not involved in the development of WoW, but reading the first formula, I'd say that they added 1 to prevent the case (that may happen a lot with very low level / unnequipped characters) of division by zero. If the "Percent increase or decrease" value is 0, you'll end up with "current attack speed" being divided by zero. In the "+1" version the only ...


1

You don't really need any specific algorithm to accomplish this. One way you can achieve that is this: Make an array that holds your tiles, most likely a 2D array will do. For each tile, make a json file, that describes what that tile looks like. Name the json files in a sequence, so the first tile would be tile_0.json the next one tile_1.json etc etc. When ...


1

RPG elements in a home-brew game engine aren't difficult, but are hilariously complex to code. Look at the number of bugs in Skyrim, which still exist years after release. Each npc entity has it's own dialogue when the player interacts with it, and that dialogue will very likely change when quests are completed, abandoned or failed. It may even change ...


1

There is best, however, I would argue for separating the concerns of deciding what text to show and getting the text itself. You can hard code the decisions, it is a finite state machine. And, I would argue for reading the text from a file (which you can replace when the time comes for translations). Or not. The text can be hard-coded too... read from a ...


1

You are calling Movement every Update frame, so you are starting a new coroutine for startMoving several times a second. You won't see the effects of this at first because each one is waiting 5.05 seconds, but after that I expect the object starts shaking because randoming will be called many times per second as all those coroutines finish. In other words, ...


1

A lot of game with modifiable terrain actually use a grid structure to store blocks internally (called "voxels" in game dev terminology, which is short for "volumetric pixels") but they are using processing algorithms like Marching Cubes to smooth them and make them look less blocky. A more advanced algorithm is Dual Contouring. Developers have come up with ...


1

You could take the Super Mario 64 aproach where if the player hasn’t collected enough stars he can ascend a stairway forever without making progress. In your case the player could fly down for as long as he wants and still remain at the same height so when he finally decides to fly up it is a short way to the island’s height.


Only top voted, non community-wiki answers of a minimum length are eligible