We are pretty sure there are Pixies lyrics about writing a python script to automate colouring a monkey’s face with 200 separate materials for a render test anyway… I’ll check later.
Er… yeh, ok, so what have we been up to then?
Well we have been pretty busy actually, and as well as the usual dev stuff we got to take part in a couple inspiring events…HackerHouse
Our friend Lauri Love has set up an initiative called Hacker House along with women-in-tech powerhouse Jen Arcuri, to get the greatest hacking minds into the same spaces and working on some of the biggest challenges in cyber security awareness, training and pen testing.They ran a Hack weekend to #HackJoti, an ID verification app for your phone. As part of that Hackerhouse got a collection of folks together to talk and inspire and asked us to come up and demo Off Grid as part of this, which we gladly did!
The weekend was filled with engaging conversation with all kinds of folk from across the hacker spectrum including HackerFantastic, the Pirate Party’s Ray Johansen, and AnonUKRadio among others.
#FreeLauri
Lauri is also facing an extradition trial and the repercussions of his case will set the agenda for important standards around the right to encrypt. He is battling hard to make sure the law is fair so if you are interested in this area even in the slightest, please read up and consider writing to your mp about his trial:https://freelauri.com/write-to-your-mp-in-support-of-lauri-love/
CIJ Cryptoparty
We also helped teach encryption to journalists at the Centre for Investigative Journalism with ex-Lulzsec member Mustafa Al-Basam, The Courage Foundation’s Naomi Colvin, and Silkie Carlo of Liberty. The day had some really interesting panels on the current state of legislation and crypto and it was great to be helping journalists get to grips with security. To read more about the CIJ and what they do check them out here:
http://www.tcij.org/
And onto the development update…
We played with some fairly central elements of the game this sprint…How using your mobile phone affects your brain
After spending a few of the last sprints working on mission scripting in Lua, and dealing with connecting devices to networks, support for sending data around, including Lua scripts in that data, and for devices to execute Lua code, we felt it was time to connect the next part of the puzzle; using all this to actually help you sneak through the levels.…And to do this we set the goal to be one of the examples we’ve used all the time to describe how the data mechanics in the game work:
As you walk past a soda vending machine, it sends you an SMS advertisement for Generic Cola™. Reading through SMS and e-mails you’ve collected from the guards patrolling in the building, you can learn that one of them is pretty much a cola addict. Recognizing the device information of that guard, you can then send the ad message forward to his phone, causing him to suddenly start feeling thirsty and decide that it would be a nice time to take a break from the boring patrol routine and head for the closest vending machine…
Most of that is now working, and while it required adding some new features to our mission scripting/Lua API, the majority of things needed were already there, so setting up things like this is pretty much something anyone can do when building their levels, not something that needs to be built by us on the Unity side. That alone is pretty exciting!
Well, like mentioned, we did have to add some new features to set this up. The main thing was a way for changing the AI motivation value from mission Lua scripts. The rest was generic-purpose Lua scripting support we had already added anyway.
Of course we plan on adding many more options for affecting the NPC’s than just changing their motivation, and all those options will be available both in the main mission script, and in the data files you might end up sending around the level to various devices. In the long run we’ll probably add more direct ways to connect the AI with Lua scripts, either by making the AI run the scripts (like the mission system and all network devices do now) or possibly by converting some part of the AI itself to run through the Lua machine.
Vertex Colours
So our decidedly brassic art style ought to provide for amazing performance benchmarks, well over the course of development we found our prototype-attitude to managing materials in Unity has ballooned unnecessarily and so our flat art style actually started to work against us a little.If you are going to make a game with an art style that looks like it should be on 90′s hardware, then you should probably use 90′s approaches to tech.
Step in, vertex colours.
We wrote up a couple of shader tests to play with how we might want materials that made use of vertex colours to render, and then ran some basic benchmark tests, between a 200 material monkey…
… and a monkey we had painted Ziggy Stardust-esque vertex colours on…
The stats windows here in these screenshots belie the performance win we gained (because Rich’s laptop is going through an identity crisis and so doesn’t know if it is a Turing machine or a copmuterised space heater).
We actually managed:
200 materials:
33-35 fps
16-18ms render
11290 batches
52181 saved by batching
1 material w. vertex colors:
61-62 fps (We forgot to disable vsync on so it’s capped to around 60)
3.1-3.2 ms render (that’s pretty clear difference!)
40 batches
52575 saved by batching
On those grounds we decided to spend a some time this sprint working on the LevelKit geometry to get the pieces using vertex colours. so we may well have some snazzy screens soon of new levels using the updated LevelKit.
Other small stuff & fixes
- Mission Lua scripts can connect interactive devices (laptops, vending machines, door scanners etc) to networks.
- Mission system supports scripted sending of data from any device and character.
- Sound events can be triggered from Lua scripts
Rich and Pontus
No comments:
Post a Comment