Game Design, Programming and running a one-man games business…

Cross platform angst and my hatred of middleware.

I do not have cross platform capability. if you play my games on linux, it’s through WINE, and if you play them on Mac, they were ported by a third party company. In the long run, this is likely to be a business weakness of mine. The ipad is great, and I can see it’s a huge market. Inexplicably, people seem to want to play games on phones, and with Microsoft making it more and more difficult to let people just download an exe from the internet, and the dominance of portals online approaching 100%, a move towards html5 or php / flash games seems like a sensible move in the long term.

Of course, people say that the down-loadable PC market is huge and not to worry, but I’m thinking 10,15 years ahead. if I’m still in PC gaming in 15 years, I need to think on those sorts of timescales. (I’ve been reading lots of warren buffet, it’s affecting me :D)

I recently checked out unity, because a top-secret-side-project-i-wont-discuss-yet is being developed in unity, and I’ve never even seen it. I was immediately put off. I can see how for many developers, unity is AWESOME. It certainly provides a ton of tools, functionality and easy-to-use stuff. It seems a lot of the fiddly, hard work has been done for you.

The problem is, I just HATE middleware. I don’t like the way other people code (as a rule, ancient-james excepted), I hate it when documentation says “you can ignore this coding concern, we handle it under the scenes” and I fear black-box code which promises to be ‘optimised’ but doesn’t tell you how, or with what assumptions.

I hate the fear that a bug will crop up after I ship, and not only can I not find it, I can’t fix it even if I could. That sucks big time. It’s rare, but not unknown. Plus I fear that ALL middleware has been built with certain limitations, and certain assumptions. Make no mistake, Unity is designed for 3D real time games. It might be ok to make a 2D turn based game in it, but you will be fighting against the tide, not with it, and carrying a lot of 3D engine bloat with you.

I celebrate the existence of unity for making many devs lives easier, but so far (I may be converted), it really isn’t for me. I like to code from the ground up, with complete control of everything. I’m a guy who uses char* and fopen(). By 2025 I might have moved entirely to std::string and CreateFile, but don’t hold your breath. Also, there is an element of ‘if it ain’t broke…’. I’ve made quite a few games with my own engine, so maybe I should build upon that, not throw it away in favor of someone else’s code?

A decision for after GTB ships, methinks.

 


16 thoughts on Cross platform angst and my hatred of middleware.

  1. I hear ya! I’m writing an (open source) game engine for Flash. I plan to write some more intricate games with it like my own version of a CRPG complete with custom rule system. The problem I have with such middleware like Unity is that it typically fits one shoe very well (let’s be honest, for most engines this would be the 3D First-Person-Shooter shoe) but I don’t want to take an engine that is predestined for 3D FPS games and make a turn-based 2D (or 3D) RPG with it (like Bioware did with taking the Unreal Engine and making Mass Effect and then calling it a RPG).

    I like having customization ability on the code-level. Like you say, 2D games can be made with Unity but it feels tacked onto a huge 3D engine and there always certain, fine but important compromises you have to make when going that way. In my own engine I can decide about the whole application execution path by myself but with Unity I would have to follow their execution path.

  2. I understand where you’re coming from BUT you’re also, slightly arrogantly, assuming that everyone else (e.g. the middleware developers) will make mistakes and you won’t.

    You’re also missing the fact that they just know stuff you don’t – stuff you could take advantage of to make a better game, quicker.

    I realise that it’s a nightmare when a problem occurs which isn’t in your code but what you’re forgetting is that they already made millions of mistakes AND corrected them and they’ll keep on doing that.

    You can’t really avoid other people’s code anyway – even the lowest-level code relies on stuff like GPU drivers – most PC developers are reliant on DirectX (or OpenGL) and console/mobile developers on a RAFT of code they cannot directly control.

    and it really is a control issue – you want to control EVERYTHING and whilst that it’s a bad thing in itself, it’s a limitation on what you can do and – most importantly – how long it takes – and time is the most valuable thing of all.

  3. A book thats basically extracts from all his shareholder letters over the years. Very very interesting. Makes you realise how insane many stock traders are, and how most of them are ‘speculators’ and not true investors. He is my new business hero :D

  4. You may want to talk arcen games. AI war was originally their own engine and then they made the switch to the Unity engine. (Also it happens to be a 2D game done in Unity as well).

    Experiences from another indie developer won’t hurt any decisions me thinks.

  5. I think the problem would be that you have invested a lot of time and effort into technology that works, using DirectX.

    Now if you made your game engine modular enough then you could use the Unity engine as the graphics/physics layer.

    I think another indie went from XNA to Unity but blogged about just using Unity as a presentation layer.

    To be honest it would be easy to throw together a prototype that would give the unit game engine a GSB graphics throughput test, you could give it a whirl in the free addition, moving around lots of large sprites, particles, lazer beams ect.

    You could even take it to full 3D, but you would probably be limited to top end hardware!

  6. Middleware is fantastic. I use it whenever I can. If Unity had been in the condition it is now when I started my current project, I would likely have used it. That said, I only use middleware where I get source and the right to modify it. I’ve found compiler bugs in Visual Studio, OS bugs in various versions of Windows, and trying to get other people to fix their bugs is a gigantic waste of effort. One gigantic timesaver for me was using Berkelium to embed the Chrome web browser for my UI. You can read about it here: http://www.onemanmmo.com/index.php?cmd=newsitem&comment=news.1.31.1 (I need to get that URL shortener code I’ve been thinking about going :)

  7. I’m biased towards Unity, so that significantly colors this comment.

    I respect any engineer’s ability to code and fine-tune their work from scratch. Hats off to you all.

    But I also like being able to produce a finished cross-platform game in a handful of months, on my own. So there’s that.

    And really, at the end of the day the majority of users only care if the game runs competently on their system of choice, something that Unity facilitates well be it a 2D or 3D project, regardless of bloat.

    The path Cliff takes is either one of the significantly skilled, or ego-maniacally control-freakish. Or both. Personally, I don’t have the time nor income to be either. Yet.

  8. Yep, I agree to an extent, I’ve had my own dev libs,tools,engine since 1997 and I’ve built on top of and used that ever since for all my own projects (and a couple of work projects too).
    Only really in the last couple of years starting using middleware libs at home (havok,Lua,LibCCD,PropertyLib,Bullet etc.), but hit some really serious performance issues with Newton then Havok and then Bullet which all have the same performance issues, this then pushed to write my own physics solution, arrogance did spur me on but I gave it a real go trying to use those libs.

    It’s great because I have full control and fully understand how it all works, but it took a lot of time away from what I was meant to be doing. So in the end it’s a balance, some areas you want full control and understanding, others you’re happy to use a damn good library and just accept you just don’t have the time to do it all.

    This is one of the main reasons I convinced Lionhead to start using Unreal 3, we always spent the time writing the tools, pipelines and tech before writing anything to do with the game, although using Unreal there’s a lot to learn and feels like you have little control for quite a while, we get to the game faster and in time we gain back the control. (though I wouldn’t use it at home, still too arrogant for that ;-) )

  9. If you are seriously thinking about switching to unity, maybe you should get in contact with http://www.arcengames.com, creators of AL War: Fleet Command and Tidalis. They converted AI Wars over to unity (from their own engine) last year, and the game hasn’t seemed to have suffered in the slightest for it.
    The game is top down 2D real-time, maybe they would share their experiences with you?
    P.S I am not in any way associated with arcen games in anyway.

  10. I hear you, and understand where you’re coming from. I’ve been messing around in Unity for about a year now (no, I haven’t published anything, too busy with my day job, but I will, someday, oh yes). One of the first things I set down to figure out was how to break out of their editor, and take more control of the environment. Sure, it’s great to be able to build levels in their nice, friendly GUI, but my stuff is mostly procedurally generated, so that gave me nothing, and their file structure wreaks havoc with version control if you don’t have the $2500 commercial version.

    The trick, then, is to develop on it similar to how modern Flash development works: almost entirely dump the GUI and just develop in a traditional IDE. In this case, use Visual C#, which is honestly just about the best IDE available for any language, on any platform. Compile to a set of .NET DLLs, which go into the Assets folder. Use your own custom GameData format (I just used JSON text files). Create exactly one class that extends MonoBehavior, in your main library, and use that as the entry point to your code. Finally, create a super-simple scene which is nothing but a single GameObject that uses that MonoBehavior. My Assets folder contains a libs folder, for my DLLs, a gamedata folder with my JSON files, a Resources folder with all the artwork (so I can load it dynamically), and that single simple scene file, and that’s it.

    Then from here, manage the whole thing from code, as you would in a more traditional environment. You still get the scene graph, the physics engine, the input abstractions, the multi-platform compiles, and a pile of other stuff from Unity, stuff that would take me a year or two of extra work to implement myself, but I get to discard most of the limiting baggage of the GUI.

    You’re still subject to any bugs that exist in Unity itself, and that’s frustrating. However, it’s not the killer you seem to think. In my last job, I was a Flash developer, and let me tell you, Flash is one of the most terrible, buggy, POS bits of middleware in any kind of common use. Yet, every single bug or bad behavior we encountered in Flash, we were able to find a work-around for. It was obnoxious, but we weren’t a slave to Flash’s problems. We just hacked around them. And Unity is a million times better than Flash. It has some weird design quirks, but unlike Flash, it’s quite stable and works as documented.

  11. Are you planning on licensing your own engine to other developers and does it fill a need that exists in the market? If not, you’re reproducing other people’s work inefficiently and expensively, and in a market that doesn’t care if the game was made on an in-house engine or middleware.

  12. Curious what your thoughts are on tech like Google’s Native Client (http://code.google.com/chrome/nativeclient/)

    It allows native code to run in a browser… some say it’s like a VM in the browser..

    Personally, I’d like to see this idea standardized across browsers/devices and allow for pluggable languages.

    Till then, it’s probably not going to be that useful.

    -Jeff

  13. It isn’t that hard to make a 2D cross platfrom lib. Like you, my lib was DirectX win32 only. Almost a year ago, I started ported to OpenGL and now, I’m the lucky owner of a cross platform 2d lib capable to compile my games on: PC/Mac/iOS and soon android with the EXACT same code base… Meaning that my games compile and run IMMEDIATELY on all these paltforms. I’ve dump some feature and the lib is really low tech but what a great move it was. You should take the time to do it yourself. You’ll be surprise how little code need to be platfrom specific… And what a joy to port a game from PC -> Mac in just few minutes (the time to set-up XCode with the src code and data) and from PC -> iOS in days (not having a mouse usually mean I have to rework the interface, but the game does run like the PC version in minutes too).

  14. Some middleware is really ok and saves you alot of headache if it’s written by competent people. (take recast for example). Whole engines Unity &co is a whole different topic and I agree with your take on it.

  15. Interesting, I was about to plunge into unity a while back, but coming from a background of flash development, so my considerations were quite different, being very much middleware itself. Flash is looking to have comparable 3d capabilities anytime soon as well.

Comments are currently closed.