Seeing as I’ve got time of from work, there has been a lot of progress on Atmocity lately. Most of it has been directed towards the upcoming demo and early QA test build, but there’s been a lot of overall progress.
I’ve finally gotten around to start working on sounds properly. There is now a selection of ambient sounds coming from buildings when you hover the camera nearby. There will also be an addition of sounds played when buildings are clicked, but this will be added later on. I’ve yet to get work started on music. I’ve only made a few concepts, but nothing that has really hit me as a perfect fit for the game. The work is ongoing though, and I expect to find the right fit soon.
The demo features about half of all the launch day buildings. Two residential and commercial tiers, the low industrial tier, all parks, all plazas, most production buildings etc. This means that I’ve been able to put a lot of work into the underlying building code and I now consider it pretty much done. It’s stable and efficient and as far as I’ve been able to tell, bug free. Adding additional buildings will therefore, mostly be a matter of modelling, texturing and rigging them in Unity. That means that building production should pick up pace significantly and I hope to finish this process completely by the end of September.
The demo also features a barebones version of the resource trading interface. You will be able to buy and sell resources, and prices will adapt to the under/over supply of resources. What’s missing now is a “price pull” feature that means a lower price on one food resource will also affect the price on the other three. Same goes for building materials. This feature will be implemented later on, as it will also depend a bit on the global economy and how prices of goods are determines in general.
As I’ve worked and tested the game more, one thing that has become apparent is the need to quickly review your city to find areas that are not performing well. To make this possible for players, I’ve implemented an efficiency visualization tool. This fetches the efficiency of each building and color codes buildings from red to green. This way poorly functioning neighborhoods will be seen quite easily and the player can start working towards fixing issues.
Probably greatest progress visually (aside from there now being more buildings) has been on the user interface side of things. I’ve managed to more or less finalize UI design. A lot of information to the player will be conveyed via icons rather than text. The hope is that icons will be self explanatory enough and that the player will be able to link for example the icon of a missing consumable to the same icon in the building menu to quickly find their way around the interface. There is now also a main menu and a loading screen. Currently it is rather barebones, but it allows for further additions as they are needed.
There should be a pretty comprehensive update for the month of august as well! Stay tuned.
/ Dispersing Minds
First off, the development of Atmocity is progressing quite well. I’m done with slightly more than 1/3 of all buildings. I’ve focused a bit extra on visual consistence within the different tiers of residential and commercial zones. Although I will return to working on all buildings further down the line, I think they are looking quite good already:
Aside from tiered buildings, I’ve also finished a hospital building. The texture of which I will change slightly in the upcoming week. Aside from that it too is finished for now:
This week, however, I have mostly focused on code. This week and last I’ve changed the entire building placement sequence to better fit the upcoming changes in the UI. Before, placing buildings required first selecting a location, then selecting the building to place. With the ever growing list of buildings, the UI has become too cramped to fit all the different types of buildings. So in order to fit all buildings into the UI, I will need to have a beefier UI with scrolling. So I’ve changed the sequence to selecting building first, then placing it. To display what side of a cube is currently selected, a hologram of the selected building is displayed. With these changed I’ve also made it possible to speed place buildings. This feature is especially intended for placement of zones and will make placement less tedious.
The majority of code work has been spent on full implementation of the resource management system. Prior to this weeks work, buildings would check their surroundings for buildings they like and dislike. If there’s a “bad” building nearby, a building will incur a penalty. For example, residents don’t like living next to factories, so a residential zone placed next to an industrial zone will not house as many residents. This would also affect how much tax a building generates. The existence of power or water, for example, was not of any concern though.
Now, buildings are not only producers of tax, or citizens, but also consumers. This means that the resource management system comes full circle. Not only do buildings need to be placed intelligently in your city as to not incur penalties, they also need to be given the necessary resources to produce. This means that residential zones that have no power or water, or lack food resources, will not grow and will pay less tax. Farms that have no water cannot produce food. Simply put, without input, no output.
This also means that the development of the games is moving into a more obscure phase. Not as much will be shown, because I will mostly be concerned with improving the game and gameplay, along with interfaces, rather than adding visible content. An interesting phase nonetheless. 🙂
First off, the webpage hasn’t been updated in quite a while, but that will improve from now on. About a week ago, I updated Brink of Extinction to the new version, called Blitz Ant. This version of the game adds several new features and fixes a bunch of issues, namely:
Shadow system has been optimized and settings for it tweaked.
FXAA removed in favor of TSAA. This means that the aliasing has been minimized even on low resolution scaling. TSAA is more performance heavy than FXAA, but the added performance cost is offset by allowing lower resolution scales to get the same or better graphical fidelity.
Loading times between levels lowered. Music is compressed into memory in the background instead of on load and SFX uses faster compression.
Improved pooling system and waypoint path generation to allow for pool expansion and drawing from a single pool. This dramatically improves the loading times, in particular it lowers the load of creating many objects on start (noticeable by a lot of stuttering when level is first loaded in).
Optimized UI code.
Some adjustments in large scenes to lower the number of objects and their FPS impact.
– Features and balancing
– General changes
Difficulty ramp on campaign changed. Earlier levels are now a bit easier, later levels slightly trickier.
Powerup costs will increase per use.
Turrets now have a special attack that unlocks when you match a specific stat. The special ability requires a 60/105s (campaign/endless) charge time.
Turret upgrade cost offset. Each upgrade costs more than the previous one for the same stat. In the campaign this generally means the special abilities cannot be unlocked on the early levels and pushes players to build in more locations instead of maxing turrets early on.
Turret recoupable credits from sales the same as before, meaning less of investment on upgrades can now be recouped from sales.
All enemy and turret stats rebalanced. To allow for more finetuning, DMG and HP has been doubled and then tuned further. This means the repair speed has been changed to accommodate higher HP values for turrets. It also means fully repairing turrets is now more expensive than before.
There’s now a 5 % chance turrets will score a lucky chance when enemies fire the killing shot. This sets the turret hp to 1 and stuns enemies for a second, allowing turrets to survive even the most devastating hits. Using the Bull turret’s gentle giant special ability sets the chance to 50 % for a short time.
– Endless mode
Continuous mode leveling system overhauled. Instead of all stats leveling up each 5-8 spawn cycles, either of DMG, HP or yield is randomly picked to level up each 1-2 spawn cycles. This should make each game more different and changes the difficulty ramp a bit – If you are lucky, yields will level up faster than damage and hit point, for instance.
Insect generals added to the continuous mode. Every fifth cycle, the last enemy spawned from one point will be a general – the general is three levels ahead of the wave level for DMG and HP and 5 levels for yield stats. Works as an extra challenge and a way to boost credits. Marked with a red vortex particle underneath.
Wave pause time changed from linear random to normal distribution. Making very long and very short pauses rarer.
Pause time between enemy spawns in wave changed from linear random between -0.1 and 0.2 to normal distribution between -0.1 and 0.4.
Spawn amount per wave in endless mode changed from random between starting value and starting value to cycle, to normally distributed with starting value as mean. This mean shifts up by value one per 5 wave cycles meaning each 5 cycles will increase the number of enemies spawned. Getting very few or very many spawned enemies should thus be rarer in the beginning and more common later in a game.
Yields changed from linear to log normal curve, meaning faster in the beginning and slower later on in the endless mode.
– Graphical changes
Some turrets have had some animations and more particles added.
Explosion effects overhauled.
The game has been translated into Russian, Swedish, Romanian and French.
Button press sound moved, to avoid “false” click sounds.
First wave starts briefly after placement of first turret to allow planning.
Level 14 deathbox fix. Enemies would sometimes miss the deathbox causing the level to not finish.
Bug where raycasting would bug out when not using SSAA fixed.
Additional hexes on level 5 and 9 and the endless mode highway level.
Unfortunatly There were a things that I had intended for this version, but simply did not have time to implement or finish implementing.
– Remaining additions for the future
I had intended to have these additions added this update, but due to a lack of time they’ve been cut. Should hopefully see implementation fairly soon.
* Mac version added. Was intended for this update, but due to continuing issues with the Mac build it has been pushed to the future.
* In game scoreboards when you finish a continuous level. Will be implemented in the next update.
* Hexagon level. Was pushed to a later date due to lack of time to balance it properly and give it the required time to test it.
* German, Spanish and Chinese translations.
Version ”Fire Ant” is now live and changes the game in a host of ways. Aside from adding two new levels, the update also rebalances the game in a number of ways. Turrets have been differentiated more, so that they have more distinct usage situations. The enemy stat increases when they level up in the continuous mode have also been changed up, making the challenge more consistent. Lastly, the yield formula has been changed in the continuous mode.
The update also adds in a collectible in the form of mem discs, that can be found in the campaign levels. The mem discs contain brief story elements, that pieced together will give a view of the events leading up to the campaign.
Lastly, the update adds Steam leaderboards, so that your best scores in the continuous mode are saved and can be compared to those of other players around the world. For Game Jolt users, leaderboards were implemented already in the launch version of the game.
Here’s the full list of changes, fixes and additions:
- Game has been upgraded from Unity 5.5 to Unity 2017.2 which means SSAA (Res scaling),
- NGSS (shadow system) and post processing effects have been optimized.
Bugs and issues:
- Level 5 base object (the truck) has been moved to increase visibility.
- Level 5 some hexes have been moved to allow max range turrets to reach the base object.
- Fixed issue where base options in the ui would get displaced when switching res.
- Increased music fadeout speed when switching scenes.
- Adjusted post proc effects in the achievement display area.
- Fixed the heatwave effect offsetting.
- Fixed sound not playing when clicking next/previous button before last achievement in achievement display area.
New features and rebalancing:
- Two new endless mode levels, the Forest and the Overpass.
- Objectives for each level have been added to the loading screen.
- If there’s an object to protect, an indicator shows which one it is.
- Zooming has been implemented, mapped to the scroll wheel.
- Collectible story notes added to campaign levels.
- Story note reading room added in main menu.
- Song in reading room.
- Five new achievements, Give ’em hell 7+8, Prime example 7+8 and Librarian.
- Steam scoreboards implemented for continuous mode levels.
- Acid turret, Bull turret, Missile turret, Plasma turret, Rail turret, Double turret and Machinegun turret rebalanced.
- Enemy level up stats (including yields) rebalanced in endless mode.
- Bug zapper range slightly increased and damage greatly increased.
- Turrets can be rotated using the arrow keys.
- Plasma turret smoother textures.
- Level 5 DoF has been adjusted to avoid the turret at the far right position on the screen blurring.
- Level C1 DoF has been adjusted to avoid bottom turret position blurring.
- Level C1 Grass was growing through some cars.
- Level C1 Lens dirt decreased.
- Added more songs to the playlists in the continuous mode.
- Spruced up turret firing effects for plasma, sonic pulse.
- Added barrel heat on the Double turret.
- Text on game over in continuous mode adjusted to not line break.
- Increased Missile turret emission.
I’m in the process of working out some changes to the game and figured I would list the upcoming changes here. Most of this info has been published on the steam store front for Brink of Extinction as well, but also on IndieDB.
– I will spruce up some of the weapon firing effects.
– Scoreboards were planned for, but never made it into, the initial release, so these will be added also (for the continuous mode levels).
– Some background story. The game does have a bit of a story, but it is currently not conveyed in-game.
– Turret default rotation will be setable with the scroll wheel, and not only by clicking and dragging.
– Tweaking of turret stats.
– Added upgrade info into the turret showroom.
– Camera pan and/or zoom.
– Objectives listed before level starts.
– Two additional endless mode levels, one with Tesla and one without. This also means four more achievements.
The turret nerfs and buffs are as follows (although they may still be subject to change):
Acid turret: Starting HP from 500 to 450, minus 50. Starting Damage from 35 to 25, minus 10. Speed will be equivalent to that of rail (40). HP upgrade will give 125 instead of 100, damage upgrade till give 25 instead of 20. Splash range will go from 1.25 to 1.3.
Bull turret: 10 less starting damage, from 40 to 30. Damage upgrade will give 20 instead of 16. Starting HP up 50.
Plasma: Starting damage 25 instead of 20, and damage upgrade 8 instead of 10. Splash damage radius from 0.9 to 1.
Missile turret: Increased damage upgrade, from 30 to 35.
Overall, the concept is to differentiate the turrets from each other more. So the Acid turret will be stronger and have better range than rail, but is weaker. Bull turret gets a more emphasized role as high HP and strong, but is slower than machinegun turret and double turret. The double turret will remain a sort of all round turret. The plasma turret and acid turret both get splash range improvements, making them suitable for large hordes of enemies. Plasma is weaker but faster than acid. I’ve yet to decide about the cost of upgrades, and some more minor adjustments may still follow after more extensive testing.
Enemies will also get some stat tweaks, but primarily when it comes to their upgrade values, so this won’t affect the campaign, as all enemies are level 0 in the campaign. I have yet to start tweaking enemies, so a post on this will follow once I have done this.
Lastly, the game has been updated from Unity 5.5 to Unity 2017.2, which means some of the assets I use have also been updated. Since the shadow system and SSAA system were fairly new when I developed the game, these have now been updated and optimized, which means the game should run better in general also (although no complains on performance or bugs have been reported).
I have previously stated the release of this update being around February, but it might be available in January already, but no promises!
I’ve gotten the BoE builds submitted to Steam. If all goes as planned, the game will release on the 30th of November on Steam and GameJolt (although a bit of work remains on the GJ builds) for windows.
I’ve also gotten the store front for Twinstack in order and submitted for approval. This means it should be up soon. The game itself is planned to release on the 20th of December, for Windows, Mac and Linux.
On a different note, the Retro 2D Tile Set Dark now has a Light edition, available on the Asset Store.
There are some other things planned for the near future. These things will be announced pretty soon. 🙂
The Brink of Extinction store page on Steam has been submitted for review. In the meantime work will continue on some Steam achievement implementation and setting up GameJolt for achievements as well. The game looks as if it’s still on for a Nov 30th release. 🙂
Been busy recently with setting up the company and also moving to a new place. Setting up the company formally has meant that I’ve needed to change the name (too similar to other brands… sigh).
All sites, aside from the unity asset store, have been updated with the new name. Unity asset store will be updated soon!
Other than that, there will be some new updates on my current projects around this weekend 🙂
In this post I aim to describe in relative detail one of the fundamental systems of my new game that currently goes under the working title ”miniTD”. The procedural level generation.
There are 6 main components of the procedural level generation in miniTD:
Generate paths and buildable locales
Find path solution
The terrain generation is a straight-forward process of generating black and white noise into a 16×16 color array. This array is stored away until the paths and buildable locales have been generated.
So next up, a grid pattern is created by placing 3 to 6 lines across the X and Y axis respectively. This is not an actual grid written to a texture, but rather a logic grid saved into a List<int>. The only rule that applies to placement here is that two vertical/horizontal lines may not run next to each other and they may not be placed so that they run along the edges of the map. As already mentioned, this grid only exists as a list of sorted integers and are not drawn on a texture. Instead, the two lists of integers (for x and y axes) are used to calculate possible intersections (where the lines across X and Y cross paths). These intersections, in turn, are used as a basis for the path solver.
The image is an illustration of the grid where red signifies excluded areas, blue is a placed line and green is a calculated intersection.
Onto the next step – the path solver decides a starting location on either the left or right side of the map (along X), and an ending point at the lower or upper part of the map (along Y). After this, the sorted list of intersections (List<Vector2>) is loaded into the solver and an iterative process of decisions on whether to move along X or Y is performed. For each move, an intersection is moved out of the list of loaded intersections, into a list of selected intersections. The primary rules for moving is that only nearby intersections are viable and thus an intersection may not be crossed. If there are no viable nearby intersections, the current index of the list of selected intersections gets removed, essentially moving the path solver backwards one step. This means that the solver has “lost” a move and needs to re-evaluate the previous step. This process will be ongoing up until the point where there are enough viable moves to get to the end of the level. The basic thinking behind this process is that the solver needs to be able to avoid “locking itself in” when it cannot make any moves that gets it closer to the end of the level. A slowed down solving process can be seen here:
The video illustrated the solver making a wrong decision, then backtracking to find a viable way towards the end of the level.
Once the solver has completed its work, the list of selected intersections gets returned and the path can now be finished. The path, just like the terrain, is just an array of colors (green in this case). This array is used to determine where to place buildable locales. The buildable locales can only be placed directly next to a path or diagonally from a path, because the turrets have only 1 unit of range (at least until the level up). The locales are randomly placed in conjunction with the path. Locales are marked with red on the same map along with the path in green.
After this, the terrain array is merged with the path and locales, essentially just if red or green color is detected, then terrain map gets marked with red/green. The final map is pushed through a blurring process to allow the terrain to “sink in” around the paths, to avoid extreme cliffs.
The image shows what a map would look like made into a texture.
Up until this point, no objects have been created, so the greyscales of the map are used as an indicator of what is referred to as “stack height”, the number of tiles to stack for height. This value ranges from 0 to 20, where black means no tiles are placed, and white means 20 tiles are placed. This is done for each pixel of the map, except for pixels where the colors red or green are detected. Instead, these are given fixed height values, ensuring that the enemy path and locales are always on same height, so that they can be easily recognized by the player going into a new level.
To make the levels more interesting and allow for further random variation, the stacking of tiles based on the greyscale parts of the map always end with a random chance of “gibberish” placement. Gibberish is the in-code term for non-gameplay vital objects such as trees, rocks, bushes or whatever the selected game world theme the player has selected come with. All the actual object creation is done off screen, so as to avoid visible lag from spawning multitudes of objects.
Lastly, as a method optimize the scene and avoid excessive shadow casters, while also making it easier to manage all the terrain layers when displaying the level construction to the player, all terrain layers are merged into one new mesh object before the level is displayed to the player. The same merging process occurs to the trees and rocks placed into the level, once they have fallen into place, and before the level’s spawn point is activated. Merging the rocks and trees is also a way to cut down on the number of shadow casters in the scene.
Video showing several random levels being made.
I hope this write-up has been enjoyable, comments and questions are always welcome. 🙂