Devlog 16: I Just Bought A Server YAY?!?

So a lot have happened since the last update. But the biggest thing is I purchased a server for development. But before I get into the update road map, let have a quick rundown the changes since Devlog 15.

All Project and Current Game Project Rebirth.

  • All projects have been update to Unity 2020.3 LTS and Entities 17.
  • All Project are being update to Dx12 and HDRP Pipeline
  • All Project will be using Unity Physics going forward.

ECS Character Controller

  • Major Refactor started in branch WIP 0.1.1 Combo Testing
  • No longer using Animator Based Transitions
    • Animator Transitions cannot be changed or muted at runtimes. This made making an unlockable combo system quite difficult.
    • Transition to a scriptable object system using Animator.Crossfade API calls.
  • Projectile System implement
  • Character Stat system reworked for Entities.
    • Adjust Health is now a function of the CharacterStat Component.
  • Melee Hit Detection System disabled. System to be reworked to use Entities and Unity Physics

ECS IAUS

  • AI Vision Detection system refactor to using Unity Physic Raycasting API. Massive performance Improvement
    • Need to Update to target specific body points
  • Influence Grid System reworked.
    • Need to Update scheduling system so influence grids only update once every 5 secs
  • Creating Scriptable Object Editor Window for Creation of IAUS AI Prefabs

General Game Dev

  • Working on Menu using for Project Rebirth: Moonshoot Proof of Concept game
  • Working on Serialization system for Project Rebirth: Moonshoot Proof of Concept game
  • Researching Networking
  • Researching Build and Testing using local hardware
  • Testing SMT On vs SMT Off of AMD CPUs with DOTS
  • Working with Substance Painter

Between leaving my previous employer, starting a White Collar 9 to 5 job and WFH due to Covid-19, I have found myself with a lot more time to game development. I have made a lot of head way on my game and DOTS projects. This has caused some self-reflection on what I really want Dreamers Inc. Is this just a stress relief hobby? Do I actually want to game for sale? How big of a release do I really want to do? Do I have the skill and equipment to do this? I have basically accepted this a hobby and I don’t see myself leaving my full time job any time soon. I don’t have the mean to support myself of it and I don’t expect to make anything of Project Rebirth. However I am follow committed this hobby. I am going to do this, I am going to do this to best of my abilities. After taking stock of the equipment I current have on hand and the long and short term goals for Project Rebirth, I accepted that I need a Home lab. 

As it stands, my current projects are backed on several cold storage externals and there are all cloud based features of Unity I want use without paying Unity or Microsoft for just yet.  At this point spending money on Servers for Test Multiplayer, Cloud Build, Testing Simulation, Testing other system, and playing Project Acoustic is potential waste of resources. So I have pick up a used HP DL360 g7 for $200 applied some fresh thermal paste and spent a week fight to get Proxmox installed. (SN: Anyone looking at HP server, USE ILO3 VIRTUAL DRIVE FOR INSTALLING PROXMOX FOR YOUR OWN SANITY) This 1U Rack Server will be the first part of my home lab. Right now I will be using this for learning networking, understand server requirement for my game should I decided to do Server Based MP, and Build/Testing of games. So let me know in the comment if you are possible interesting in Server related content.

Posted in Dev Log, Development, Information, Unity, Video Games, WIP | Tagged , , , , , | Leave a comment

Devlog 17: Under the Influence Maps

When it comes to struggle in the four major areas. I often dream too big. I’m stubborn as hell. My organizational skills are limited at best. And I really suck at keeping things updated. Apparently the last updated devlog I did was six months ago. I can’t believe that much time has passed already. However you really don’t get a good time reference until you have been working and noticed that you either made no progress or made tremendous amounts. In a moment of clarity last week I realized that while I’ve made some good improvements to my projects, none of them are particularly useful. There’s one big issue holding me back with my project right now, the influence map system. My implementation of the influence Map system has been so bad that I’ve been avoiding reworking it for practically six months.

Last week, I decided I needed to start fresh. So I trashed all the sticky note off my white and deleted like 3000 lines of code. Below you will find a list of the changes due to this restart

  • Infinite Axis Utility AI System Stable Branch 0.7.2-2020LTS release.
    • ECS Influence grid System removed
    • Generic Grid Influence Map Implemented. Code based on the Generic Grid system created by Code Monkey. Video Posted below. 
    • Retreat system now based on enemy threat and friendly unit proximity in area
      • This is a basic  implementation refinement to come in future updates
    • Hearing system temporarily removed. 
      • This system has not been delete and could be brought back into the project for enemy detection of the player. 
    • Platform Build Pipeline Package imported into project. 
  • DOTS Inventory System
    • Started prototyping Skill and Magic augmentation system. 
Posted in Uncategorized | Tagged , , , , | Leave a comment

DevLog 15: The One About the DOTS IAUS Repo

Apparently an update is way overdue. I’ve seen a lot of people start to follow me on GitHub as well as followed various projects I’m working on. However I was not sure how much of it was genuine interaction versus people waiting for a potential free product to use on their next game. This is mainly because I don’t see any issues being logged by user. If you’re running into bugs or have questions about how or why something was written the way it was, please log an issue on the repo. I can’t guarantee a quick answer as  this is a secondary job. But I will do my best to answer as thoroughly as possible. 

Based on recent alerts on my Unity forms account, I think it’s time for me to do an overview and kind of getting started guide on the work with dots and the infinite access utility AI system. For those of you that are unaware what utility AI is, the linked GDC Talks by Dave Mark will give you a complete overview of the system in ways that I could never do justice.

2013 GDC talk by Dave Mark 

Architecture Tricks: Managing Behaviors in Time, Space, and Depth starts at 33 min mark

So What is the IAUS System Repo?

The IAUS Repo is my attempt at Dave Mark’s Infinite Axis Utility AI using Unity’s Data Oriented Tech Stack’s implementation of ECS. This is to be the main AI used in the upcoming Open World Action RPG I am currently working on codenamed Project Rebirth. Beyond just being highly performant and more realistic AI, this project is focus on have an easy to implement and modify States, simple to implement AI states, and high degree of variety in AI agent with relatively little work. At this time, Dreamer’s Inc Studios is a passion project for most of the developers involved. We have primary jobs that pay the bills. So having a system that is not a nightmare to work with takes priority over refined intricate solutions. I say that because I know there are areas where there are better solutions and that I should be targeting a Pure ECS solution.

What is my system doing?

Going forward, I am assuming that you are knowledgeable of ECS, Unity DOTS as well as IAUS or have watched the videos linked above. This project is a work in progress, so expect changes to the workflow. A ScriptableObject Editor based workflow is being developed currently. Also an influence map system is all being created to work with this system. 

Editor

For simplicity, the system can be broken into 2 parts, Editor and Runtime. 

For the editor portion, I want to maintain a simple to easy that is highly customizable. For that reason, each state is implemented as a component. This allows the user to modify the response curves of each AI state on a per entity. To get IAUS running on a npc, all the user needs to do is add the Base AI Authoring class, NavMeshAgent class, assuming npc can move, and the desired AI States.  

Certain states do have help class and IComponentData that are required for functionality. Example are the PatralWaypointBuffer required for the Patrol State and AI Sense class require for the Move To Target state.(Side note: Most of the Enemy npc AI states are still under development). Once all the desired states are added with their state value, simply run the game and everything “should” work accordingly. 

Runtime and Scripts 

There are definitely efficient ways of handling IAUS or why didn’t I do it this way. At this time, the focus is on functionality. Also based on recent testing, the NavMesh system is a larger bottleneck to performance. In recent testing of 500 IAUS Agent running, the entire ECS code running on this system takes under .66ms. So for now, I am not going after anymore performance.

Everything starts with BaseAIAuthoring Class which adds the IAUSBrain, StateBuffer, and temporary SetupIAUS components to each AI Entity. The SetupIAUS component allows for the SetupIAUS Tag causing the IAUSBrainSetupSystem to run. Based on the AI State components added, a state buffer is added to the entity and the additional component required for the state operation are either verified or added to the entity. From there, each state score of each state. Currently this is done in a separate system for each state. This is probably change to an single multi job system in the future. Once that has been completed, IAUSBrainUpdate is called and the highest scoring state’s Action tag is added if it is different from the current state tag. 

Now we reach, the cause of Alpha 0.7, The implementation of a Generic Reactive System, which was Developed by WAYN_Games on the Unity forum.(link). In a nutshell, with the addition of this system, I am able to run specific jobs when the AI State Action tag are added or removed. 

Posted in Dev Log, Development, Information, Unity, Updates, WIP | Tagged , , , | 2 Comments

DevLog 14: The Joys and Woes of Being a Solo Dev

After completion of the transition from ComponentSytsem and JobComponentSystem in the ECS IAUS and adopting a reactive tag system, there has been a major bump in performance. SystemBase allows for usage a Schedule Parallel and reduces the amount of the boilerplate. The amount of boilerplate code required after removal of IJobForEach and transitions to Entities.ForEach Lambda operator was one of my big complaints. I originally avoid transition to IJobChunk due to the fear of unity later abandoning them as well. Its seems those fear are possible unfounded as Entities.ForEach Lambda operator jobs are compiled to IJobChunks at build.

Based on the performance increase I am seeing from SystemBase and Reactive Tag System, I have decided to wait on the work on a Frequency Phasing System for DOTS ECS. This decision was driven by my 2000 AI agent test hitting 60FPS with Ryzen 7 1800x down cored to 2 core on a single CCX running at 4.1 ghz Tubro. So we are merging the changes into the main branch and pressing on.

Unfortunately, I need to step away from the AI system in order to advance the rest of the project. We are at the point of write game specific AI state like Attack, use skill, and use item. To implement this state, I need to focus on create the systems that use them. This is one of the pains of Solo Game Game Dev. So if you are following the Github page, you will see a couple of new repo for Inventory and Skill system using DOTS.

Posted in Uncategorized | Leave a comment

Devlog 13: The Beat Goes On

After a brief, unwelcome hiatus, we are back to work on Project Rebirth and the Git repo that support it. Just recently, the ECS Infinite Axis Utility System, IAUS, received an update to the Alpha 0.5.1 as well as the creation of an experimental branch.

In Alpha 0.5.1 update, the DOTS Spawner Repo has be incorporated in to the project along with Scriptable Objects for Enemies and Squad using the IAUS system. This addition created a test scene for random squad patrolling using the default built-in NavMesh system. Using a stock Ryzen 7 1800x paired with AMD RX5700 XT, the testing scene running 600 drones at 1080p 120fps and 1500 drones at 1080p 45FPS. While there is still a large of amount of code to write for IAUS system, there is a need to work on system efficiency.

In the new experimental branch, we are testing 2 potential optimizations, Reactive components and Frequency Based Update Systems. The Reactive system goal is reduce and simplify code by have component that update the IAUS system when components are add/removed.2020-06-28 20_28_59-ECS IAUS sytstem - Microsoft Visual Studio

The basis for the Reactive System can be found here on the Unity Forum created by Forum user WAYN_Group.

The second system in production is a frequency phase system for DOTS. The goal is to spread out the entities update across a range of frame. Simply put instead updating 600 frames each frame the system will update 60 entities across 10 frames.

We will keep you updated on as these systems progress

 

Posted in Uncategorized | Leave a comment

Relearning How to Write Custom Editor

2020-05-19 21_51_11-Window

First Custom Editor Window in 3 years

It is true when they say if you don’t use it, you lose it

Posted in Uncategorized | Leave a comment

Dreamers Inc DOTS Projects Recap.

See how this blog and the associated Github repos are starting to starting to see a little bit more traffic due to more people becoming interested in Unity DOTS, I figure now might be a good time to recap/introduction of Dreamers Inc and projects we are working on.

Dreamers Inc Studio is small indie game dev team conceptual back in late 2000s at Kettering/GMI University. The driving principle for this team is simple. Make the game that you want to play. We are not here to chase trends or make the next Fortnite, PUBG, or Stardew Valley. In design principles, we believe a game is ready when it is ready and that a game should be as complete as possible on release. This means we are not saving anything for DLC and a season.  If DLC pack should be released, they will be there standalone story that is a new adventure using established character of that game.

Currently Dreamers Inc has 3 open and actively shared Github repo regarding Unity DOTS and 4th in development for a HDRP Custom Scriptable Render Pipeline.

DOTS Infinite Axis Utility AI 

The repo is a recreation on Dave Mark’s Utility AI System used in games like Guild Wars 2 in Unity DOTS. You can learn more about Utility AI and how the Infinite Axis solution fixes issues with unbalanced number of consideration in the follow GDC talks.

The basic principle is that each state receives a Utility Score based on world factors like Character Health, Enemies in Area, Party Health, or Distance to Target. The State with highest utility score get performed.

DOTS Spawner

DOT Spawner project is a wave and world spawning system driven by DOTS. A Spawn game objects are stored as Scriptable Objects and given an ID number. DOTS spawn find that ID number and spawns based on available spawn points. DOTS Spawner repo also contains an RNG Loot system.

DOTS Motion System

Perhaps the one repo that is getting the most attention right now. The ECS Motion System is a redesign the Unity Standard Assets 3rd Person Character Controller. This system is created for Project Rebirth Hack and Slash Game currently in development. The design to have both Character controlled and NavMeshAgent driven character models animated using DOTS system. This is a hybrid ECS implementation as NavMeshAgent and the Animator currently do not have ECS based systems.

Posted in Uncategorized | Leave a comment

Dev Log 12: Starting to Form a Game

Its has been a hot minute since I have update this blog. Which to those of you who actually read isn’t very surprising. Since the initial launch, I have struggle to maintain a regular update cycle.  But I digress. If you are following the github repos for ECS, you will see there has been a lot of work done on Infinite Axis Utility AI System.  Besides some optimization and few refactors, the framework of the system is completed. All that is left now is to make the AI action status and  start testing the system.

 

 

Posted in Uncategorized | Leave a comment

Dev Log 11: Entities preview 0.8.0

One of the most difficult parts of working on this project has been the use of Unity DOTS. Unity DOTS is very much in is early infancy stages being that is a preview package. This being a solo developed project is is mildly insane of me to use DOTS. The documentation is highly technical. Tutorial available are either extremely based or outdated from the initial announcement of Unity ECS. Unity’s over examples going from rotating a cube  to an advance Boids system. In fact, if you are reading this, most likely you are looking for help with some unclear console error message.

2020-03-22 11_56_42-ECS IAUS sytstem - Influence Map work area - PC, Mac & Linux Standalone - Unity

Vague Error Message

On March 13, Unity release Entities package Preview 0.8.0. And with it have disrupted my entire knowledge and work flow moving forward.  The 2 big changes in preview 0.8.0 are as follows:

Deprecated

  • Types that implement IJobForEach interfaces have been deprecated. Use IJobChunk and Entities.ForEach for these jobs.

Fixed

  • Allow usage of Entities.WithReadOnlyEntities.WithDeallocateOnJobCompletionEntities.WithNativeDisableContainerSafetyRestriction, and Entities.WithNativeDisableParallelForRestriction on types that contain valid NativeContainers.

This means any one who write JobComponentSystem using the IjobForEach system should either remain on preview 0.8.0 or older or refactor their project as IJobForEach will be removed on 6-20-2020 per the warning in Visual Studio. If you chose to remain on thie version of Entities, you can stop the warning from showing in the console by using [System.Obsolete] Attribute tag.

While the refactoring can be done quite easily, the ForEach Lamba operator Job system add a lot of boiler plate code and takes away from the principles of Clean Code.

2020-03-22 12_15_55-ECS IAUS sytstem - Microsoft Visual Studio

From This

2020-03-22 12_16_38-ECS IAUS sytstem - Microsoft Visual Studio

To This

While I love the boost in performance I get from using DOTS, each update makes its harder and harder to recommend anyone use the full DOTS system. Overall the documentation is far too technical for the average unity user. ECS implementation has changed majorly since its launch. Too many of the major system Unity, developer depend on can’t not be easily accessed using DOTS, IE NavMesh.

 

Posted in Dev Log, Development, Information, Lessons Learned, Unity, Updates | Tagged , , , , , , | Leave a comment

Scriptable Render Pipeline: Start of a For Dummies Series

I am currently stuck between a digital rock and hard place. To create the desired visual effect for Project Rebirth, I need to use the Visual Effect Graph and ShaderGraph packages. ShaderGraph allows for easy creation of custom shaders without extensive shader programming knowledge. I have already used ShaderGraph to create a shader for Magic Conjured weapon, which uses a dissolve effect. Visual Effect Graph allows the particle system to be ran on GPU instead of the CPU. Considering some of the VFX I have in mind for spells, this is an essential requirement for my project.

However, in order to use either of these packages, you have to use the Scriptable Render Pipeline, SRP. No sweat, you might be thinking. Unity has two-production ready Render Pipelines ready for use free of charge, the High Definition Render Pipeline and the Universal Render Pipeline, HDRP and URP. Unfortunately based on my testing, for the average Indie Dev, who is not using URP for a mobile game, these systems are not ready for usage.

Issues

I know what you are probably saying. “HDRP and URP are built-in ready to go. Why can’t I just use them?” Well it depends on how much you already know or willing to learn about cinematography and lighting. HDRP completely overhauls the existing camera and light systems. HDRP uses Physical Light Units (PLU) for its lighting. These units are based on real-life light measurements, like those you see on light bulb packaging or a photographic light meter. HDRP provides different methods of producing sky within your Unity Project. You can choose which sky type to use for each Volume in your Scene by altering the Sky Type property in the Volume’s Visual Environment override. As great as HDRP is most indies do not the time or want to invest in learning another system when there is still so much other work to do. And this doesn’t even type on the number of professional camera setting that were unlocked. Camera Sensor type, Aperture Shape, and Lens setting can now be adjusted.

lighting

On the other side is URP. While it retaining all the classic setting and variable, it just look visual worst that the default system and have greater limitations. Some of the limitation are as follows:

  • Only a single Directional Light can produce for real-time shadows.
  • Dynamic Batching (Shadows) is in development
  • Single pass shading
  • Limits on the number of light effecting objects.

If you want to look more into the differences between URP and the default Render, You can check out the Unity comparison page here. This will give you the most up-to-date info.

Where Do We Go From Here?

So you are anything like me, you the HDRP system is a like a giving a toddler a $3000 camera and using the URP is trying to make a $50 million feature length film using a cell phone. There is need for something the provides the best of both world. High quality vision without requiring a bachelor’s of arts in filmography to create. This mean take the scriptable renderer pipeline system and extending to meet me needs. I could spend the time learn the HDRP, but with this being the future of Unity, I need to learn it. And not everyone needs AAA level rendering tools

So if you want to learn more about SRP, follow along. I will be adding a link to my git repo once I get it up and going. I think in the next post. I will be building a base test scene for comparisons of Default, URP, and HDRP comparisons.

Posted in Dev Log, Information, Introduction, Tutorials, Unity, Updates, WIP | Tagged , , , , , , | Leave a comment