Online shooter on Unreal Engine 4 for 90 hours (video creation + source)
Hello harb! About a year ago, I laid out an article about how I live created a survivor for 150 hours . This time I want to introduce you to a network shooter that I created in 25 visits of 3-4 hours. In total, it took about 90 hours and as a result we created an online shooter, which we played together with the audience.
As in the last series, the goal of the project is to show beginners how to work with the network in UE4 using the example of a shooter. In the streams, we looked at how to organize communication between the server and clients, where some logic should be and to execute, and also looked at various side aspects of development, such as creating maps, setting up animations, and so on. ')
Despite the sheer time, this project took about 10 months. I took long breaks in the streams, but nevertheless, I finished the development and now it is available to everyone for free and without SMS. If you are interested in details, recordings of streams, source codes or a build of the game with the server in a set, I suggest reading further under the cut! In the streams, we considered almost the entire process of creating the game (except for its release). From planning, to importing and customizing graphics and testing with real players. However, due to the tight deadlines, we missed a few important points, such as balancing, prototyping, and a couple more moments.
Most, of course, went to the logic of the game. Initially, we implemented the character's behavior, we made the manager and weapon classes, then we made game modes and rounds.
Almost the entire project is written in blueprint. The reasons are quite simple:
The course is aimed at beginners. In C ++ it’s difficult to navigate, and it’s more and more clear.
It makes no sense to use C ++, when there is no performance advantage from it. The client worked steadily and quickly. A server with 16 players occupied only 1-2% of the processor (home i7 4770). And the whole logic is event-oriented.
If desired, you can turn on the blueprint of the blueprints, so that they convert to C ++. Due to this, the difference between Blueprints and C ++ remains only in convenience and capabilities, but not in performance.
All that we needed was the Blueprints. The only time you had to get into C ++ was to write session creation. Of course, Blueprint also knows how to do it, but it was necessary because the Online Subsystem and its master server would work, which a developer can attach (for example Steam)
We also worked on the graphics. There was no time for realistic or any special graphics, so we made simple, cartoon graphics with a stroke. Weapons and characters left standard. We even made two cards, so that after the end of the round we would have a vote for the next card and, accordingly, the transition itself.
A list of all that we have implemented during these 90 hours
Character
Basic character management
Gamepad support (tested on Xbox 360 Wireless Controller)
Component of lives and armor
Running and Stamina System
Animations of the character from the third and from the first person
Support for secondary action on the PKM (for example, the sniper's sight)
Recoil and spread of firearms
Reloading and registration of the cartridge in firearms
Various advanced settings (Amount of cartridge, rate of use)
Game modes and rounds
Basic game mode with basic logic (death, respawn)
Deathmatch mode - "Every man for himself"
Command mode
Round system
Points of the round on points and on time
Waiting for players and counting the beginning of the round
End the round with voting for the next card.
Content
Closed Card - Hangar
Open Card - Warehouse
Static stage lighting
Various models taken from personal projects or from Epic Games demo projects.
Sounds of shooting and walking
Effects of a shot and bullet hole
User interface
The main HUD with information about the character and weapons, as well as information about the round
Minimap
Tab menu with match and player statistics
Chat
Kill chat (panel where recent murders are shown)
Pre-round window with a list of players and team selection
The window after the round with the results of the match and the vote for the next card
Sessions search window (without a master server, only the LAN server is working)
Main menu with settings and search. It is the pause menu
Here is a video review of all that we have done:
Of course, this does not look like a finished product, but I hope that the project has completed its work. We considered a lot of useful things, used all the basic features of the blueprint for client communication with the server. As a result, we collected a dedicated server and played it all together in 8-to-8-player team mode.
In addition, I want to say that outside the stream, I put together a build for an android. The game worked and connected to the server normally. My friend and I were able to run together (he is on the phone, I'm on my computer). Of course, we didn’t control for the sensors, but I still wanted to add this fact to the article. So if you need a session shooter for phones, welcome.