📜 ⬆️ ⬇️

Creating game levels: tips and tricks (part 1)

On Habrahabr, there are a lot of indie developers, some of them have to be more or less involved in level design. Over the past few months, I have been working hard for about fifty different game levels, and I would like to share my experience. This article contains effective Tips and Tricks, which you can use to enhance the overall quality of your game. This is by no means a step-by-step guide, but only a collection of ideas and useful tips. The first part of the article is aimed more at work with the visual component of the game, while the second part, accessible by reference , contains more fundamental things, such as prototyping, determining the size of the hero and the environment, playting and analytics.



Level design and narrative


A little lyrics before moving on to a purely practical material. Creating levels is closely related to the narrative. In other words, almost everything you do tells a story. If a ray of light makes its way into a dark dungeon through the cracks in the stones, this hints at the presence of peace outside the cave. If under the dome of the gloomy hall there is a massive statue of the Lovecraftian god, you create an oppressive atmosphere, raise questions about what kind of creature is sealed in stone? Who and why worship him?
')
By this I want to say that even being in the techie mode and fulfilling purely technical tasks, the level designer should strive for his goal - the best way to tell the player the story and immerse him in the game world. Some may say that this is not important for PvP levels, but remember the classic map of “Warsong Gulch” from “World of Warcraft”, where the whole battle revolves around the confrontation of the Orcs and Elves for resources and territory. Nevertheless, even when working with something completely mundane, such as collider tuning, you are convinced that the user will get exactly the gaming experience you want to create for him.

Visual variety


A good level maintains the interest of the player, periodically changing the sensations of the surrounding space. We have a number of tools, including:




How to use forms in level design? An excellent example can be found in the Dreadnaught spacecraft in “Destiny”, where the diagonal elements of architecture create very unique sensations from the interior to the discomfort that is barely visible in the subconscious.



Without the help of colors, text, movement, sounds, etc. only one change of form as you progress through the level can reveal new facets of history. Look here: at the beginning of the level you are surrounded by clean, smooth shapes, and then irregularities appear. Even by the abstraction of the following picture, you can roughly understand what happened! Probably in your mind has already flashed a passage of some history.



By the way, a lot of interesting ideas can be gleaned by studying post-modernism in architecture striving for originality. Highly recommend. The "modern art" is not a very good reputation, but architecture, as a rule, is too expensive to be played with full mediocrity.

Unique frames


“Vista” is a sight opening player, but one that is breathtaking. In games with the open world, “vista” most often is the highest point on any tower or mountain where you look at the surroundings. We all remember the famous “sync” process in “Assassin's Creed”. For other games, epic types are created specifically, and not just allow us to look from top to bottom.



A separate subspecies "vista" can be considered "hero assets". As a rule, these are especially remarkable objects of the environment, often used only once per game. They pay attention to them, they are remembered, they are guided while they run around the level. In principle, a good example is the famous Citadel, towering over the City-17.

“Vista” and “hero assets” can help you make more memorable levels, add zest to them, but know the measure. You can fall into the trap and give them too much attention instead of the assets that will be used hundreds or thousands of times. Here is a picture from the article by the guys from Bethesda, who worked on the levels for Skyrim:



Think ten times exactly whether you need this unique content and whether you have the power to create it. It is especially important to soberly assess your strengths by indie developers who have extremely limited production resources.

Interactive and Dynamics


Unlike the previous paragraph, this one is relatively simple to create and use. Whatever moves on your location is cool! Simply put, any dynamic objects breathe life into the game. Try to add burning torches, flags fluttering in the wind, water flowing from pipes, waterfalls, swaying vines, flocks of birds above your head, and so on. It is difficult to describe in words - you have to feel this when you add dynamics to a static level, and it is transformed before your eyes.

Here you can add interactive objects with which the user can interact. They become an important part of the gaming experience, and not just statics in the background. The door can be opened, the lever can be pressed, the wall can be broken through, the barrel can be blown up, the column can be dumped. In “Diablo III” it was used quite often. For example, a classic example with a lever that allows you to bring down a massive chandelier on your enemies head. Or a stone wall that collapses when a hero passes by and accidentally touches it.

NPC can also be added to dynamic objects. In “White Garden”, a small village at the very beginning of “The Witcher,” is full of life - women wash clothes, children rush around and play with each other, old people smoke pipes on a bench, men beat muzzles in a tavern. This, of course, is a completely different level of dynamic environment, which requires a significant investment of power.

Fog as color correction


A very interesting trick: the fog does not just have a significant impact on the atmosphere and the plausibility of the level, but is also an excellent tool for color correction. Moreover, on mobile devices it is the cheapest color correction method (“weighs” about 3-5 fps).

In our game, we implemented the simplest tool that smoothly changes the fog when the hero enters the trigger. The simplest example: a player runs along a cozy sunny canyon with a blue mist. When he enters the cave where the thugs have lodged, the fog turns blood-red, keeping the atmosphere of danger uncomfortable.

To finally convince you of the power of this tool, compare the screenshots from the indie game I'm working on. Because of the fog, the first looks like a slightly overcast day, and the second looks like a sandstorm.



In the next two screenshots you can see a very light fog, barely noticeable. But even with this approach, the difference in shade is obvious.



There is a pitfall: you need to choose the right type of fog (for example, exponentional squared in Unity is usually best suited for this task) and density in such a way that the fog does not blur the texture and they do not lose contrast.

Returning to the atmosphere. Next come the screenshots from Crysis 3. As you can see, the upper space is compressed. It seems that the houses are very close to the player. At the bottom of the same picture neatly picked up fog visually expands the space, pushing the house in depth.



Lighting is love


Lighting is one of the most powerful tools at your disposal. I strongly recommend that you give it enough time and energy. Instead of a thousand words:



Even simple geometry with simple textures takes on an adequate appearance when lighting comes into play. Through the light, we transmit not just technical information such as time of day and weather, but also mood. Neat work with light allows you to fine-tune the atmosphere. Just imagine: bright sunlight. At one end of the spectrum you will have the harsh, merciless sun of a dead desert. At the other end is a happy mild summer sun, like in the anime about the first love of Tokyo schoolchildren.

How to achieve the desired effect of lighting? Art and experience, of course. I have no ready recipe. But these are lyrics, but I want to share one more practical trick: it is crucial to have variations in the color of the lighting. Follow the logic, but do not forget about the creative. If you put light sources only where there are lamps, the result will be stale and boring. At the same time, even a small color variety from light makes the level more visually attractive.

One of the interesting techniques: at first, only logical lighting is put (that is, where the lamp is located, there will be a source of light), but somewhat muffled, not final brightness. After that, additional colored light sources are added. They raise the overall illumination, while expanding the color palette.

There are exceptions, of course. For example, a level with bright sunshine can mostly consist only of it, and will look great. In this case, you will be helped by a verified ambient light, making colored shadows, as well as various post-effects on the camera to maintain the brightness of the sun (the notorious bloom, for example).

Blending light with surroundings


When creating lighting, initially you only have the light source and the environment that receives the light. They are separated from each other. But in reality between them there would be air, dust, atmosphere.



Here are some methods to help simulate the effect of light on “empty” space:





Post effects


Posteffects have a bad reputation due to their excessive use. From generation to generation, legends about the tasteless use of the Lens Flare effect are transmitted. In fact, well-balanced post-effects are barely noticeable and do not attract attention.

Post-effects and lighting are inextricably linked. In the image below, you can see how a light fog is added to the dark light (a Global Fog post-effect from the standard Unity set), over which Bloom is superimposed.



In other words, when working on lighting, always remember about fog and post-effects. The idea of ​​the level depicted in the picture is that you are in a dark and dark cave, and the silhouettes exposed by bright fog allow you to navigate in space.

The most powerful post-effect is considered color correction. With it, you can make changes to the color palette with jewelry accuracy. This tool came to us from the cinema, and now not one AAA game can do without it. By the way, color correction is used in cinema even when working with a conventional film without using computer graphics. If you look at the footage of “Fight Club” by David Fincher, then immediately pay attention to the characteristic green tint. This result was achieved through the special composition of chemicals used in the development of the film.

Other post-effects that you may find useful: tone mapping, bloom, antialiasing, vignette, chromatic aberration. I especially want to mention tone mapping, which simulates an HDR image based on LDR (low dynamic range) data. In the next picture I was completely satisfied with the brightness of the light, but some objects turned out to be excessively overexposed.



Notice the changes that occurred on the little blue monitor to the right of the aisle. This is the result of the post-effect tone mapping. To sum up, caution: try to be careful when dealing with post-effects. It is easy to be deceived by making a poor level with mediocre lighting, and hardly sprinkling it with “sugar”, to decide that everything is cool with you.

Conclusion


I hope this selection will give you a couple of new ideas for your projects. I plan to write another article on the same topic. In it, I’ll tell you about prototyping, hero and entourage scale, the character’s running speed, colliders, pleiting, and much more. It should be even more mundane, with fewer pictures, but well packed with my experience.

Meanwhile, if you are interested in the rendering of lighting in Unity, I already have a technical article on Habrahabr. Frankly, having accumulated more experience, I see that there are some inaccuracies in the article, but in general it is close to reality. Therefore, if you are just studying the topic of lighting in Unity, the material should be useful to you.

Source: https://habr.com/ru/post/274483/


All Articles