• entries
59
86
• views
39758

Development of Floatlands game

## Devblog #40: Geometry grass, Random island placement

Geometry grass solution

DOMEN KONESKI

A couple of weeks ago I showed some early samples of rendering grass on the GPU by using geometry shaders. Fresh in-house grass solution allows us faster performance and fuller environment. This video shows you what can be done with the new grass system. It aligns to the terrain, grass color is the same as the vertex color beneath it. It also has full forward shadows and global wind support.

Random island placement
VILI VOLČINI

This past week I was working on random Island placement and many other things. I found a need for Gradient Descent style optimization, to place Islands around each other, with special constraints. First I made a penality function or error function. This function is scalar field, since it returns a real number based on position in the world (and islandRadius you are willing to place).

float PenalityFuncIsland(Vector3 point, float islandRadius) {

float error = 0;

// island-wall-distance
float wd = ClosestDistToWalls(point, islandRadius);

error += Mathf.Max(wd - minimumDistanceBetweenWallAndIsland, 0);

// closest island-island-distance
float d = ClosestDistToAnyIsland(point, islandRadius);

error += Mathf.Max(minimumDistanceBetweenIslands - d, 0f);
error += Mathf.Max(d - maximumDistanceBetweenIslands, 0f);

// difference between 2 closest-island-island distances
float c2 = ClosestDistMaxDist2Islands(point, islandRadius);

error += Mathf.Max(c2, 0f);

return error;
}

In order to minimize the error, I needed to do a gradient of the same function. This is 2D version, since we are placing regular Islands (not Floating Lands). Because it’s 2D gradient, I just needed to calculate 2 derivatives.

Vector3 PenalityFuncIslandGradient(Vector3 point, float radius) {

float dx = PenalityFuncIsland(point + Vector3.right,   radius) - PenalityFuncIsland(point - Vector3.right  , radius);
float dy = PenalityFuncIsland(point + Vector3.forward, radius) - PenalityFuncIsland(point - Vector3.forward, radius);

return new Vector3(dx, 0f, dy);
}

Then I picked random iterPoint in space (initial guess), and then I just walk over world like that, minimizing error (walking down the hill).

while(..) {
..
iterPoint = iterPoint - coefficient * PenalityFuncGradient(iterPoint, radius);
..
}

Obviously this is not the whole story, since I also needed some termination code (knowing when to stop & knowing when a point is good enough or should be discarded). I have drawn the trail of walking through our space, and this is the end result:

ANDREJ KREBS

I have modeled and prepared some more skins for the crystal armour, which the players will be able to collect and use. This week’s newly additions are two more modeled and animated critters for the game, an armadillo and a spider-like robot with a drill.

Painting more icons for the UI
MITO HORVAT

I continue to paint icons for the UI. Slowly finishing with armor sets and moving towards the trash icons. You can see some of the new trash icons in the picture below. Trash items are mostly damaged objects you’ll be able to find in the floatlands universe. From mechanical parts to wooden junk that will lay around on the ground.

Additional UI icons - armor sets and damaged objects

Creating templates for Floatlands Wiki
BLAŽ DROBNIČ, TADEJ VRANEŠIČ

Perhaps you noticed the Gamepedia link on our blog. Well, Gamepedia is hosting Floatlands official Wiki. Since our game is still a work in progress, game changes also have to reflect in the Wiki.

So lately we’ve been updating the main page – correcting the layout, background and logos (featured images are a little outdated and will be replaced soon). We’re also preparing various templates, which will help us add elements to Wiki a lot easier. Tadej and I first put together a template for adding Weapons. The example on the right shows Close Encounter Shotgun and all of its characteristics in the game.

An example of weapon item template on Wiki

Floatlands music: Earth
CHRIS PLEXIDAS

Earth is a darker track, soothing and mysterious that will play during nighttime and dawn time when exploring your unknown surroundings.

## Devblog #39: Submarine, helicopter, armor

Player Panel
DOMEN KONESKI

I’ve implemented a system where adding new types of armor and skins is now easy. All you have to do is add appropriate mesh, name it correctly, create a prefab, set correct layers and add a custom script which resolves everything (from icons, number of skins, to item bonuses armor has).

Items will have shared sprites as well, meaning two different items have a shared sprite, allowing us to create more world items that can drop from various mobs.

junk armor

Loot tables reworked
DOMEN KONSEKI

Items now have a world drop chance. If their drop rate is > 0% then this item can be used in our new loot table system. You can define loot tables via our in-house solution. Next thing that needs to be done is applying loot table callback when lootable events occur: you kill a critter or an enemy, looting crates, mining and resource gathering.

loot tables

Algorithm that selects an item is straightforward. Gather all items and their drop chances in a list, then sort them from lowest to highest item chances and then start evaluating their drops by using Unity’s Random.value.

public static T SelectItem<T>(List<GenericSelectedItem<T>> items)
{
items.Sort();

for (int i = 0; i < items.Count; i++)
if (UnityEngine.Random.value <= items[i].Chances)
return items[i].Item;

return default(T);
}

Reworking DeepEnd and Buzzard
ANDREJ KREBS

I have reworked the models for the Buzzard helicopter and Deepend submarine. We decided to make them a bit more compact and the models were divided, so they will be built in the game by adding pieces of them to a frame.

DeepEnd submarine

Buzzard helicopter

High tier armor sketch and model
ANDREJ KREBS

I also reworked the high tier armor for the player. Based on Mito’s sketches I modeled a metal armor that is ornamented with several crystals. I will add some more versions, that will be available as skins.

metal armor with crystals

Floatlands music: Reveal
DOMEN KONESKI

“Reveal” is one of the first tracks I made for Floatlands. The bouncy modulated toy piano sounds in the beginning represent your clumsy first steps that are easing you into another long and deep synth swelling that feels like the airy lands of the game. A deep breath of awe before you continue your venture through those lands.

## Devblog #38: Player panel, Grass rendering, New biome

Player Panel
DOMEN KONESKI

Player panel is now fully implemented and ready to be taken further. It serves as an indicator how well you are doing. It’s also a place where you manage your gear – from head items, torso and so called ‘plugins’ which increase your stats. You will be able to craft and find these plugins troughout the world.

DOMEN KONESKI

Since the world won’t be that small, we will give players some sense of direction by adding simple compass on top of your screen. We had a map in previous iteration and with testing the game we have seen that noone had been using it. Probably because they weren’t any interesting things on the map, so these things can change troughout the development. Though the main idea remains – for players to know where they are (we are about to add memorable points of interest and floating islands). Also, biomes are the easiest way to tell where you are (snow biome is usually in the north, desert biome is in the south).

GPU Rendered Grass Test
DOMEN KONESKI

We had plenty of concerns about our recent grass renderer that I made. It uses Unity’s DrawMeshInstanced() function over multiple meshes that are spawned troughout the world. The problem with this system isn’t rendering itself, but batching grass meshes that are near you. We’ve used the fastest possible Octree implementation to get nearest grass meshes. These were then put to the renderer, that caused a lot of GC allocation and used alot of CPUs usage if we wanted dense and diverse grass. It also used a lot of drawing calls when we wanted to draw different meshes with different textures at the same time (example is when you stand on the edge of two or three biomes).

Rendering grass on the GPU by using geometry shaders

The last and only solution that I thought of was doing everything on the GPU by using geometry shaders. There are zero to none examples on how these things work in Unity so I started experimenting with it. The shader successfully draws triangles on a list of vertices I provide along with color and normal of the surface beneath. The shader has tweakable settings, from width and height of the grass, shadow intensity, wind strength and more. This is for now only a test and will probably take it further from here, we have to figure out how will grass cope with our art style.

Shader world models for items
DOMEN KONESKI

Item framework system a has new additon which enables us to (re)use world item models on different items. This means we can create more items with less modeling. Example: two torso sets that look the same, but have different stat bonuses on it. More about it in the future blogposts.

Timelapse #6: Companion modeling and rigging
ANDREJ KREBS

Companion will work as a tool and is therefore modeled with relatively lots of polygons, since it will appear close to the players view. The model was then rigged, so I could animate all the moving parts. The model was then animated together with the first person rig for the various actions that will be performed.

Outfits and skins
ANDREJ KREBS

The outfits and armors we are adding to the player character are separate models, that fit over the player character and are connected to the same skeleton as the player. I model and weight paint them with the player model in blender, so I can test it with different animations and see how it works and looks with the player, but I then save it in its own file for import into unity. This way we can keep adding more outfits.

Outfits

Skins are basically new models that represent the same item. Sometimes I copy an existing armor and modify it and other times I just make new armors from scratch for skins, depends on what I’m trying to make. The player and outfit models are then brought back together in Unity and are then remaped to the same skeleton, to work with the animation in the engine.

### Floating islands biome conceptMITO HORVAT

The floating islands above the ground are going to need an overhaul as well. We’re redefining the shapes and sizes plus it will have its own mini biome. The old island models look too boring and simple to recycle them, so we had to come up with something fresh. I drew up various shapes and sizes concepts which were then approved and based on that, I painted this quick concept art.

concept of floating islands biome

### New icons for UI/Inventory screenMITO HORVAT

I’d been given another sidetask by Domen, to paint the new icons for the game UI/Inventory screen. It’s going to take ages to complete, but it is the necessary evil that has to be dealt with.

New icons for UI/Inventory screen

Improving resource helper

World bounds
VILI VOLČINI

Lately I’ve been working on world bounds, which are automatically generated based on bounds size. The intent here is to prevent a player from falling off the world.

World bounds

Charting software
VILI VOLČINI

I was searching for charting software for planning. I did this because it felt like we were somewhat in the dark with planning. I found TeamGantt, their charts allow you to plan tasks on the timeline, and more importantly, make tasks depend on each other – “if Y depends on X, then we must finish X before working on Y”. With this software, we can estimate, how much work there is to do and how much time it will take.

Gantt online charting software

Serene track
CHRIS PLEXIDAS

Every blogpost from now on and until the release date we will release one track of the Official Floatlands Soundtrack a week, but also remixes and experimental tracks. Happy listening and let’s make a start with the track Serene.

Serene is a track that is set out to make you feel the vastness of the scenery in Floatlands. A multitude of layered and swelling Synthesizer patches guide you slowly into the dazzling, dreamlike worlds.

## Devblog #37: New floating islands, RoboDog, Reducing loading times

### Timelapse #5: Digital painting of islands and skiesMITO HORVAT

With the whole world being redesigned, the floating islands that are in current state quickly became obsolete. This is where I come into play. I have painted a concept art with the new world that is currently in the making. A huge surface “island” filled with various biomes we developed in the past. It’s cluttered with man-made assets and huge craters that will explain why there are numerous floating islands in the sky.

The purpose of the concept painting was to try to fit in the new island shapes that will soon be modeled by Andrej. Domen gave me a lot of freedom, so I explored various shapes and sizes that would somehow fit in our game. Since there aren’t many islands on the painting (the game would definitely require more), I drew a bunch of concept sketches from different perspectives so we can handpick the appropriate shapes that will then be modeled. These new islands will have their own special flora, that’s why my next task is to figure our what would fit on these islands.

RoboDog
ANDREJ KREBS

This week I made some more animations for all the functions the companion will need to fulfill. There are now animations for mining, healing and showing the inventory.

After that is started working on the robo-dog and made the animations for him. This will be another robot critter, similar to the sphere robot.

More on Floatlands resources helper
DOMEN KONESKI, TADEJ VRANEŠIČ

Me and Tadej continued with the work on our Item managmement application where you can easily edit every aspect of an item (or even add them). Item data gets stored in a large JSON file which will be loaded by the main game. There will be a lot of settings to play with, from World settings, Item definitions, Item bonuses and qualities, Loot drop tables, Crafting recipes and more. This tool is also a minor step towards modding the game, but more on this later.

VILI VOLČINI

I continued my work on optimizing terrain generation, to be more specific, foliage optimization – spawning grass, bushes etc. Right now the whole scenery takes about 1 minute and 30 seconds to generate. My goal is to reduce that to somewhere around 20 seconds. We don’t want the players with less capable computers to be too influenced by the loading times.

Floatlands interview on IGDB.com
BLAŽ DROBNIČ

You may have noticed that we post Floatlands updates on multiple platforms. One of them is IGDB (indiegame database) and they are introducing their own blog. They were kind enough to feature an interview about Floatlands – the story behind it, our team, goals and much more. Head over there and have a read!

## Devblog #36: UI, Terrain, Companions

Companion
ANDREJ KREBS

I started making the player’s companion based on Mito’s design sketches. This will be a small floating robot, that will follow the player around and be available to him. The companion will mostly stay out of the way, but the player will be able to call it to help him with certain tasks.

Usefulness of a companion

• They will be projecting the inventory, crafting and character UI. This will be a mostly aesthetic task that should add some more immersion.
• Companion will have a limited healing capability. It will be able to heal the player, but its healing capacity will deplete quickly and will take time to recharge.
• It will work as a limited gathering tool. The companion will be able to shoot a mining laser, that will break trees, rocks and mining veins, but it will quickly run out of power and need to recharge. This will give the player the ability to gather resources, even if he finds himself without any gathering tools, but also give him incentive to craft them, because they are much quicker at the task.
• Technically, the companion will be regarded as a tool that will always be available. It is animated in a similar way as the weapons, meaning it has animated interactions with the player character’s first person rig.

More User Interface Changes
DOMEN KONESKI

Player Stats
In the lower right corner you will find various player variables: health points, energy points, companion energy points and jet pack fuel. The panel is intuitive – the most important player stats have colors. If a certain stat is being low, the icon starts flashing (there will be also danger SFX for it later). If you gain certain stat (e.g. you are getting healed or damaged), the text color is changed as well to notify you something is happening to you. More details about a certain player stat:

Player stats
• Health points: this is something you will have to watch out for a lot, like in other games. You will be able to replentish your health in various ways, from consumable items, companion healing and world “healing stations”.
• Energy points: this is the secondary stat to monitor. It depletes when doing certain tasks: mining, jumping/running endlessly, diving in waters, staying in radioactive zones, to name a few. To replentish the energy, you will be able to craft yourself energy batteries or build yourself (or finding one in the world) a charging station.
• Companion energy: as mentioned before, you will be able to use your companion to heal yourself or as low-level resource gathering tool (until you craft yourself a pickaxe or another more advanced tool). Companion energy will deplete and replentish fast and its resource gathering/healing capabilities are basic.
• Jet fuel: it will be used to reach previous unaccessable areas with fast depletion and slow replentish rate. There will be no way to replentish it with consumable items.

Item Bonuses
Since we have player stats now defined and ready to use, there should be an option of improving or degrading them. For this purpose, I’ve implemented item bonus system that’s going to be enabled if you put items in your hotbar or gear slot (gear items won’t work in your hotbar though). A sample item with bonuses:

Item bonuses

Crafting menu has been overhauled to be more intiutive. The design is not yet finished as it requires SDF icons and other minor tweaks. Items are sorted in different categories, from weapons, tools to electornic devices. You can easily see what items are still missing to craft a certain item or if it requires a workbench to craft it (applies for bigger, more advanced items).

Crafting Queue
You can add up to 5 items to your crafting queue where items are being crafted for you. You can cancel certain recipe from being crafted and regain all items needed for this recipe back to your inventory.

Crafting queue

Resource helper

I’ve been creating an in house resource helper, that will reduce time costs of searching and manually changing files containing item definitions and resource definitions. What you see is an XAML app, that parses .json file and gets out values of each item. These values can be manipulated easily through WIP UI interface and later simply replaced by just one click of the button. Soon I’ll be moving to crafting variables, and its manipulation.

Resource & Crafting Helper

As you can see, this is a necessary chore, which allowes even non-coders in the team to easily fix over or under saturated values of variables. This will become specially useful in the testing phase, so we’ll be able to change things on the fly.

Later on, I’m going to implement server connection, which will broader the options what we can do with it. Nothing is sure for now, but a bit deprecated version could be used even for players. That way they know which items/crafting receipts are used in the game, or even for modding support. But as I said before, this is just a thought, we will let time decide other proper use cases for it.

Updating UI icons
MITO HORVAT

Since Domen is extensively reworking the entire UI and the whole inventory system, we’ll have to update the icons as well. The current icon style won’t fit the UI design that is currently being created. So this week was kind of frustrating, simply because its not the simplest task to find the exact type of icon style to fit the UI. After plenty of rejections and reworks this is what I came up with. Some of them will probably get replaced in the near future.

Terrain
VILI VOLČINI

Due to creating a new Floatlands world lately, I had to rework terrain as well.

Optimizations:

• Multithreading of all operations on 2D maps, which includes Perlin noise generation, filtering, map rotation, addition.
• Pool for 1D and 2D arrays, also with thread-safe functions.
• Direct mesh contruction (previously mesh was constructed then modified).
• Caching where possible to avoid Garbage Collection.

New features were also added:

• Signed Distance Field for each Biome, so I can know how far away from biome edge I am (inside & outside).
• Picking quad diagonal based on surface curvature, so that mesh looks more natural.

To demonstrate how it’s done on 2D arrays. Lets say you have a quadcore PC, then we split any workload to 4 parts, so each thread gets it’s own part to work on.

A code example of how it’s done in our project.

 1 2 3 4 5 6 7 8 9 10 11 12 /// N is resolution map /// x is index MapUtils.ForPararell(N, (x) => {       // this closure inside is now running on it's own thread       for (int y = 0; y < N; y++) {           // do operations on 2D arrays as you'd normally do,         // don't share state between threads though, or bad things will happen     } });

This is the current state of terrain, with still some tweaking to go:

## Devblog #35: UI framework, Critters, Foliage

New Inventory Interface Framework
DOMEN KONESKI

I established a new inventory interface framework by writing a new logical layer on top of the current system. By doing this we can now save a lot of coding and designing time. The system is generic which means UI elements are built on the fly and asynchronously. For example, we load sprites from the pool if they already exist in the memory, else we load them asynchronously from the resources – disk. Everything feels seamless now, which was the primary goal in mind while recreating the system.

New logical layer introduced new item manipulation techniques while having your inventory open:

• By hovering over an item, a description panel shows which holds information about your item such as item name, description and quality;
• By dragging one item onto another one, swapping or merging becomes possible;
• If you right click on an item, you can split it if there is enough room in your inventory;
• If you left click while holding left-shift, you can transfer an item instantly to another inventory panel.

Harvesting world resources
DOMEN KONESKI

World resources such as stone veins, metal veins, niter veins, crystals and trees now have a harvesting feature – items (wooden logs, ores) now drop while mining/harvesting the resource which significantly improves resource gathering feature of Floatlands:

Critters
ANDREJ KREBS

We started adding some more critters to the game. These will be harmless small animals and robots that will add some more life to the game. So far I’ve modeled, rigged and animated the hermit crab and the spherical robot. I also added a missing animation to the rabbit.

Foliage
ANDREJ KREBS

I have prepared some undergrowth foliage to make the nature more varied and interesting. They’re made in a similar way the grass, bushes and treetops are made, with alpha transparent textures on planes.

Companions
MITO HORVAT

Roaming around the world can sometimes feel a bit lonely. So we decided to implement a companion to follow you and keep you company as you play. Companion won’t just follow you arround and be useless, they’ll be a valuable asset early in the game. For instance, they’ll help you gather resources with their set of utilities. They’ll even provide the source of light during the night!

As with any concept design task I’m given, I usualy sketch a bunch of ideas on a small collage. In this case we then printed it and everyone in the office picked their 3 favourites.

Based on that decision I combined the elements of the companions everyone picked and came up with the following concept. It’s also important that the companion has elements that you can find in the game, to give it the unique aesthetic look.

## Devblog #34: Riverbanks, Trees, Floating stones

Riverbanks, Trees, Floating stones
DOMEN KONESKI, ANDREJ KREBS

Riverbanks

Riverbanks and (under)water are now filled up with more content such as grass, stones, chorals, ruins, tires and more. I’ve developed a spawning system that allows quick and easy setup for new game objects. You want to spawn a game object only in water at certain depth? You want to spawn trees at certain slope angle and then change its height on the fly? This system now allows you – without coding – to do such things with ease.

ruins on the riverbank

New trees

We decided to rework the tree tops, so I experimented with techniques and stiles, until we got to something we all really liked. This really changes the attitude of the game and creates more immersive but still somewhat abstract feel. The solid blob treetops are now being replaced with bunches of textured alpha transparent planes.

new trees implemented

Floating stone

Lastly, here we have a timelapse video where I modeled a floating stone with a crystal. These stones will float above the crater where the floating islands were raised. I sculpted the basic shape and applied a decimate modifier, after that I added a crystal made in a similar fashion.

New Inventory Interface Framework
DOMEN KONESKI

I’ve been tweaking our new grass renderer a little bit and asking myself if I can increase the grass draw distance without ruining the overall performance. I came up with an unique solution by decreasing the amount of rendered grass, having in mind maximum grass distance and current camera position.

New LOD logic allows subtle decrease of rendered grass meshes over the distance between the player and the final render distance. With this system we can now increase the render distance and allows us to add more content into the world of Floatlands

LOD comparison

Terrain minimums and maximums
VILI VOLČINI

Finally I set out to improve the tools for terrain. It’s not much, but I did a function for local min/max search and slope of terrain. Local maximums should be useful for spawning bigger objects that need visibility. Local minimums could be useful for resources that need to be more hidden from the player.

local min/max search

Critter concepts
MITO HORVAT

To further enhance the world we’ll add tiny critters that will roam around the environment. Critters will be friendly animals or mechanical creatures that will move around specific territories. For example you’ll encounter turtles near the sea/shore line, chickens near villages etc. If you decide to kill the critter, there will be a chance that it will drop loot or crafting materials. Although, what kind of heartless person could possibly kill a tiny cute crab dragging around a tin can house.

critter concepts

## Devblog #33: DeepEnd submarine, Smoother terrain

Dev Stream #05: DeepEnd submarine
ANDREJ KREBS, MITO HORVAT

The underwater scenery in Floatlands will be huge, you will need an efficient way to travel underwater without getting yourself killed and for this reason Deep End submarine comes in handy. Players will be able to craft this submarine. You’ll be able to travel at faster speed underwater and reach the undiscovered depths. You'll even mine precious minerals that only spawn on the ocean floor with the help of the laser mining “drill”, which you’ll craft and attach to the front of your Deepend. We livestreamed the creation of a few Deep End assets – the aforementioned submarine and a small crab:

Crater assets
ANDREJ KREBS

We started making a small biome that will appear in the craters left by the raised islands. In particular these will be harsh toxic areas with a lot of very lucrative resources. So far we have modeled quite some assets for it, based on Mito’s concept art.

Crater assets

Reworked grass & bushes
ANDREJ KREBS

In addition, we have reworked and developed a new look for the grass and bushes. The bushes we added use a similar approach as grass, using planes with alpha cutout textures and a foliage shader to make it react to wind.

new grass & bushes

Smoother terrain
VILI VOLČINI

Domen already did tremendous amount of work on improving the terrain, but I saw some room for improvement. Terrain is based on heightmap/bitmap, but sampling was done without interpolation. So this is why I implemented bicubic interpolation, which gives us smoother terrain and enables us to do derivatives on it (gradient). And from gradient, I can calculate normals or search for a local minimum/maximum through iteration (gradient descent). This is very useful because there is no more need to raycast meshes to get normal sample, which should optimize some terrain generation processes. As a result, here is animation of testing gradient iteration and it works quite good.

### Simple animation scriptDOMEN KONESKI

For the purpose of creating simple animations (basic object rotations and translations) without using any external libraries we have written a script that handles animations by itself without using Unity3D’s animation framework. You can use the script either programmatically or as component. Good thing about having animation system is scalability and room for improvements, because it will be a location based system meaning only those game objects that are in vicinity are going to be animated.

## Devblog #32: Underwater

### Dev stream #04: Underwater sceneryANDREJ KREBS, MITO HORVAT

This time Mito and Andrej joined forces and created Underwater scenery. A proof of concept demonstration of possible new models/elements in the Floatlands Game. From concept art to sculpted models to finished scenery. The visuals of a game can change a lot between concept art development and final Blender 3d model implementation in scenery.

Concept art for the beach and underwater biome
ANDREJ KREBS, MITO HORVAT

We’ve been preparing ideas and concept art for the beach and Underwater biome that we are setting up. It will be one continuous biome that will stretch along the shoreline. We created different assets that will be on various distances from the shoreline, ranging from land that’s away from water, to deep under water. The ocean bottom will be littered with interesting sea flora and even resources you’ll be able to harvest. We explored different moods ranging from dark and gloomy, to bright and lively so we can decide on what we want it to look like.

underwater concept

The beach will be where the players start their game. They will not be able to go out to sea until they level up to a point where they are capable to go far out into the water. This will force them inland to explore and get familiar with the world first. Later the players will be able to explore underwater, find more resources and explore remote islands.

Underwater - Gameplay-wise
DOMEN KONESKI

The Underwater will serve as an interesting and difficult area to access. Since you are a robot, the water will also affect you in a negative way. Although with levels and skill trees planned, higher level players will have a true access to the Underwater. For new players we want them to focus on the Floating islands and the Main land. They need to experience fear of going into the ocean for the first couple of levels. When they level up the world will get bigger for them. Kind of removing a “hidden” barrier and introducing them to the last bit of the world.

We are also thinking about including new vehicles, but that idea is still something we have to figure out first (the impact on the gameplay can be drastic). The purpose of making The Underwater more difficult is for the player to find some huge chunks of resources in the deep water. These are hard to obtain, but can improve late-game gameplay (players will start to explore waters when they are done with Floating islands and the Main land).

Still, The Underwater is still in the concept phase and we really want to make it as fun as we can.

## Devblog #31: New world

### New World - world changes and improvementsDOMEN KONESKI

I was very skeptical about New World and changing the current world of Floatlands. The world included floating islands, debris and details such as clouds. There was a lot of unused space (air) which was not defined gameplay-wise in any way.  It was only a medium for traveling from one island to another, therefore making it a really boring routine to do. We could fix and improve that by doing various things:

• allowing players to build in the air with more air-play,
• creating more debris/objects where players could land in the mid air,
• designing ‘spacecrafts’ with whom you could travel trough the world (good idea, but it is not appopriate lore-wise since we really want to improve on smaller aircrafts such as our little Buzzard),
• creating a ground level terrain which covers entire playable area (which should be large) with terrain.

The decision was obvious, we went with the latter choice (hint was in the previous blogpost). I started working on the so called Main Land island which we will include in Floatlands. Main Land will include all biomes we introduced already and floating islands. It will also have water (sea & rivers), Humans of Floatlands, our beautiful animals, basically everything we already worked on.

I’ve already done a lot towards creating this new ground level of Floatlands. There’s a whole-new procedural terrain generation, color blending between biomes and height differences, whole-new grass renderer using some advanced techniques and our current day/night cycle system.

#### The technical part of the New World

First of all, we generate the height map trough different sets of Perlin noises. We also have a biome map, which represents which biome is at specific position. The best part about this biome map is amount of mathematic principals and algorithms I’ve used to create a procedural biome map so it would look as natural as possible. Have a look:

Biome map texture

Blue represents sea/lakes/rivers, green represents our ‘normal’ biome (take a look at the bottom right, you can clearly see some micro islands will form), yellow-ish is desert and white are mountains with our snow biome. I easly implemented rivers using custom made Growing Trees algorithm. Here is the first test I ever did (it looks like ice cream – don’t mind the colors):

First procedural generation test with color blending

Meanwhile Mito and Andrej remodeled some of our trees, created new concepts for our metal/niter/stone veins (we’ve been using old models and they were really outdated speaking of general design).

New veins sketches

3D models/render of the new concepts

After adding rivers system, new generator rules, grass and other natural objects, the world started to look familiar and appealing.

Current state of the New World.

In conclusion, we have also produced a short video showcasing the current state of the new world (note that floating islands are still missing in the video).

You’re all welcome to join us on Floatlands Discord server and have a chat with us.

## Preparing for SGC - Slovenian Games ConferenceDOMEN KONESKI

We have been preparing for an upcoming conference SGC – Slovenian Game Conference which will be held in Ljubljana, the capital of our beautiful country. Event focuses on development, marketing and bussiness, there is also an indie expo meant for teams to showcase their game in progress: from mobile games to PC and VR. We prepared some T-shirts, posters and 3D printed model of our dreadful sheep which can be yours! You will also have an opportunity to try Floatlands and chat with us. See you there!

promo material for SGC

## 3D printingANDREJ KREBS, VILI VOLČINI

We delved into 3D printing a bit and prepared some animal models from the game for 3D printing and ordered some test prints. So far we’ve prepared and printed a model of the cute little sheep from the game. We’re also thinking about trying to print a rhino and a couple of deer.

3D print renders

## Dev stream #02: Drawing new concepts & gameplayDOMEN KONESKI, MITO HORVAT

Last friday we had our second live stream where Mito showed the process of creating concepts. He drew a couple of weapon sketches and there were even some good weapon ideas from our Twitch viewers that we tried out. In the second part of the stream Domen showcased some early gameplay footage. Check it out!

## New rock conceptsMITO HORVAT

With the environment and the world constantly evolving we have decided that its about time we replace the old nature assets with new and improved ones. So I made a couple of new rocks for each biome, trees are next in line and to spice it all up we’ll add even more nature elements in the game to make it look more alive and less monotone.

new concepts for rocks

## New rock and tree modelsANDREJ KREBS

We started reworking some assets from early development like the normal biome, since some of the assets in those biomes are still there from our prototype stage. So far we’ve modeled some new trees and some rock clutter.

rendered models of new rocks and trees

## Light & scan radar for droneTADEJ VRANEŠIČ

Wohooo, after much testing EGX Showcase build was finally ready. Few details were added on a scanning drone such as a light and a scan radar. Few new avoid manouvers will be added soon, so droid flight wont be repetitive.

## Compiling the gameVILI VOLČINI

This week was slow for me in terms of development. I was mostly smashing my head fixing various bugs. I have fixed some inventory bugs and a couple of fatal crashes. Afterwards I have successfully built the working prototype of Floatlands so we could internally test out the gameplay. I have finished junk shredder aswell which will turn useless items into useful resources.

## Our first live Twitch streamDOMEN KONESKI

Me and Andrej have done our first live stream, explaining some core mechanics of Floatlands while showcasing the EGX Rezzed demo build. Andrej also did a quick tree sculpting for our new biome. Bear with us that this stream was our first one and we were pretty shy doing it. Check it out!

## Better terrain generatorDOMEN KONESKI

I have made some changes to the terrain generator. It allows water to be rendered, hills/mountains are more exposed now allowing us to create different types of terrain with ease.

## Setting up Wiki pagesANDREJ KREBS

Started setting up Floatlands Wiki and worked on the item and main page. I prepared the template for the individual item’s pages and filled out some basic resource pages.

## Trees for swamp biomeANDREJ KREBS

Modeled some trees for the swamp biome and made LOD’s and colliders.

## Creating a game build for development testingTADEJ VRANEŠIČ

This week was mostly about rushing to create a game build for mid-game development testing. A few changes were made in controller menu, but it still needs fine touches. New logic was implemented for drone movement, which is now completely physic based.

## Shotgun close encounter, adding effectsVILI VOLČINI

These past couple of weeks I worked on pimping up Close encounter shotgun, added ricochet particle effects and blood effect. Otherwise, I just spent my time fixing bugs for upcoming demo build.

## Reworking some older ideasMITO HORVAT

Since we’re frantically preparing the demo for the SGC event, there’s really no point of pumping out new concepts and content. Therefore its time to rework some of the older ideas. We’re dumping the wooden fences and completely overhauling the buzzard. The changes wont be extreme, but since we’re constantly evolving I think its appropriate we update the older assets as well.

## Spartan & Roman skins

I started this week by preparing a broken model of the dropship, so the players will be able to blow them up spectacularly and making collider models for the broken pieces. After that I carried on by adding more skins for the player outfits – the latest additions are Spartan and Roman like skins.

Spartan and Roman like skins

I prepared some more cloth outfits and a few junk armour pieces. I also added a camouflage skin for the fine metal armour.

cloth outfits and camouflage skin

## Dropship destruction

I’m still playing around with the dropship NPC, I even did some work on it through the weekend. Here are some key points:

• Separating single script into many separate scripts
• How dropship explodes
• Adding explosion and smoke effects
• Dissolve effect
• Collision avoidance – so dropship doesn’t bump into something

This code may be used for future flying NPCs so it’s not good to spoil this fun by writing bad code. I can show you this clip of dropship destruction (stress testing):

dropship_destruction_lowpoly_floatlands.mp4dropship_destruction_lowpoly_floatlands.mp4

## Clouds & Flow Map

Clouds are now animated/translated troughout the playable area using flowmap. A flowmap is basically a texture filled with various colors. Each pixel describes a movement vector by extracting red and green component of the pixel. The computation looks like this:

We’ve used Teck’s FlowMap Painter to generate nice and smooth flowmaps which can be easily imported in your Unity project. Check his other work aswell.

flowmap

Cloud system is being spawned by a custom pooling solution, the only thing left is to create some weather scenarios – cloudy and less light, rain and storms. We can do this by changing the flowmap (which has more aggresive vector field) in real time.

moving clouds

So we can conclude that a flowmap is a vector field.

This week my time was invested in creating Controls Menu. Finally some UI quirks that will put the whole game together nicely. First thing that comes to mind, when creating Controls Menu is KeyBinding, which lets user choose custom keys with Key Definition – KeyCode pair. We decided not too use Unity default KeyBinder-Input Manager and use our own system with .ini file that has [name, description, category, defaultKey, playerKey] connections, which gives us more freedom from the get-go.

## Swamp biome assets

swamp assets concept

With the swamp biome on the horizon, its time to spice it up and make the biome look distinguished from others. Currently I’m playing around with different color palettes to give the biome a specific atmosphere. Colors combined with all the right assets will create a really unique environment for the player to explore. Swamp biome will be littered with small ponds and tall trees. The flora will be very lush and the combination of huge trees and roots everywhere will create a very dense looking biome. We’ll also include swamp specific critters and animals, but we still have to brainstorm what would fit, any suggestions? Below is a collage of concept sketches of assets that will be added in the biome.

## World map

I’ve been working on a new ‘feature’ for the game – World Map. With this I have removed our initial idea of compass since you can now use your map to guide you troughout the world. The idea was to map out all islands with their positions as an icon but then noticed scaling and precision problems so I took another way of doing a world map.

world map WIP

The idea was to render the visible world to a rendering texture using ortographic (2D) camera. I had alot of problems zooming in, aligning the grid and moving the whole map with the mouse. The end result is great and intuitive.

finished world map

The map texture also has an edge detection algorithm on it for some image effects. Note that render texture can be wiped out when changing the level or programmatically pausing the whole application.

## Clouds everywhere

Skies in the game are empty so I started working on some more details, the first was adding some splats and details to the “cloud” cubemap, the second change is a cloud system with a pooling mechanism. When a cloud prefab hits something (e.g. an island) or is out of bounds it shrinks and is then sent back to pool ready to be reused. The system needs some more prefabs and more movement logic to it – cyclones (read: vector field) anybody?

## More skins

This week I made some more variations of armour sets that will be available as skins. I also added a clothes outfit that will be purely aesthetic. I added some paintwork to the wooden armour, some decorational bolts to the junk armour and made a coat and a hat for the aesthetical set. I also made a new, fine metal armour set, that will be available in a variety of finishes.

more variations of player skins

## Swamp biome concept

I’ve decided to take a short break from all those numerous player armour sketches and to break the monotony I’ve started researching concepts for the next biome. The next in line is a dense swamp biome. Below you can see couple of speedpaintings I did of the enviroment. I’ve also experimented with different color palletes to portray a specifit mood for the biome.

greenish swamp biome concept

Those type of islands will be covered in thick mist and tall and lush trees. Trees will have huge roots poking out of the ground, and long willow tree like branches. On the ground you’ll find swamp biome specific foliage and wildlife, and the landscape will be littered with ponds.

dark swamp biome concept

## Drone movement and destruction

Scouting drone has finally got its smooth flaps movement. It is correlated with its speed – at desired speed flaps are perpendicularly to the line of drone sight, with speed increase they move backwards and with speed decrease they move forward.

speed correlated flaps movement

Previously I showed you an example of scouting drone destruction and how it falls appart into pieces. This time you can check out the mining drone destruction – not as many destructible parts, but still pretty good.

drone destruction

## Dropship movement

I got back to working on dropship movement, since it still needed some smoothness to it. It’s almost finished, so I can show you a bit of a sneak peek. Mostly I worked on tilt movement, PID controllers (Vector3 and Quaternion PID controllers) and cleaning up the code. Remember that this is still a WIP, but here is a short animation showing how it lands on an island.

dropship landing

## Ideas for armour sets & jetpacks

I made a couple of different concept sketches for the armor sets that I mentioned in the previous blog post. From simple wooden planks tied on the player to welded metal plates that form a strong looking armor. Below you can see some of the examples (arms, legs and helmet).

sketches for arms, legs and head armour

This week I mainly focused on the player jetpack. I created various jetpacks that would fit into the game, and then create 3 different “skin” types that will include particle effects individual to each “skin”, and added modular pieces so they will differ from each other.

jetpack variations

## Armour sets

After we got settled into the new offices and extended the weekend, I started preparing the gear and outfit models for the player’s 3rd person model. Mito prepared some sketches for me and I modeled wooden and junk metal armour sets so far. The armour sets are made as separate items the player will be able to equip: Head gear, body armour and leg armour. The jet pack will also be an item that will be equipped. The armour sets will also get more models as skins for the players to collect and wear proudly.

armour sets

## Drone destruction

This week was all about the way enemy drones react when they get hit by a bullet. Running away manouver really gives them a life-like feel. Another cool little quirk we added was, how drones fall apart when they are destroyed. The connections between parent/children parts are being disabled and a small “invisible” explosion is created, so that parts fall away from that destroyed position.

drone destruction

## Logic Gate system

Lately I’ve been improving the Logic Gate system. I wish to make event-driven logic simulation, and it’s quite a hard thing to do. Why did I decide to do this? Because current implementation of logic gate simulation is really bad and I doubt people will be able to play with complicated logic. Unfortunately I can’t show you any pictures yet, but I can explain a little bit about the base components of current state though:

• Pin – can be input, output or bidirectional
• Connection – connects two pins
• Element – element consists of many pins, can think and update state
• Event – events are raised on changes, then processed when it’s time
• ProcessingSystem – this system holds all those components and processes events

The hardest part so far has been building a correct simulation. A simulation that can be modified in real time – adding and removing elements, connecting elements, or pressing hubs on switch.

## Recording voices for NPCs

Currently we are recording and reviewing different ways of incorporating voices for our NPC’s. When it comes to speech, we will not record out every single line, but we will try to bring reactions and emotions across. I have build a homemade vocal booth that will serve for recording the voices and sound-FX.

Sound-FX will be partly recorded and partly created with synthesizers. For recording sounds we will switch between an instrument microphone (SM75) and a condenser microphone (NT1A).

Singal processing is important. Every recording will be enhanced and amplified. You can’t go anywhere without a Pre-Amp and my weapon of choice is a Golden Age Pre 73 MKIII.

Further sound processing will be done with plug-ins that I will demonstrate on a later update.

## Scouting drone

This week was intense, because there was no right way to make a mining drone beautifully stabilize after being hit. Finally we decided to include PID (proportional–integral–derivative) system. Yes, I know it sounds complicated, but all it does is try to minimize error over time and readjust the path. It worked like a charm, actually my new favorite thing about the game is hitting drones and watching them stabilize. The second thing I was playing with this week was “scout” drone, which can move its flaps now. Only a few more steps and a buzzing drone army will be ready!

Flaps movement on scouting drone

## Settings

Floatlands will have predetermined graphics/game settings values (lets call them Low, Medium and High graphics) and of course a custom one. I have created external files for each graphics quality settings that are loaded at the start of the program with our own parsing algorithm.

The settings values look like this and can be changed without recompiling (for now a game restart is required):

To read values from the file (the values are stored in the memory in an array list) we simply call the following API calls which are reachable anywhere in the game code:

## Junk recycler device

We had this idea of including a Junk recycler device, which recycles junk items the player will find lying around and turns them into condensed recycled junk pellets that can be used in crafting. I relatively quickly prepared a model of this device for game implementation, then I also revised item descriptions and fleshed them out a bit to be a bit more interesting and helpful. I am now looking over and organizing the crafting recipes, so we can later balance the crafting more easily.

junk recycler

## Dropship

I decided to work a bit on the dropship and here’s a picture of the current state. Turrets already aim at you, motor particle effects are also in place, landing gear can open and retract, LODs are working. There’s still lots of work needed for it to become fully functional. I need to implement quadcopter-like physics, path planning, some realistic behavior and enemies dropping out of ship when landing. I would like to do it as soon as possible to show you some more goodies!

aiming turret & dropship gizmos

## Skins

In the following weeks, we’ll add various modular armour pieces (skins) so the player will be able to personalize their character. There will be several different versions of the each possible armour piece (skin). Those will be divided into 4 categories: torso, limbs, helmet and jetpack. I’m still in the process of figuring out what would fit the best, but below you can see some quick and rough concept sketches.

modular armour pieces

## UI: character menu & build mode panel

Continuing with the UI, I have decided to implement a brand new character menu that includes all the player stats, player model and item slots for your dressing needs (will be implemented in the future). You can rotate your player model with the script that is provided below.

I have also changed the looks of the Build mode to make it as simple as possible.

New build mode outlook

## Generic mouse swipe script

It is time to give away some code for those in need of a solution when you want to do something with the mouse gestures, in this case a mouse “swipe” gesture, e.g. you wish to rotate your character model in the character menu with your mouse. The script provided can be used in your projects, free of charge, and can handle multiple things:

• Unity Event when moving the mouse in X direction only
• Unity Event when moving the mouse in Y direction only
• Unity Event when moving the mouse in XY direction
• Knowing if the mouse is “down” on the selected raycastable panel

To make things work create a UI panel, hide the image (do not disable the component), select the image as raycastable and add this script. What you have to do now is to populate your Unity events with your custom function calls. Do not forget when calling your function via this script the function getting called must take one (for X or Y only events) or two (XY event) arguments type of float. The last thing is to mark the event as dynamic, see image below.

mouse swipe script

using UnityEngine;

using UnityEngine.Events;

using UnityEngine.EventSystems;

namespace Floatlands.UI
{
public class MouseSwiper : MonoBehaviour, IPointerDownHandler, IPointerUpHandler
{
public bool isHoldingDown;
public Vector2 totalDeltaVector;
public Vector2 deltaVector;
private Vector2 prevVector;

private Vector2 startPosition;
private PointerEventData eventData;

[SerializeField]
public SwipeSingleEvent OnSwipeXEvent;
[SerializeField]
public SwipeSingleEvent OnSwipeYEvent;
[SerializeField]
public SwipeDoubleEvent OnSwipeXYEvent;

public void OnPointerDown(PointerEventData eventData)
{
isHoldingDown = true;
startPosition = eventData.pressPosition;
prevVector = startPosition;
this.eventData = eventData;
}

public void OnPointerUp(PointerEventData eventData)
{
isHoldingDown = false;
}

void Update()
{
if (isHoldingDown)
{
Vector2 currentPosition = this.eventData.position;
totalDeltaVector = currentPosition - startPosition;

deltaVector = currentPosition - prevVector;

prevVector = currentPosition;

OnSwipe((int)deltaVector.x, (int)deltaVector.y);
}
else
{
totalDeltaVector = Vector2.zero;
}
}

void OnSwipe(int deltaX, int deltaY)
{
if (OnSwipeXEvent != null)
OnSwipeXEvent.Invoke(deltaX);
if (OnSwipeYEvent != null)
OnSwipeYEvent.Invoke(deltaY);
if (OnSwipeXYEvent != null)
OnSwipeXYEvent.Invoke(deltaX, deltaY);
}
}

[System.Serializable]
public class SwipeSingleEvent : UnityEvent<int> { }
[System.Serializable]
public class SwipeDoubleEvent : UnityEvent<int, int> { }
}

## Outfits and speakers

Mito created some outfits concepts for “techies” that would distinguish them from the “farmers”. So this week I was occupied with modeling and weight painting the new outfits. They put more metal pieces on themselves as armour is made of junk pieces of sheet metal.

various “techies” outfits

After that I modeled propaganda speakers, which will appear in the world. The speakers will emit propaganda messages and other sounds.

propaganda speakers

## Extra robot concepts

Currently there is only one type of enemy robots. Simple humanoid machines that wield various weapon types (from snipers to grenadiers etc), they roam around and attack anything in sight. In the near future we’ll add sturdy, hard to destroy robots that will challenge the player. In addition, we’ll also add small spider like robots that will be quick and unforgiving with their melee attacks. Those enemies will surely test your aim. You can see the first glimpse of concept sketches below.

a different kind of enemy robots

## Mining drone in action

This week I’ve been playing around with drones, particularly “mining” drone which Andrej beautifully modeled. Mining drone will represent a fine touch to resource collecting. Upon destruction its loot will be dropped and ready for collection, which allows the player to gather resources faster. Tweaking its avoidance system makes it fly smootly regardless of any obstacles on its path. Finishing touches were also made for the drill rotation. More nuts and bolts next week.

mining drone in action

## NPC battles

Humans are already alive and fighting each other (Farmers vs. Techies). They have 3 different weapons for now: fists, single shot pistol and revolver. They can also melee attack with pistols!

NPCs fighting

I also just started working on ‘Hint nodes’, which will have different geometric shapes. Those hint nodes will provide information about the world – safe spots, danger spots, sniper spots and so on.

basic gizmos

## Time for a new video? Sure is!

It’s time to produce a new dev update in video format, introducing new Electricity system, Humans of Floatlands, Vendors and world improvements. Game is shaping up nicely and becoming more alive. Stay tuned for more stuff!

## UI changes

I have made a new UI redesign phase, combining similiar UI elements together and changing texts and images to so-called Signed Distance Field system. The only problem right now with the UI is the brightness of the environment – everything seems so bright in the middle of the day so it covers the UI and becomes invisible – to solve this problem I have to create a system that calculates overall brightness of the screen (by getting some of pixel colors and averaging the sum of color components) and change the color of UI elements using the calculated value.

Changed and simplified UI with a problem of bright environemnt, system in the works!

## Scouting and mining drones concept

I have decided to completely rework the drones in the game, since I wasnt really pleased with their look. Domen agreed with the revamp idea so I began sketching a couple of variations that would fit the game more. While I was doodling, I figured out it would be cool if we’d implement two different drones. The first one would be a scouting drone, simple looking aerial drone that would just fly around and stop occasionally to “scan” the area. The second one would be a mining drone, but instead of scouting the area, it would descend to the ground level and use the drill to mine rocks. Below you can see the concept sketches.

Scouting & mining drones concept

Since Vili is close to finishing the “farmers” AI we will soon implement the “techies” faction which means I’ll be responsible for creating outfits that would distinguish them from the “farmers”. You can see some of the concept sketches in previous blog posts. Domen requested more outfit variations and some helmets to characterize them more.

Techies outfit concept

## New drone models

I finished up the player 3rd person character from the previous week and tested it. After that I imported and tested the animations for the enemy NPC robots and added the IK systems to the assault droid NPC, so Vili can later add them to the game. The droids now have similar IK features to the player’s 3rd person character like aiming, grounding and recoil. I also modeled two of the Mito’s new drone designs that will roam arround the islands.

Scouting & mining drones

## NPC interactions

A lot of work has already been done on Humans of Floatlands aspect of the game – NPCs. They already feel enjoyable and fun (see the latest dev video update). They can interact and react to the world and others NPCs as well.

For more curious readers, those are internal details of current Behavior Tree and Animator. (Caution, images are extra large)

## Bug Tracking

We are close to delivering a working prototype so it is good to have a bug tracking system in place. Uptil now we were writting down bugs on paper which was okay. Now when the game is quite a large sandbox place a lot of bugs can occur so I started looking for a solid bug tracking software that is:

• Easy to use interface, pictures of bugs supported
• Visually appealing
• Free

We decided to go with LeanTesting

Some of the bugs already live on bug tracking software!

## Vendors

We are currently adding NPCs that are going to be roaming around the villages in Floatlands. They will be of a friendly kind until you attack them for (loot?) no reason at all. One of those NPCs is going to be a Vendor which buys or sells goods that can be obtainable in the world of Floatlands – either useless junk or rarities that cost alot. To buy goodies you will have to gather fiat which is measured in, you guessed it, Bolts!

Techies vendor hut

Basic UI implementation and interaction

## Junk items & new shotgun

It’s been a while since the last post and quite a lot has been done lately. We have made a collection of junk items that will be found throughout the world, like empty cans, bottles, lanterns, a broken cog etc. These items will be processed into other resources that will be used in crafting.

Junk items

The tools that players will use were revamped, we also tweaked some of their animations. Mito’s new designs made them more consistent with our overall look. They now look more like they were crafted out of scrap material. We have also redesigned the pump action shotgun with Mito’s new concept and I created the new animations for it.

Human NPCs & Robot player character

I made more animations for the human NPCs, like crouching, fighting with their fists and some reaction animations, like waving and pointing, to give their actions more variety and give them more options in combat situations. I then modeled some more elements for the electric system, that will allow players to make more complex systems.

Human fighting animation  &  New robot player character

## NPCs relationship & last seen position

I have improved NPCs ‘Relationship’ object, which is kind of IActors memory about other IActors in game. Still work in progress but it’s getting closer to finish. The reason I’m doing this memory improvement is because our current robots ingame (humanoid robots) are not clever and we are adding humanoids, which I want them to be more clever.

public class Relationship : IEquatable {

public IActor actor;

public RelationshipType type; // Enemy, Predator, Neutral, Prey, Friend, Threatening
public RelationshipReason reason; // reason for this relationship to exist (maybe damage)
public float timeSinceLastSeen;
public float maximumMemoryTime; // how long does this relationship last in memory, if NPC doesn't see actor

//last seen variables to make NPCs more realistic
public Vector3 positionLastSeen;
public Vector3 velocityLastSeen;
public Vector3 directionLastSeen;

public float threatLevel = 0f;
...

This was a sneak peak into Relationship code, it also includes prediction code and other helpers. The next thing I want to show you is Gizmos of selected sheep – the Gizmos show ‘lastSeen’ data. Now, if task like LookAt gets called in Behavior Tree, then the NPC will look at last seen position. This is also a work in progress though, since last seen position can be outdated, and NPC can be somewhere else completely.

Checking last seen position

## Tutorial with hints

For this assignment, I took a bit of a different approach. Instead of the usual PC and tablet combo, I’ve decided to hand draw the pieces, import them and edit in Adobe Illustrator and Adobe Photoshop. We are creating a “tutorial” system which will help out players when they first play the game. Hints will pop up with instructional text and a cartoony drawing of the protagonist. Below you can see some of the examples.

Drawings for tutorial

Here is how Domen implemented his Hint system, triggering when interacting with certain world elements, Workbench in this case.

Workbench hints

[color=#000000]

# [font=arial]Procedural grass level of detail[/font]

[/color]
[color=#000000]

## [font=arial]The world outlook from farther distance kind of felt boring and dull. Some games just increase the fog level just to hide this dullness. There was zero detail in the distance so I started increasing draw distance for trees and rocks. I have created a new simple mesh (actually a rectangle with two triangles) and populated it with a simple grass cutout texture. I proceeded with creating procedural LODs, placing both simple mesh and complex in one spot, baking the same ones together in patches and adding UnityaEUR(TM)s LODGroup on top of that. The distance is busy now which enables us to decrease the fog level. LOD levels (for world objects) and other settings (such as shadows) are going to be tweakable via config file.[/font]

[/color]

[font=arial][color=#444444]

[/color][/font]

[color=#000000]

[/color]
[color=#000000]

## [font=arial]I have also managed to create a color variety on the terrain itself by writing a custom terrain surface shader. The shader enables us to input three different colors aEUR" one for the lowest points of the island, second one is meant for middle/ground heights and the last one is meant for hills and mountain tops. To interpolate colors smoothly I have transformed the colors from RGB to HSL space and used this code bit for interpolation (_Middle is a float [0, 1] that sets the aEURoemiddle groundaEUR? height):[/font]

[/color]float3 interpolatedHSL = lerp(bottomHSL, middleHSL, h / _Middle) * step(h, _Middle);interpolatedHSL += lerp(middleHSL, topHSL, (h - _Middle) / (1 - _Middle)) * step(_Middle, h); fixed4 tintColor = fixed4(hsl2rgb(interpolatedHSL), 1);

[color=#000000]

## [font=arial][/font]

[/color]

[font=arial][color=#444444]

[/color][/font]

[color=#000000]

# [font=arial]Drone[/font]

[/color]
[color=#000000]

## [font=arial]Me and Andrej added a new kind of non-hostile NPCs to the world that actually have no purpose as regards to gameplay aEUR" they will only make skies more busy and immersive. They are called Prospecting drones. They will fly around the island, stopping at the rocks and try to mine them with their laser. Yes, you can destroy and scrap them, but why would you do that to these beautiful robot creatures?[/font]

[/color]

[font=arial][color=#444444]

### Non-hostile Prospecting drone in action

[/color][/font]

[font=arial][color=#000000]

[/color][/font]

[color=#000000]

# [font=arial]Randomized human NPCs[/font]

[/color]
[color=#000000]

## [font=arial]Since there will be a lot of NPCs that will populate various settlements, we decided to make a system that randomizes the characters by using shape keys (blend shapes / morph targets, whatever your software calls itaEUR|) on the face to change different facial features of the character and effectively makes each character have a unique face. Of course the character will also have a variety of different outfits.[/font]

[/color]

[font=arial][color=#444444]

[/color][/font]

[color=#000000]

[/color]

[color=#000000]

[/color]
[color=#000000]

## [font=arial]Every device that we have in our electricity starter pack needs proper implementation. Previously I worked on repair and charging stations, but this week I focused on bringing functionality to light lamps, actually two types of those lamps aEUR" wall lamp & standing lamp. A quick preview in the picture below:[/font]

[/color]

[font=arial][color=#444444]

[/color][/font]

[color=#000000]

[/color]

[color=#000000]

# [font=arial]Icons for electric devices[/font]

[/color]
[color=#000000]

## [font=arial]We are slowly finishing up the electricity which will be an exciting new addition to enhance the gameplay. The newly added electric devices will need icons to display them in the players HUD. Below you can see a set of new icons, including bolts which will have a special use in the game.[/font]

[/color]

[font=arial][color=#444444]

### Icons for electric devices, wheat and corn.

[/color][/font]

[font=arial][color=#000000]

[/color][/font]

[font=arial]

[/font]

[color=#000000]

# [font=arial]The Techies[/font]

[/color]
[color=#000000]

## [font=arial]I started implementing the second stage of humans of Floatlands aEUR" the Techies clan. In our previous updates we presented the Farmers clan, or rather buildings and props that they will be using. aEUR~The TechiesaEUR(TM) are innovative people that want to simplify their life with the aid of machines and technology. After the split they found shelter in old factories which they rebuilt and used as a center of their future settlement.[/font]

[/color]

[font=arial][color=#000000]

[/color][/font]

[color=#000000]

[/color]

# [font=arial][color=#000000]Continuing with dungeons[/color][/font]

[color=#000000]

## [font=arial]I also made refinements to the dungeon system by adding itaEUR(TM)s own pathfinding using Unity3DaEUR(TM)s new NavMesh system that was introduced in the latest stable build (5.6.) aEUR" it allows you to bake and manipulate NavMeshes in realtime. The bad thing about the system is lack of good documentation so I had to figure everything out by trial and error.[/font]

[/color]

Procedurally generated navmesh, including obstacles

[color=#000000]

[/color]

[color=#000000]

[/color]

[color=#000000]

[/color]

[color=#000000]

[/color]

[color=#000000]

[/color]

[color=#000000]

[/color]

[color=#000000]

[/color]

[color=#000000]

[/color]

# [font=arial]Repair station implemented[/font]

[color=#000000]

## [font=arial]Lots of electrical devices models needed implementation so I focused on the repair station (a device which heals a player). The animations for repair station work very smoothly aEUR" if you are hurt, you just need to step on it and the device starts repairing you. Remember, the station needs to be properly powered up by electricity or else itaEUR(TM)s going to do a poor job. This is a short preview of how it works.[/font]

[/color]

I also added critters to the game aEUR" they were a bit difficult to implement, because they are so tiny and itaEUR(TM)s hard to navigate around an island. For now, critters in the game include rabbits and chickens. Rabbits will hop around on the grass and run away from scary things. Chickens will mostly be eating and showing off in front of you.

[font=arial][color=#444444]

### Rabbit and chicken

[/color][/font]

[font=arial][color=#000000]

[/color][/font]

[color=#000000]

[/color]

# [font=arial]Chris Plexidas joins our team[/font]

[color=#000000][font=arial]

[/font][/color]

# [font=arial]Farmers village placement[/font]

## [color=#000000][font=arial]WeaEUR(TM)ve been working on the Farmers village placement aEUR" placing various objects such as buildings, props and loot on an island. [/font][font='Open Sans']This was already showcased in our previous [/font][/color][font=arial][color=#000000]Youtube dev video[/color][color=#000000]. [/color][/font]

[color=#000000][font=arial]To spice things up IaEUR(TM)ve also added various props for villages, to enhance the whole aspect of having a primitive type of friendly NPCs. An example of this are harvestable corn, destroyable barrels, interactable squeaky doors and cozy firepit.[/font][/color][color=#000000]

## [font='Open Sans'] The same will follow with our second aEURoeclanaEUR? of people, called Techies. They will also have the same set of buildings and props but with a twist.[/font]

[/color]

[font=arial][color=#444444]

[/color][/font]

# [font=arial]Dungeons are coming to life [/font]

## [font=arial]ItaEUR(TM)s been a while since I started working on the dungeon system. You can check out what will the dungeon be by reading our Devblog 33 which explains its concept. In it we mention the first steps on how the dungeon generator will actually work aEUR" creating rooms and corridors then connecting them together. The first dungeon style will be a cave-like dungeon. Andrej created new cell objects which can tile correctly. The result is nothing special but itaEUR(TM)s a foundation for everything else.[/font]

[font=arial][color=#444444]

[/color][/font]

## [font=arial]The next thing was to add vegetation and set the overall looks for caves. I started thinking and researching about vegetation in caves (I know, it is not so natural to spot patches of grass in caves, but we really want to include life into every aspect of the game). IaEUR(TM)ve made some rules where and how grass/moss and vines can spawn. I added some rocks and dripstones as well and lastly the puddle of water has also been added.[/font]

[font=arial][color=#444444]

### Overall looks of a cave system

[/color][/font]

[font=arial][color=#444444]

[/color][/font]

# [font=arial]Techies buildings & new cave entrances [/font]

[color=#000000]

## [font=arial]I finished the corn I started working on last week, which has already been added to the farmer villages. The corn cobs can be picked from the plants and the plants react to the wind like other plants so far. I also made some new dungeon entrances that will lead into the proceduraly generated dungeons.[/font]

[/color]

[font=arial][color=#444444]

[/color][/font]

## [font=arial]After that I started working on the Techies settlement buildings. So far IaEUR(TM)ve made the greenhouse, where the techies will grow their food, and one of the houses.[/font]

[font=arial][color=#444444]

### Techies residence and greenhouse

[/color][/font]

I am now continuing the work on devices that will plug into the electric system, and I made an animated healing station, that will activate and start fixing playeraEUR(TM)s robot character when he steps in it.

# [font=arial]Electricity update [/font]

## [font=arial]IaEUR(TM)ve been refining electric system, fixing bugs, and adding new components. ItaEUR(TM)s possible to switch buttons now and add fuel to the generator. A lot of electrical consumers will be added and their style will also be refined. Here is first glimpse of generator, battery, switches, lights and some wiring. The system will be flexible enough to add additional elements on the go, we will just need to brainstorm an idea, model and code the new element and thats it. We think electric system will be a very fun feature of Floatlands.[/font]

[font=arial][color=#444444]

[/color][/font]

# [font=arial]Techies buildings concept [/font]

[color=#000000]

## [font=arial]Below you can see some of the concept sketches for the Techies buildings that you will find around the world. They are constructed and carefuly fused together mostly from scrap materials they could gather. Strong metal foundations and steel plated walls are often reinforced with thick layers of metal plates to protect the inhabitants from the outside world.[/font]

[/color]

[font=arial][color=#444444]

[/color][/font]

# [font=arial]Humans of Floatlands in action[/font]

## [font=arial]IaEUR(TM)ve started working on Humans of Floatlands aspect of the game aEUR" friendly zones on the islands that provide you with loot, quests, vendors and perhaps a little bit of action. Andrej did an excellent job modeling aEUR~FarmersaEUR(TM) buildings and my job was implementing them in the world.[/font]

[font=arial][color=#444444]Farmer shop[/color][/font]

# [font=arial]Farmer props[/font]

## [font=arial]Continuing with the humans of Floatlands, I started to work on props that will spawn in the farming villages to add detail and make it feel more genuine. Haystacks, bales of hay, wooden barrels and carts are just some of the objects that you will find lying arround on a farm and will be placed around the proceduraly generated villages by Domen.[/font]

[font=arial][color=#444444]

[/color][/font]

# [font=arial]Assets for electric system[/font]

## [font=arial]I also made some assets for the electric system that Vili is implementing. These are various devices that generate, use or store electric power and connect together with cables, so I had to make connecting ports that will be placed on the devices and have wires plugged into them.[/font]

[font=arial][color=#444444]

[/color][/font]

# [font=arial]Electric system[/font]

## [font=arial]There is a global graph where node represents an electric device (battery, generator, light.. ) and a link (cable connection). Links are bidirectional. When you modify the electric system (add a connection or a new device), graph gets rebuilt. With that I mean global graph is split into groups. Each group represents a single electric system.Every device has a battery aEUR" there are two kinds of batteries: external and internal. External batteries give up energy, internal are parasitic and they keep it for themselves (they donaEUR(TM)t send it back to the network). Generators and storages have external batteries, electricity users have internal battery. Electric nodes/devices also have a transfer rate, which tells you how much energy they can transfer in one second. An example of what can be done so far with a battery, generator, 4-switch and a light:[/font]

ItaEUR(TM)s also easy to connect things in build mode:

1. Select first connector (cable is blue)
2. Select second connector and thataEUR(TM)s it (cable is green)

[font=arial][color=#444444]

[/color][/font]

# [font=arial]Concept for electricity elements[/font]

## [font=arial]Vili is currently working on electricity which we will add to the game very soon. He asked me and Andrej to come up with some concept sketches and some prototype 3D models. Since the electricity is still work in progress these presented elements will most likely be just placeholders and will be a subject to change in the near future. Players will be able to use electricity to illuminate the shelters and protect them with turrets. YouaEUR(TM)ll even be able to rejuvenate yourself with some of the components. Below you can see some of the electricity elements, from various hubs and switches to batteries and fuel generators. These will all be connectable with the cables system that is already in place.[/font]

[font=arial][color=#444444]

[/color][/font]

# [font=arial]Furnace[/font]

## We have already added furnaces in the early stages of the development. Check them out HERE. They were obsolete and their design didnaEUR(TM)t fit properly with other objects in the game, so we managed to recreate a furnace model with revamped background functionality. We also added new particles for the furnace as seen below:

[/font]

[font=arial][color=#444444]

[/color][/font]

# [font=arial]Item stacking[/font]

[color=#000000]

## [font=arial]WeaEUR(TM)ve seen a performance drop whenever you wanted to drop a lot of items out of your inventory. To optimize this IaEUR(TM)ve created a world item stacking, this means that nearby items with the same ID get merged. To add a sugar on top of it, IaEUR(TM)ve managed to increase the size of a stack aEUR" the bigger the stack, the bigger a certain item is in the game:[/font]

[/color]

[font=arial][color=#444444]

[/color][/font]

# [font=arial]ELECTRICITY[/font]

## [font=arial][color=#000000]We have decided to rewamp the electric system used in the game aEUR" you can have a look at our initial electricity implementation with generators [/color][color=#000000]HERE[/color][color=#000000]. Our new direction is to have cables and the whole system will be more dynamic as well. I was mostly designing & planning though, so not a lot of programming was done. Still, I managed to finish up the cable connectivity aEUR" the cable is done with cylinder bending shader (wrote by aEUR~MetapyziksaEUR(TM)), bending is done with cubic bezier (4 control point).[/color][/font]

[font=arial][color=#444444]

[/color][/font]

[color=#000000]

## [font=arial]I also added capsule colliders through the existing cables, they are needed because cables will be destroyable (either in build menu or by a player raiding). Still lots of work awaits though, I have drawn some technical sketches of electronic devices, those sketches will then be retouched by Mito and finally 3D modelled by Andrej.[/font]

[/color]

[font=arial][color=#444444]

[/color][/font]

# [font=arial]Villager buildings[/font]

[color=#000000]

## [font=arial]In preparation for adding humans to Floatlands I started modeling buildings for their villages. So far I made two barns, water tower, granary and a central firepit.[/font]

[/color]

[font=arial][color=#444444]

### Villager buildings: barn 1, water tower, barn 2, granary

[/color][/font]

[font=arial][color=#444444]

[/color][/font]

[color=#000000]

## [font=arial]When making models for a game we also need to make LOD models (levels of detail) which get swapped when the player is further away to save system resources and so the world can be fuller. I start by making the most detailed model first and then copy it and start removing details in two ways aEUR" by hand and by using modifiers, depends on what works best for the given model.[/font]

[/color]

[font=arial][color=#444444]

[/color][/font]

[color=#000000]

[/color]

# [font=arial]Night-time improvements[/font]

## [font=arial]I did a lot of tweaks on how the night actually looks. Before the lighting was dull was dull and weird and now the night has its own source of volumetric light aEUR" moon. We find it much better this way and sometimes you just have to stop and admire the beautiful scenery.[/font]

[font=arial][color=#444444]

[/color][/font]

## [font=arial]To give you a more clear look of how drastically lighting and colors of the scenery change during a one day-night cycle, here is a quick day-night cycle preview:[/font]

We have also implemented fireflies and dust particles that will spawn randomly around the player to create a more immersive world. Naturally fireflies will also serve as some kind of small source of light.

:

# [font=arial]Rabbit ragdoll physics[/font]

## [font=arial]After I import an animated or at least rigged character I put it on my workbench scene and start with the default ragdoll tool which generates the basic ragdoll. This tool is primariliy intended for humanoid characters, but most vertebrates have similar bone structures so it can easily be modified. The tool opens a window, where you simply drag and drop the coresponding bones and it adds rigidbody, character joint and a collider to each of the added bones. This can be done manualy for strange creatures, but I find that the tool saves quite a lot of time and I just tweak the character joints settings and colliders so that it behaves like I want the creatureaEUR(TM)s anatomy to behave. Afterwards I add some extra joints and colliders to parts of the creatures that arenaEUR(TM)t covered in the tool, like the floppy ears of a rabbit in this case. I test the ragdoll continuosly during the entire process, by just running the runtime. The ragdoll is later enabled by a script in the game.[/font]

[font=arial][color=#444444]

[/color][/font]

website