Reality is a Game

Game thinking from Adam Clare

Tag: unity(Page 1 of 3)

Stardoz! My Game Which Uses Heartbeats To Spawn Enemies

Stardoz

First version of Stardoz

Stardoz is a crazy experimental biometric-driven game I built at TOJam a few weeks back. In the game you fly around in a spaceship shooting at giant floating heads and hands. It’s similar to many flying in space combat games.

The catch is that your heartbeat controls the spawn rate of enemies. The pulsing red border on the screen shows the player’s heart at work.

If floating heads seems familiar to you, it’s because you may remember the movie Zardoz starring Sean Connery. Just watch the trailer to see how zany the movie is.

Really, the gameplay is similar in play insofar that “the gun is good” and that one survives by ‘killing’. It’s very simple gameplay with a neat twist. I made Stardoz to test out some space-based game mechanics and to incorporate some biometric data into a game.

Playtesters have liked the heartbeat spawn mechanic and only one player took issue that the game is hard for people with high resting heart rates. I’m still tweaking the spawn rate but it’s alright for the most part.

Stardom being played

The art confuses players and that’s a design goal of mine. I wanted it to cross between the ridiculous and the overly-symbolic. Thus, instead of a score it lists how many egos you’ve destroyed and how many emotions you have. .

You are flying through space (or is mindspace?) destroying representations of human forms. In some cases it’s heavy handed and in some ways quite subtle (only one person has figured out the symbolic placement of the TOJam goat).

Getting the Heartbeat

Pulse Sensor

With the excellent help of J Lee, I was able to get an Arduino Uno board to work with a pulse sensor which meant that heartbeats could be tracked using Unity. The heartbeat is tracked using this pulse sensor which was really easy to connect to the Arduino and to configure it into Unity.

“Fun fact”: for Windows use COM4 and /dev/cu.usbmodem1421 for Macs as the port for Unity to talk to the Arduino. At least this is what worked for my setup. Results may vary.

The pulse sensor goes around the player’s finger and surprisingly doesn’t interfere with gameplay controls. It can be attached to the player’s ear but it just feels weird.

Here it is in action around the left index finger of a player:

Heartbeat sensor with game controller

Next Steps

For this game will be to see if I can get it working with the Apple Watch (or Android Wear), if it works maybe I’ll release it for anyone to play. In the meantime I’m hoping to show it at upcoming events.

Stardoz restart

On Game Making Resolutions for 2014 And Learning To Code

It’s 2014 and if you’re into making games you may have made one of those resolution things related to making more games- I know I did!

I want to push myself and have thus opted to engage in the One Game a Month Challenge. The challenge is to release a game a month – not to create a brand new game every month. In this regard it’s different from the game jam model of starting fresh. So if you have games that are half finished (like me) then you can complete them and have that count. One of the nifty things about the challenge is that it’s like a game itself in which you can earn XP. Presently, I’m at level 4 for just filling out my profile.

One thing that I particularly like about the game a month challenge is that it’s not focussed on only video games. You can make board games (pro tip: Board Game Jam!) or games set in playgrounds! Whatever your heart desires.

It looks like many on Twitter have also thought that entering the self-imposed challenge is a good idea too. It’s never too late to join!

For those of you who are debating making games yourself, I implore you to take a look at the easy to use resources I’ve listed which include things from art to code to sound to more!

If all goes according to plan you too can be a indie game developer by the end of 2014! When in doubt, be sure to read how to be a happy indie game developer. Stay positive and remember that even a little time spent on making your game brings it that much closer to completion.

At the very least, you can help make 2014 not copy an awful year for technology that 2013 was.

Coding technology is complex

Speaking of technology, it obviously relies on code. Part of me wanting to attempt a game a month is to up my abilities in the obscure world of coding.

Coding is obviously something that needs to be learned and there are many place online to learn it. What I’m interested in is what people had to say about the process of learning.

Late last year Cecily Carver of DMG fame posted Things I Wish Someone Had Told Me When I Was Learning How to Code and it’s excellent! Here’s just one of many great points in the essay:

I’ve found that a big difference between new coders and experienced coders is faith: faith that things are going wrong for a logical and discoverable reason, faith that problems are fixable, faith that there is a way to accomplish the goal. The path from “not working” to “working” might not be obvious, but with patience you can usually find it.

In /r/LearnProgramming one person asked how self-taught developers learned how to code. The best response is applicable to anyone learning anything new:

You’re going to be frustrated, feel like you’re stupid, and get completely overwhelmed many times. The only difference between that person with that app/game on the store and you is that they didn’t give up.

Coding is (socially) complex!

It’s so often said in the tech community that coding will solve all problems and guarantee you a job. This is not the case! Indeed, over at Wired they have an article Pushing People to Code Will Widen the Gap Between Rich and Poor which further complicates this technopostivist worldview.

All that compiles is not gold. Coding is only a panacea in a world where merit is all it takes to succeed. In other words, a starkly different world from the one we actually live in where social structures, systemic biases, and luck may matter more.

On this “code solves all” ideology all I can really say about it is that it’s important to understand the core logic behind programming. For now, I’m going to continue to learn and make more games.

This turned from a short post into a long one that really should divided into multiple post for clarity. Oh well.

Time to go make games!

Get to Know Unity Shaders

Unity is the indie game engine of choice due to its relative ease of use and ability to output to multiple platforms. Some people complain that Unity games “look the same” but that isn’t true, and very avoidable, if you play with shaders.

First, what’s a shader? A shader is an algorithm that tells computers what something looks like. For example, you can have a dull red apple that looks red in a default shader but in a modified shader that red apple becomes a highly reflective purple apple.

Thankfully, the great people at Unity Gems have a Noobs Guide to Shaders! It covers the basics and goes into how you can use it in your Unity-made games. If you’re new to code you may get a bit of a shock, but you’ll do fine – I think.

You should read this article if:

  • You are new to shader programming in general
  • You want to build shaders to do cool things in your game but you can’t find one that fits your needs
  • Strumpy Shader Editor isn’t helping because you don’t get the basic principles
  • You want to manipulate textures inside your shader

Unity Gems mentions the excellent Strumpy Shader, which is really good. It’s an open source shader editor that is quite powerful, part of me wonders why it’s not just included into Unity. If you know the very basics of shaders than you may want to check out this introduction to Strumpy Shader:

Familiar with shaders?

If you are familiar with shaders but not how they function in Unity, check out Unity’s page of surface shaders.

Of course you can always create and play around with your own.

Lastly, if you have Unity Pro check out to create a dream-like world. This last tutorial makes use of camera effects – and camera effects will have to be a whole other post.

Mobile Optimization Tips for Unity

Earlier this year Unity’s basic mobile licenses went free which is a great thing for indie developers. If you’re new to putting games on mobile with Unity you’re going to want to check out these tips.

Garden Knight Games has a good introductory blog post to getting your Unity game ready for mobile devices.

This article is going to focus on how to get your Unity game running as fast as possible on mobile devices, specifically iPhone but you can carry over techniques to Android as well. This is something I find a lot of people have issues with, their game running at terrible frame rates and not understanding why or what they can do about it! iPhone’s hardware isn’t that beefy which makes optimization much more important! Squeezing visual fidelity without suffering game play is the challenge.

It mentions the 3Gs iPhone quite a bit and I think it’s far to say that you can ignore that device flat out – particularly with the rumoured new iPhone coming in September. Key lesson from this is that directional lights on mobile slow everything way down.

Similarly, Paladin Studios has a post on getting your Unity game ready for iOS and Android using four tips.

1. Use The Performance Profiler

The first thing to look at when you want to improve the performance game is the Unity Profiler. It is a Unity Pro feature that lets you analyze performance bottlenecks. The Profiler is an invaluable tool. With it, you can determine where any framerate issues are coming from. You run the game on your target device, and run the profiler on your PC. When you launch the game, the Profiler starts pumping out performance data.

Here’s a quick video on texture optimisation and size tips in Unity 3D:

Finally, a general tip across all mobile games is scaling for the proper screen size. In this post, three options are outlined: scaling, letter boxing, or cropping.

(hat tip to r/gamedev)

Page 1 of 3

Powered by WordPress & Theme by Anders Norén

%d bloggers like this: