Now available on the marketplace! Marketplace Link
Highly customizable multiplayer template for creating TopDown or Survival games.
** User Guide **
Features
[spoiler]
• Twin-Stick-Shooter controls
• day&night cycle including clock with customizable format
• climate system with fluctuating world temperature and temperature modifying areas
**Multiplayer system **
• create and join multiplayer sessions
• reconnect to sessions with your character being remembered by the server (identified by the playername)
• scoreboard with customizable sorting order
**SaveGame system **
• separate SaveGame objects for the game and for the options
• variables of a player’s character can be saved bound to the level or saved bound to the SaveGame.
**Realistic hunger, thirst and body temperature system based on thermodynamic laws **
• human body tries to regulate his body temperature by shivering and sweating
• drinking does affect the body temperature depending on the temperature and amount of the fluid
• clothing modifies how much the air temperature does affect the body temperature
• PostProcess effect covering the edges of the screen warning the player that he is close to becoming hypothermic / overheated.
**
Inventory, Equipment, Crafting and Building system **
• optimized for low usage of network bandwidth in multiplayer games
• move, swap, split, stack, resize, use, equip, unequip, drop and pick up
• lootable actors with customizable random loot
• add or remove craftable items and modify their crafting cost and time to craft during the game
Please note: The Twin-Stick-Shooter controls and the example map are designed for TopDown games. Everything else will also work in Third-Person and First-Person games.
[/spoiler]
FAQ
Where can I find the tutorials?
This pack currently has 11 Blueprint Editor Tutorials. These tutorials cover the character, inventory, equipment, crafting and building, weather, food water and temperature and interacting with actors and outlining them, start menu, multiplayer system and the SaveGame system. You can find them under Edit->Tutorials in the level overview or under /Blueprints/Tutorials. These tutorials cover where to find specific logic, how it’s set up and explain how things like inventory items, equipment slots or wind speed can be quickly added. If anything remains unclear after reading the tutorials please contact me about your issues. I will always help you to realize your vision and be thankful for all feedback that will help me to improve the documentation.
Can I play with a friend over the network?
This system uses the Online Session nodes and therefore you can. Check out the Unreal Engine 4 documentation to find out more about the Online Session nodes.
Will basic AI (for example zombies) be added to this pack?
I will consider that in the future but it’s not at the top of my list. I will keep focusing on features that are more related to each other first. Such an AI would have nearly no relations to the existing features and would therefore pretty easy to integrate into the template for everyone.
The widgets stop updating after they have been drag&dropped
I am aware of this issue but this is an Unreal Engine bug. This issue is documented in the report UE-31777. Epic will hopefully fix that bug in the near future.
Additional Tutorials
Drop / Pick up item actors outdated since v1.2.0
Add a new item
Remove the survival part (day&night cycle, temperature, food, water)
Changelog
v1.1 (12-22-2016):
- The 12 hour format of the clock wasn’t displaying the correct hour. This is now fixed.
- Fixed a bug that was causing the inventory system for one client not working properly when using a dedicated server.
- Fixed a bug that was causing the temperature system for one client not working properly when using a dedicated server.
v1.2.0 (02-14-2017):
New Features
[spoiler]
Near game-ready StartMenu
This includes a singleplayer (create new game, load singleplayer SaveGame), a multiplayer (Host new game, Host multiplayer SaveGame, Join game and an options menu (default options for saving, full graphics options). The StartMenu is designed minimalistic just like the user interface and the same widgets are reused as often as possible so you can change the design quickly as soon as you want to.
Game menu
Ingame a player can open the GameMenu by either pressing Esc or F1. The widget used for this menu are the same as that in the StartMenu so the style will automatically be consistent. You can choose if the screen should be blurred while the GameMenu is open. In singleplayer games opening the GameMenu pauses the game.
Multiplayer system
The Multiplayer system uses the Online Session nodes with all functionality these nodes offer. In addition to the JoinSession node a game can be joined by directly entering the host’s IP. The server will load the last status (including inventory, equipment, crafting manager) when a player who’s known to the server connects. The server even differentiates on which levels a player is already known and you can quickly change what variables will be remembered bound to the level and what variables will be remembered bound globally over all levels. Each player can chose some player specific variables combined in a struct when joining a game. This variables are used to define what type of character the player wants to play. Whenever a player respawns these variables will be used to set up the new spawned character aswell.
A player is identified on the server by the playername he chose. There is no unique way to identify a player without an online subsystem. Before releasing the game you will most likely want to replace this with a unique ID of the online subsystem (e.g. steamID).
SaveGame system
The SaveGame system is directly connected to the multiplayer system. Whatever variables you choose to be bound to the level or bound globally bound over all levels will be saved and loaded just like that. In addition the SaveGame system saves and loads the inventory of all actors with an inventory in the level, the transform and remaining burning duration of campfires and the Open/Closed status of all actors that inherit the interface BP_iOpenable (windows, doors). The SaveGame system also saves and loads game specific variables that define the rules of a game (e.g. difficulty, weather). At last it also saves some variables like the current level, date of save and the ingame time.
The options (SaveGame, video options) are saved in a different SaveGame object so these are remembered after restarting the game.
Scoreboard
The template now includes a scoreboard. This scoreboard will automatically display all online player and their chosen name. The scoreboard displays the name of a player, his score, deaths and ping. Score and ping are stored in the player state and (per default) increased whenever one player killed another player / dies. The scoreboard can be sorted in ascending or descending order for each of its attributes. Per default a player can change this order by clicking on one of the buttons of the scoreboard.
Inventory system
- The inventory system now uses a DataTable to store the information of items that don’t vary between instances of an item. This nicely reduces the memory usage (especially from empty slots) in case of very large levels with many inventories.
- Items can now be dropped and picked up
[/spoiler]
Changes
[spoiler]
- The inventory system now only replicates an inventory when a player opens it instead of replicating neutral inventories to everyone. This is the absolut minimum information a client can get from the server and therefore as proof to cheaters as the rest of the template. This does also fix an issue of the inventory system regarding network relevancy that could’ve occured earlier.
- The template now follows Allar’s style guide as much as the submission guidelines allow it.
[/spoiler]
v1.2.1 (02-24-2017):
Changes
- The class BP_InvItem_Buildable is now removed. The campfire and other buildable items now directly inherit from BP_InvItem. They become buildable if both of the buildable variables in the DataTable DT_Items are set.
- Some Server RPC events are not longer RPC events and start with a SwitchHasAuthority node instead.
v1.2.2 (04-13-2017):
Changes
- The component BP_Inventory now contains a function for resetting the inventory so it can be looted with randomly generated items again. Calling this function will only have an effect if called on the server and when no player does currently has the inventory opened.
- The type of the attachable equipment meshes is now skeletal mesh.
- Fixed a bug caused by the editor that resulted in a warning in BP_PlayerCharacter after each editor restart before compiling.