Search Unity

Games Darfall - Survival City Builder with RPG elements

Discussion in 'Projects In Progress' started by Wrymnn, Dec 27, 2022.

  1. Wrymnn

    Wrymnn

    Joined:
    Sep 24, 2014
    Posts:
    380
    Introducing Darfall, a strategy survival city-builder with RPG elements. You lead your hero with a band of warriors to defend your settlement, explore the corrupted land, and craft new items. Expand your settlement and defeat the darkness coming from everywhere.



    The project has been in development for approximately two years, with myself as the programmer and my friend as the artist.
    Despite having 8+ years of experience with Unity, I have carefully designed the project's architecture, code, and workflow to ensure that the project remains organized and manageable.

    If you are interested, I would be happy to share some of the technologies and techniques that we have used in the comments below, or in our discord.

    MORE INFO



    Wishlist: https://store.steampowered.com/app/1961600/Darfall/

    We have also Dev Blogs that offer a sneak peak into some features of the game from the technical standpoint, one of them is what we use for our AI, or how the procedural maps are generated.

    FEATURES

    Build your Settlement


    Explore the Map


    Loot Various Items


    Survive Invasions
     

    Attached Files:

    mgear likes this.
  2. Wrymnn

    Wrymnn

    Joined:
    Sep 24, 2014
    Posts:
    380
    DevBlog #1
    https://store.steampowered.com/news/app/1961600/view/3317486166925335061?l=english



    Hello all!

    We are two indie developers, Lukas (me) and Martin, working on a Darfall game, where you build, defend, loot, explore and survive waves of undead invasions during the night.

    This is the first dev blog, we hope one of many, where we introduce the game and ourselves to you.

    I started this project several years back as a solo programmer. The original game was a player controlling this viking village, balancing its economy, all made using just 2D graphics.
    The project later transformed into a 3D game, where you fought over a control of various islands inhabited by enemy factions :D
    Later on, I removed the islands and just made one giant map where you built a city and defended against invasions. This was more or less the idea of the game we currently have. We then introduced some unique mechanics, like leveling and equipping a hero, crafting of items in your city, or a day & night cycle.



    A year ago, my artist friend Martin joined me in this endeavor. Martin did a great work on marketing, steam page, game trailer and the UI art. We also do a game design together, so you can imagine how two different mindsets have to work together and try to connect ideas into a single one (while still trying to stay friends :D)

    The project is done in a Unity engine, as this is the engine I've been working with for almost 10 years, both in hobby projects and professionally.



    Above you can see the entire map generated from the Unity editor view.

    And this is where all the work is done from my side on the project


    And this is Martin's desk, you can see the creative notepad he uses for his sketches and ideas :D


    We hope you liked this brief introduction about us and the project :) Next dev blog post will be about the Main Menu rework we focused in the past week.

    See you in the next blog post!

    Martin and Lukas from SquareNite
     
    tsibiski likes this.
  3. Wrymnn

    Wrymnn

    Joined:
    Sep 24, 2014
    Posts:
    380


    Hello everyone and welcome back :)

    Today, we want to show you the work we have done on the Main Menu in the past weeks. It was not the only improvement to the game, far from it, but it's something visually interesting we can show you.

    As we are moving closer to the testing phase and giving the game to other people, the menu is the first thing player sees when they start it up.

    Our old menu was not changed for more than a year, it was full of empty screens and placeholders, since it was not a high priority during the development.

    Bellow you can see how was the main menu screen looking before



    and now the reworked menu page



    Following is the old page where player could choose which survival map to play



    and the new version with additional info and improve art



    next we have the load game menu, which was a complete mess :)



    now its a clean and dedicated screen with all your save files



    and lastly, we have a loading screen, which was really just an empty screen with simple status text



    and we transformed it into a more informative page, giving you a loading progress bar, as well as cycling game tips, which can give you more hints and info about the game as you wait for your new world to generate



    Martin, our artist, did an amazing job on designing the UI and we are really satisfied on how it turned out. There are still improvements we want to make to the menu in the future, as having a 3D animated scene from the game.

    We hope you liked this new visual update!

    See you in the next dev blog post, where we will talk about how the AI works in the game.

    All the best,
    Martin and Lukas from SquareNite
     
  4. Wrymnn

    Wrymnn

    Joined:
    Sep 24, 2014
    Posts:
    380


    Hello everyone and welcome back :)

    It's me Lukas and today I will talk about how the map is generated in Darfall.

    Since maps in Darfall are procedurally generated, we needed a versatile system that would allow us to modify any part of the map generation, like which trees are placed into the forests, what areas will our forests cover, or what units and structures are generated into which parts of the map.

    This system is fully "scriptable", this means that Martin, our artist, can modify any part of the map generation without me needing to touch the code.

    Grassland Map

    Let's start with few steps of how the
    Grassland
    map is generated. First, an empty body of water is placed onto the map



    Next, the terrain tiles are generated, with mountains and bodies of water. Both use perlin noise to make them look natural.



    Then resources like trees and iron veins are placed into the map. Trees are also generated using perlin noise, which gives the tree clusters more natural look.



    Finally, enemy camps are placed into valid locations, like orc camps or undead zones



    Camps

    Any enemy "point of interest" location is called a camp. These are also procedurally generated. We have a simple system that allows us to quickly populate these camps with props and loot in the Unity editor without touching the code.

    Some simple examples of orc camp can be seen here:




    All these tools allow us to create quite an impressive locations, like undead zones which create an atmosphere of dangerous corrupted lands



    Above were just quick examples of the processes we currently have in its initial stages. In the future, we plan to generate entire villages, forts or encampments for different races, that will be present across different map biomes.

    I hope you liked this quick sneak peak of how Darfall is generating its map :)

    See you in the next dev blog post!

    All the best,
    Martin and Lukas from SquareNite
     
  5. Wrymnn

    Wrymnn

    Joined:
    Sep 24, 2014
    Posts:
    380


    Hello everyone and welcome back :)

    It's me Lukas and today I will talk about how the AI (Artificial Intelligence) works in Darfall and what we use in the background to drive it.

    At the very early stages of the development, the AI for our units was quite simple, like moving to a position, or attacking a target. I wrote this behavior in pure code with my own implementation, but it turned out to be super messy and unreadable quite fast. Even such a simple AI behaviors takes A LOT of code to write.

    Later on I tried to research what other tool I could use for our AI. I came across Behavior Designer, the most popular AI asset on the Unity asset store. In the Behavior Designer, you put nodes on a visual graph and depending on how you place and connect your nodes, it will create AI logic you desire.

    Simple Tree

    Here is a very simple node example, showing how the AI waits for some time, then picks a random position and walks towards it.



    You could probably deduct what these nodes do even if I did not explain the logic behind them. This is why having a visual tree such as Behavior Designer helps immensely during the AI development and navigating its different parts.

    Woodcutter AI

    The following tree shows a small example part of the woodcutter AI. The nodes are evaluated from left to right, where left nodes have the highest priority and always try to execute first.



    1. Do we have any resource to carry?

    - If yes, carry it to storage
    - If not, continue to the next node segment 2.

    2. Have we found any resource to gather?

    - If yes, move towards it and gather it
    - If not, continue to the next segment 3.

    3. Wander around aimlessly until the worker faints out from exhaustion :D


    Player Unit AI

    Here is another example, a full tree that represents the AI behind the player warrior units:



    You can see how complex this can get very quickly even with a such visual tool :)
    Now you can imagine how hard would it be to write all this AI logic in pure code, without any visual tree representation.

    The AI is usually the most challenging feat to handle during any game development. I had to rewrite the entire AI in Darfall for several times already, using different approaches or plugins, such as NodeCanvas.

    I'm happy how it turned out and that Behavior Designer trees were a good choice, reducing future bugs, or making it much easier to implement new AI logic like possible boss fighting mechanics.

    See you in the next dev blog post.

    All the best,
    Martin and Lukas from SquareNite
     
  6. vintage-retro-indie_78

    vintage-retro-indie_78

    Joined:
    Mar 4, 2023
    Posts:
    285
    this looks really amazing // looks to be Nintendo, perhaps even SteamDeck hit - title . . .
     
    Wrymnn likes this.
  7. Wrymnn

    Wrymnn

    Joined:
    Sep 24, 2014
    Posts:
    380
    Hello everyone and welcome to our 5th Darfall update. It's me Lukas and today we have something interesting to cover.

    We hope you enjoyed the last AI Update, where we explained the workings behind our unit "brains".

    Since our last update, we have been hard at work on fixing bugs and adding quality of life improvements, as well as some new features.

    One of those features are legendary item powers. Legendary items drop very, very rarely and thus have a huge glow you just cannot miss. This was heavily inspired by Diablo, those of you who played know this :)

    You can see the huge orange legendary glow compared to other item types: epic (purple), rare (green) and common (white).



    Finding a legendary item boosts your hero power significantly and can decide whether you survive the next night or not.

    Moon Robe

    One of these legendary items is the Moon Robe of Defence. It’s used primarily by caster heroes (such as our Archmage) and also gives a huge boost to healing and ability damage.



    As the description states, it has a chance to activate a protective barrier around your hero that absorbs all incoming damage for several seconds.



    Phantom Mask

    Next one is another legendary with an interesting power, a Phantom Mask, which has a chance to fear an enemy, making him unable to move or attack.



    As you can see, the enemy skeleton archer has a fear icon over its head, as it was feared by the hero's Phantom Mask



    Other Legendaries

    Here are some other examples of legendary power items you may come across when defeating powerful enemies.









    How to Get Them?

    All of the legendary items have a very low chance to drop, but they only drop from the most powerful foes you can find roaming the map, such as Orc Warchief from the orc camps, or the Undead Warlord protecting its graveyard.

    (Angry Orc Warchief)


    (Undead Warlord)


    It will not be easy to defeat these enemies, but once you do, the rewards can be great, giving you a huge help surviving more nights.

    We hope you liked this dev blog and are eager to find these items on your own and use their powers to your full advantage.

    If you have any thoughts to share, please don't hesitate to share them in our Discord.