Whistle Your Way Through A Cave in: Hyper Bat Simulator 2018!

A few weeks ago was the end of January, and many game developers know what that means: It’s time for yet another Global Game Jam! The GGJ is a world-wide event with hundreds of locations where people meet for 48 hours of rapid game development.

This year’s theme was “Waves”, and I found myself in a team where I didn’t know a single person – which is always challenging, but also fun! The development went nearly without any hitches and I’m really content with our result:

In the game, you are a bat flying through a cave looking for its bat pups so you can go hunting. The cave is dark and the pups are tiny, so you use your echolocation to see and hope the pups answer. You steer with the gamepad – but to use the echolocation, you have to whistle into a microphone! (Like the title suggests, this is definitely the latest in bat simulation technology.)

Here’s a video of our presentation after the GGJ (starts at 0:29):

 

And a small trailer video Emily and Caroline made:

 

The game and its source code is available at its Global Game Jam entry page.

Before I talk a little more about the development, here’s the team:

We also used some assets:

Okay, on to the development! This time (and very atypical for me), the concept was rather simple. A single player game with no really hard development challenges – well, that leaves more room for polish, and sounds just right for 48 hours!

This was also one of the few times where the game design didn’t change much over the course of the weekend. Everything just worked. In the end, we actually finished the game with all the features we wanted! We even removed some features we already implemented because they made the game less accessible and weren’t as much fun as we had imagined: Dizzyness when the bat crashed into a wall, and not being able to call out to children when there’s a wall in the way. We also wanted to add monsters that follow sound, but in the end the game turned out to be plenty fun without the added complications, so we decided not to go that route.

The microphone implementation was incredibly easy, more so because this isn’t my first microphone controlled game. I just had to sample the input volume and detects peaks.

First I wanted to do the echolocation waves via shaders, but that that would’ve taken some time. Then I remembered something I learnt about in a Pluralsight video tutorial just a few weeks ago: Light Cookies, which allow you to put shadow masks on Unity3D lights. The final echolocation waves are just multiple spotlights with a circular light cookie mask shining from above, and the angle gets progressively bigger. That way it “runs” across obstacles and scales walls and stalagmites instead of just looking like it’s two-dimensional shape projected from above. The effect is a bit hard to describe, but you can see it quite often in the videos linked above.

I am really happy with our result! Thanks a lot to my team for being the best team – and to the location organizers and the Global Game Jam team who made it possible for us to jam without worrying too much about such mundane things as work space or food!

Generative Art – Sketches #043 to #050

Alright, next batch of generative sketches coming up. Grab them while they’re hot!

#043: Das Kollektiv

This is the first time one of my artworks is inspired by music! The song in question is Das Kollektiv by ASP. I’m taking a fairly literal interpretation of a swarm of little entities in between the walls, sucking out the essence of the “guests”. The images are pretty dark; you might need high contrast settings.

043_das_kollektiv_01      043_das_kollektiv_02      043_das_kollektiv_03

#044: Into Oblivion

This next one isn’t just inspired by music, but directly driven by it! There is already a post about it, so I’ll just post the visuals here.

Here is a video using a shortened version of Push Every Button by Lapfox:

044_into_oblivion_01      044_into_oblivion_02      044_into_oblivion_03

044_into_oblivion_04      044_into_oblivion_05      044_into_oblivion_06

A Slice of π – A MOD Music Visualizer

When making Into Oblivion, I was a bit frustrated that it was rather hard to gain good information from the FFT analysis and that it was utterly impossible to find which instrument was playing. And then a friend told me about MOD music.

Unlike audio files like mp3, module files aren’t rendered down to just the audio information. Simplified, they have two elements: A collection of distinct audio samples and tracker information when to play which sample and how to modify its pitch, volume and other properties. So that means if your visualizer is a MOD player, you have all this juicy information available at your fingertips!

So there were a few things I needed:

  • MOD files: I got those from ModArchive.org. I chose:
    • chiptune, phantasmagoria, rsectro and zapped_out by 4mat
    • Rivendell by radix
  • A MOD tracker to analyze the MOD files: OpenMPT filled that spot quite nicely and was easy to get into even for a total beginner like me.
  • A MOD processing library – of which I only found one! Luckily, PortaMod has (nearly) everything I needed, and the creator Brendan Ratliff was most helpful on Twitter.

Since this was my first foray into MOD music visualization and I wasn’t cooperating with a musician, I wanted to keep the visualizer as general as possible; any file that it could play should work. I also wanted to use as much information as possible. In the end, I chose a rotating circular representation divided into slices. Each slice is a MOD channel and each MOD sample was assigned a color. Pitch modifications made the radius go bigger, and everything is pulsating according to the output amplitude.

Downloads:

Executable for Windows
GitHub Repository (MIT License)

And now there’s been enough talk – have a preview video and a few screenshots!

The song used are, in order:

  • Rivendell by radix
  • phantasmagoria by 4mat
  • rsectro by 4mat
  • zapped_out by 4mat

chiptune01      phantasmagoria01

phantasmagoria02      phantasmagoria04

rivendell03      rsectro01

rsectro04      zappedout03

Tobi’s Unity Utilities

When you google “unity utilities”, it seems like everyone and their dog has one of those. Well… now there’s one more of them! Open-sourced, well-commented, with descriptions, examples and class documentation. Get it while it’s hot:

GitHub repository

Class Documentation

Overview

  • Countdown: Useful for things like cooldowns or spawn delays. It is also helpful for tweening things by using the PercentElapsed property.
  • EditorHelper: Gets the [Tooltip] attribute content of fields for editor classes. Might get more helper methods in the future.
  • LINQExtensions: A collection of extension methods for IEnumerable, List and arrays.
  • MathHelper: Helper methods for time-independent eased lerping, mapping and angles.
  • MeshCreator: Makes it more convenient to create meshes via code.
  • NoiseOutputValue: Enter a range and a speed in the editor, get an output value that fluctuates over time using Perlin Noise.
  • RandomBag: A RandomBag gives you random items from a group while ensuring that in a certain interval every item was given back the same number of times.
  • Range: Editable data types that take an int/float range. Used for things like “Spawn 2 to 4 enemies.”
  • RollingArray: Collection that keeps the last x elements that are added to it.
  • Singleton: Allows easy and convenient creation of a Singleton. Optionally makes a Singleton persist between scenes while ensuring that only one exists.
  • UnityHelper: Contains a plethora of useful extensions and helpers for Transform, GameObject, Vector2/3/4, Rect and more.
  • XmlHelper: Serializes data to XML strings and makes accessing optional element content and attributes in general XMLs easier.

Usage

To use the scripts, just drop them into the Assets folder of your projects. Or better yet, make an “Assets/Extensions/TobisUnityUtitilites” folder and drop them there. Hurray for proper organisation.

You can also just use selected scripts, but you should check the “Dependencies” section in the respective folder to make sure you copy everything you need.

Generative Art – Sketches #029 to #035

It’s been over a year since I last posted a collection of small generative art sketches – but that’s not because I stopped making them, I just got a bit lazy with posting. There’s quite a lot queued up now! And without any further ado, here are candidates #29 to #35.

#029: Plasma Blob

This one isn’t terribly impressive, but it was made in a few minutes to demonstrate Processing to a colleague and is reasonably nice to look at.

s029_plasma_blob_03      s029_plasma_blob_02      s029_plasma_blob_01

#030: Mara’s Ocean

A typographic variation of #028: Isles using the Mara’s Eye font.

s030_maras_ocean_01      s030_maras_ocean_02      s030_maras_ocean_03

s030_maras_ocean_04      s030_maras_ocean_05      s030_maras_ocean_06

#031: Chimera Maker: What Has Science Done?!

The sillyness levels go through the roof with this one. For executables for Windows, Mac, Linux and Android and for more pictures, check out it’s own blog post!

031_chimera_maker_01     031_chimera_maker_02     031_chimera_maker_03

The Greater Book Of Transmutation: A Procedurally Generated DIY Book for the NaNoGenMo 2015

After missing last year’s NaNoGenMo (the generative cousin of the NaNoWriMo: the National Novel Generation Month), I thought I should finally take the plunge this year. Nevermind that I never made any generative text before.

The Greater Book of Transmutation is mainly based on a free association database that I found here. It’s about making things, using materials that are commonly associated with them – e.g., a cat might be made from “being feline”, “claws”, “meows” and “being graceful” and “tail”. Throw in a system of tools with actions that use/transform materials, a bit of word classification, a markov chain latin words generator, a lot of silliness and bit LaTeX, and you get:

The Greater Book of Transmutation Title

You can find the resulting PDF here.

The source code (MIT license) written in Python is also available.

An example:

How to make a book in 12 easy steps:

Materials:

  • 10 hymns
  • 178 readings
  • 10 clear concepts of poem
  • 4 clear concepts of guide

Tools:

  • bucket with water
  • vessel
  • pet unicorn
  • ballpoint pen

Instructions:

  1. Let vessel cool down.
  2. Heat vessel.
  3. Dip 10 clear concepts of poem into the bucket with water.
  4. Feed 10 clear concepts of wet poem to your pet unicorn.
  5. Let your pet unicorn lick 10 hymns.
  6. Pet your pet unicorn.
  7. Wait for a long time.
  8. Wait until your pet unicorn poops. Receive 124.89 ounces of a very dirty pile of “wet poem”
  9. Draw a magic circle on the floor using the ballpoint pen.
  10. Draw a cross into the circle and place 10 licked hymns, 178 readings, 4 clear concepts of guide and 124.89 ounces of a very dirty pile of “wet poem” on each corner.
  11. Whisper the following spell: “Alchemia implacabilis! Meio clystermitto clodigo condocefaciencia, millibi! Verca bisellatrocinium! Creditor circumbrans!”
  12. Reluctantly, a book will appear inside the circle.

That might also help those that are struggling to make a book. And if you are missing one of the materials or tools, maybe another entry in The Greater Book of Transmutation could help you make it!

Used data sources:

Generative Art – Week 4

Four weeks ago, I started doing daily generative art Processing sketches – and now I am at the end of this fourth week. I’m glad I held on to the “do one sketch every day” mantra, even when I wasn’t feeling inspired – I made some pretty fun stuff this week. Alright, let’s dive right in!

#022: Tentapus Generator

That’s right – it has 10 legs, not 8! I really like how the legs always look so different. While generating, sometimes it almost looked like it was dancing. I might actually use this in a game one day – it certainly looks like it would be fun to play with.

s15_03_22_tentapus_generator_01      s15_03_22_tentapus_generator_02      s15_03_22_tentapus_generator_03

s15_03_22_tentapus_generator_04      s15_03_22_tentapus_generator_05      s15_03_22_tentapus_generator_06

Generative Art – Week 3

And thus, the third week ended. It had its hits and misses, but I learnt new stuff and I’m especially content with the three dailies at the end! And now, without any further ado:

#015: Probably a Metaphor for Something

On the other hand, maybe it isn’t. Let’s… let’s just skip this one, okay? I guess it’s safe to say that it didn’t go where I wanted it to go.

s15_03_15_probably_a_metapher_for_something_01

Generative Art – Week 2

And the second week is over! I had some interesting and diverse results this week. I’m especially fond of the Silk/LightWeaver and some of the results of Stormy Weather look very dynamic.

#008 – Silky Smoke

A variant of #006 (CircleTrails), inspired by this video where Casey Reas talks about the circle collision thing that #006 also uses, but with drawing lines between them. Silky Smoke works in a similar way, but isn’t about drawing a persistent picture and more about the movement created. It looks okay, but I have to admit that I was hoping for more.

s15_03_08_silky_smoke_1      s15_03_08_silky_smoke_2

s15_03_08_silky_smoke_3      s15_03_08_silky_smoke_4

Generative Art – Week 1

Hey! If you’ve been reading this blog for a while, by now you’ve probably noticed that (true to my tagline) I mostly post games that I make – but sometimes, it’s also other stuff. The “other stuff” might get a bit more company from now on! I’ve been getting into generative art, and I’ve decided to make one generative art sketch per day until I get bored with it. Every Sunday I’ll post the results of the week with screenshots, videos, executables for Windows and the processing source files. And if you’d rather see me making games, don’t worry – making interesting and potentially beautiful things with code will only help making my games look better. And now without further ado, I present to you week 1!

#001 – ShardSphere

First one in my daily series! Mostly inspired by Generative Art Chapter 5. I really like the beginning when it comes to life out of nowhere.

s15_03_01_shardsphere_1      s15_03_01_shardsphere_2

s15_03_01_shardsphere_3      s15_03_01_shardsphere_4