Cape Guy

  • Games
    • Re-Entry
    • Ski Three
    • 80 Days on PC and Mac
  • Blog
  • About
    • About
    • Friends
  • Contact

A* for All

22 January 2016 By Ben

A while back, I found myself looking for a simple C# implementation of the A* (pronounced ‘A Star’) path-finding algorithm to use in 80 Days for finding routes between cities from the raw map route data used by the game.

If you’re not sure what the A* algorithm is or how it works then there’s a good introduction to it here. Alternatively, there are or some pretty nifty video tutorials about implementing it in Unity here.

I did find a few available implementations out there but wasn’t really happy with any of them. Some had a lot more code than I thought the algorithm justified – which I generally consider to be a warning sign. Some of the them required the graph to be specified ‘up front’ meaning that you couldn’t use lazy evaluation techniques to allow searching of non-finite graphs or to get good performance where there is a large overhead of looking up graph information. Others relied on an underlying grid pattern to the graph, which isn’t very useful for a lot of situations.

In the end I decided to implement my own and thought I would share it in case anyone else could benefit from it.Continue Reading

Porting 80 Days from Native-iOS to Unity

18 November 2015 By Ben

While first getting started with Cape Guy, I also discovered 80 Days on my iPad. I absolutely loved it and, after a surprising response to a tweet, discovered that Inkle were also based in Cambridge. I already had plans for a first project but, having recently read The Lean Startup, was willing to pivot early, in this case before even actually starting in the first direction! Now THAT’s what I call being agile!

I’d always planned on building up a series of increasingly ambitious projects using Unity, which I’m still doing, but saw an opportunity for both Inkle and Cape Guy. I emailed them and we met up in the pub a few days later. It turns out that Jon and Joe are both really great guys and we got on straight away. An hour or so later we were discussing me doing a PC and Mac port of 80 Days, using Unity. Inkle could release a game to the PC market – which they’d been considering doing for a while – and I could get comfortable using Unity while not having to worry too much about game design (one step at a time!)Continue Reading

Unity Auto-Save on Play in Editor

9 July 2015 By Ben

Years of experience (specifically a few bad experiences) have taught me to save my work as often as possible. Because of this I have a tendency to save my Unity project and scene pretty much every time I enter play mode to test something. After a while I thought I’d try and automate this process so I wrote an editor script to do it for me.Continue Reading

No More Unity Hot-Reload

22 June 2015 By Ben

[Edit: There’s an update to this post – Disabling Assembly Reload While in Play Mode]

As you can probably tell by now, I think Unity is great. I’ve never had such awesomely short edit & test cycles on a games project and I really value them. However like almost everything, Platonic Solids aside, it’s not perfect.

There’s one situation in-particular where Unity does something entirely unexpected (at least to me) and quite annoying:

  • You’re debugging an issue, sitting at a breakpoint and you work out what the problem is (Yay!)
  • You make a quick edit of the code, save the change and return to the Unity editor
  • All is good. Things seem to be running happily again and then…
  • BAM! There are loads of unhandled (mainly null-dereference) exceptions and you can’t seem to skip past enough of them (all your want to do is get out of play mode) so you eventually give up and just detach the debugger.

Continue Reading

« Previous Page
Next Page »
  • E-mail
  • Facebook
  • LinkedIn
  • Twitter

Latest Tweets

  • Just finished ironing out a few glitches in #ReEntry's space-time continuum #IndieDev #gamedev https://t.co/jhT2CWPSQd 26 February 2019 10:31 pm
  • #SkiThree version 2.0 is out! Loads of improvements, and it's now Pay Once and Play! https://t.co/LiPMP4QtkI #madewithunity #unityawards 30 September 2018 10:41 am
  • I’ve been blogging about disabling @unity3d editor's Assembly Reload feature while in play mode again:… https://t.co/GmdgVVtH8h 12 June 2018 11:44 am

Copyright © 2025 Cape Guy Ltd.