So I was tweeting that this took forever:

dialog1

It’s just a dialog box for gratuitous space battles 2., why did it take more than twenty minutes to put together? Now… I’ve seen unity, I know it has all these plug-ins that do stuff like this, and that it’s all very user-friendly etc blah blah. But I’m old school. I’m rocking my own custom-written engine, including all the GUI. That gives me huge advantages (mostly speed) and also some disadvantages. The best advantage is there isn’t anything I can’t make the code do.

The pain with this dialog box came in three flavours.

Flavour one was those circular clock-like indicators. In theory, this is really easy, you can just generate a tri-strip of a lot of polygons and draw a curve thats smooth and crisp as you like, as long as you can spare the vertexs. I’m not drawing many, so it’s not an issue. The problem is, when you do that, you get a too-blocky, too un-aliased clunky mess that just doesn’t look ‘right’ when surrounded by lovely aliased everything. I’m not drawing 3D models, so my game has a  nice smooth look to it, and it jarred badly. So I have a sprite of that curve, and I draw a subset of it using a tri-strip arc. It’s a bit fiddly, ant took a while to get right.

Flavour two was the outline of the right-hand part of the window. It’s a bit complex, as it goes in and out and then around the close button and then loops around those circles, and it has to be really slick too, and ironically in this case it looks better drawn as a crisp 1 pixel line, so there is actual hand-crafted code in there to work out all those positions and curve ncie arcs and lines around them.

Flavour three was speed. I like everything in my game to render fast, including GUI. No point in having a fast engine where 95% of the frame is spent drawing a dialog box. That means ensuring that ouline on the dialog is a single draw call with no fuss, that all those tiny animated bits of fluff in the dialog corners and outside the edges are drawn efficiently, that the calculations on that arc outline are as fast as possible, and that the dialog in general; doesn’t use many draw calls.

It’s all horribly, laughably slow really. I probably have a ‘spare render target’ knocking about that I could use to blap this whole dialog to (BTW they resize dependent on the ship, which adds to the complexity), and then only update it when it changed, otherwise just blapping it as a single quad. In practice, the windows various elements update quite a bit.. but I’m sure I could speed up the module icon rendering with runtime aliasing onto spare render targets. I love all this stuff.

But even I know when I’m getting obsessed and need to move on!

Fuck yeah D00ds!!!!!!!!! Welcome back to another FUCKing BLOG post. YEE-HAW!!!! and it’s me Cliffski! Your Gaming commentator who TELLS IT LIKE IT IS! Lets see what KRAAAAAAAAZZZZY things are happening in the world of games!!!111oneoneone.

Every now and then gamers take part in incredibly self-righteous debates about how games are ‘art’ and a mature art form, and are being unfairly discriminated against compared with more ‘established forms of media such as books, films, TV and the theater. Why is gaming treated as some ‘lesser’ art form or media when other areas of the media are held in comparatively high respect?

I think it’s pretty clear why. or to put it in gamer-coverage terms, DUDE, it’s like FUCKING obvious you Noob!

I’m 45 years old. I have a bald spot, own slippers and have a pension. I play games, and so do a LOT of people my age, and a bit younger. Pretty much everywhere, everyone treats me like an adult. When I read a book or magazine, it treats me like an adult, ditto for most websites I visit, or events I go to. Except when any of those involve games. When it’s games related, suddenly I am targeted as though I’m a horny and stupid 13 year old boy who wants to shout a lot and say ‘fuck’ because mom isn’t watching. This hasn’t been something that appeals to me for about THIRTY YEARS.

As a quite committed, serious gamer, I can ignore a lot of that and still enjoy what is my hobby as well as my job, but it *must* turn away a lot of people my age and in their thirties. I am EMBARRASSED at a lot of gaming coverage, whether it’s in a magazine, or online, and especially in video. Lets not even mention TV. I would have assumed that the situation would have got better over the years, as more people into gaming like me grew up, but if anything, the youtube obsession has made it much, much worse.

Lets face facts, gaming will NEVER be taken seriously until it sheds this infantile image. Tax-breaks for the gaming industry? how do you make that argument to a politician my age (or older) when a quick search online for interviews with game developers shows them being quizzed by embarrassing kidults in bandanas holding skateboards saying DUDE and FUCK at every opportunity? You think that appeals to anyone who is in their forties? It’s not just journalists. even the head people at gaming divisions for Microsoft and Sony have the tendency to start saying stupid dumb things and doing high fives on stage the minute they talk about games.

Some games are deliberately immature and silly and aimed at kids. Some aren’t. All of them get reviewed by people who think they are making adverts for nerf guns. Please grow up, it is acutely EMBARRASSING to see 30+, or 40+ men pretending to be ‘down with tha kidz’. The next time you are posting a video review of a game, see if you can manage it without adopting a stupid voice, and without swearing. If people can review books and movies in a normal voice without screaming and making knob jokes, I theorize the same can be done for games.

I know blog reader regulars know this already but… I’m working on this:

GSB2-Black500w
Oh yes indeed.

I guess not many people will be surprised, the original game sold very well, was very popular and seemed to have an endless lifespan thanks in no small part to an excellent community of modders. The reason for doing a sequel isn’t financial though (I’d be doing Democracy 4 if it was), but driven more by a desire to do the job properly.

Gratuitous Space Battles was the first time I ever tried to do a game that looked impressive. I mean it. Kudos and Democracy are not designed to be a feast for the eye, they are interesting simulations covering topics not covered before. Those games are about choices and mechanics. The GUI was there because it had to be. Nobody looks at those ‘happiness’ sliders in kudos or those bar charts in Democracy and says ‘I gotta get me some of that!’.

menu

I love space battles. I love em to bits. I could sit and watch them on and endless loop. There is so much to them, the feeling of scale, the sound effects, the particles, the cool lasers, the amazing nebula backdrops and the vast vast fleets of ships doing amazing acrobatics. As a kid I grew up watching the original star wars movies and playing Elite. Space Battles are in my blood and I love them. Game-wise, I *want* to liked Eve online, but I’m sick of being ganked by some teenage boy and his pals for their amusement. I don’t want the lowliest of the low mining ships that gets one-shot killed. I want a huge fuck-off spacefleet. I want to be ackbar.

battle

GSB2 is a continuation of my fantasy of making this come to life. There are various questions answered on the placeholder website here, but let me summarize. GSB2 will be bigger, bolder, better and have more cool effects than you can shake a laser gun at. It will have a truly gratuitous user-interface. it will lovingly embrace the possibilities of twin 2560 res monitors. It will have a super-cool feature I haven’t announced yet. It will be a PC-first game, pure and simple, and it will be in your hands either late 2014 or early 2015. And you can play it in London at the Eurogamer Expo in September. If you are press and looking for presskit logos etc, clicky here.

Videos to come in due course. You are going to *really* like the videos.

Creeping inefficiency

July 23, 2014 | Filed under: programming

Here is why I reckon that triple-A game runs slow on your PC. The real reason :D

Step 1: Geniuses at Intel / AMD / ARM design an unbelievable;e processor capable of a bazillion operations per second. Efficiency 100%

Step 2: Someone writes a compiler that converts C++ into assembly language / processor specific stuff that makes a lot of assumptions and loses a big chunk of efficiency Efficiency 80%

Step 3: A coder like me waltzes in and writes some code that is as optimized as he can possibly manage, but has deadlines etc and knowledge gaps meaning it’s slightly less efficient than optimal Efficiency 75%

Step 4: He then writes it to run on a single core, because the headache of smoothly spreading tasks over all the cores is unbelievable, plus game code doesn’t multithread easily so… Efficiency 25%

Step 5: Because writing a new engine for each game is un-trendy these days, the coder decides to use an off the shelf engine that makes even more assumptions and compromises… Efficiency 15%

Step 6: Coder #2, not knowing the assumptions Coder #1 made when we wrote those handy functions, calls them every frame instead of once… Efficiency 5%

Step 7: The game gets run on a typical desktop PC, with 30 different apps fighting for CPU and RAM, IM clients, P2P stuff, web browsers, email, all that crapware that shipped with the PC, anti-virus scanners, cool desktop widgets that tell you the weather, music streaming as you play… Final Efficiency 3%.

eff

My numbers are wild guesses, but I reckon there is some truth to it all. For inexperienced coders using off the shelf engines probably boosts efficiency. Maybe some engines under some circumstances on some hardware multithreading is more possible. I can’t help[ fantasizing about a PC that absolutely locked everything down in a big way when you launched a fullscreen game. Turned off everything that could possibly use some CPU or RAM and let the game run like an xbox. Maybe that is what steambox will become?

That’s more likely than many programmers learning how to optimize, that’s for sure :(

 

There is some twitter discussion about this:

http://www.bbc.co.uk/news/technology-28363729

With controversy about this:

The Commission said: “These include not using the word “free” at all when games contain in-app purchases,”

I fully support this. I think we have an absolute basteridsation of the word free, and that governments should regulate the hell out of it. There are various books on the topic of how the word ‘free’ sets off all kinds of triggers in our brains that ‘very very very cheap’ is nowhere close to. It seems we respond overwhelmingly positive to ‘free’ and ignore all the caveats and disclaimers around it. Basically a ‘free to play’ game is BETTER to our subconscious than a game that is not ‘free’.

But come on, you and I both know F2P games are anything BUT free. They are designed to get as many people as possible (but realistically not all) to pay for ‘upgrades’ and ‘customisations’ and ‘conveniences’ within the game. The business model depends on the game experience being dissatisfying to the extent that you pay to skip bits you don’t like, or improve things you are unhappy with. Why give the player 100 unlock points per battle when you can give them just 5, and charge $1 for 100 unlock ‘gems’ instead? Cynical, cynical bullshit…

The trouble is, this WORKS. it works well. It works in the way cunning modern advertising works, it plays to tricks in our brain, and the way we are easily fooled, lured, confused and misdirected. We are not vulcans, but massively irrational animals who are at the mercy of our primitive subconscious desires and pattern matching. The idea that any of our purchasing decisions are rational is a joke, and the idea that we are not being manipulated by cynical F2P business models is a joke too. It’s perfectly understandable that so many of these F2p companies employ pyschologists. They aren’t there to make the game fun, they are there to make you spend money. Lots of it.

This isn’t new. There were scandals many years ago about subliminal techniques in advertising, and advertys are regulated to prevent the blatant techniques that some ad agencies would like to use. The trouble is, it’s difficult to ‘rule’ on these topics, because it’s all open to interpretation. For example, is this an advert for a sandwich…

a-suggestive-burger-king-ad

Or is it a pretty obvious, and crude and blatant comparison to oral sex? Now prove that in court…

The difference between ‘fuzzy’ issues like that, and F2P games using dodgy practices is that it’s pretty easy to regulate F2P to curb it’s worst excesses. For example, if a game actively prompts the player to purchase add-ons within the game, than I don’t think it’s fair to call the game ‘free’. No game should allow you to purchase more than ten times in a day, or more than some limit per week, and above a certain amount, they absolutely should ask you to re-enter your password, or confirm that you know you have spent $1,000 on gems this week.

Some people are addicted to alcohol, even though most of us aren’t, so we as a society tolerate warnings on advertising and branding pointing out the dangers, and in the UK we ban drinks ads in many environments. The same is true of Gambling. Most people who drink, or bet are not addicts, but we place curbs and restrictions on those activities because we know to some people they are VERY addictive.

Alcohol makers and Betting shops got lucky, they happened to create a product that was already addictive to us. People who employ psychologists for their F2P game are Actively and KNOWINGLY working to generate addiction in their customers so as to milk them as much as possible. Profiting from selling games is fine. Knowingly creating a marketplace full of addict by using psychological tricks is not an entertainment industry I want to be associated with. Legislate the crap out of them.