How I Broke Neptune’s Pride 2

Gaming is an intuitive hobby, and there are some problems in the gaming world only a human can solve. Whether a game is “fun”, is wholly subjective. But through the use of a fun spreadsheet trick, it’s possible to achieve near perfect balance by isolating a game’s overpowered strategy. For fun, I used it in Neptune’s Pride 2 — and became overpowered in the process.

Shuffled away in my “Other Bookmarks” folder in Chrome is my group of bookmarks called “Design Crap”, where I put all the game design theory stuff that no one else on the media side of things seems to be interested in. Everything in that folder is fascinating to me. Articles about designing combat systems, what we know about human senses and how that effects our perception of game aesthetics, and of course, the psychology of game design, unethical and otherwise.

While I don’t get as much time as I’d like to sit and explore that folder, I’ve made time for one blog which has held my interest for months, called The Intelligence Engine, in which a man named Paul Tozour explains how techniques used in finance and other operational roles are changing one of the oldest pieces of accepted wisdom in game design: that there’s no formula for fun.

Using evolutionary algorithms, Tozour is able to simulate hundreds, thousands of games on a computer to find the ideal strategy for his two-player competitive tower defence game, City Conquest. The algorithms throw insane amounts of numbers at the problem, and return the best result. Balance, and the desired types of balance, is a necessary element of fun in such games. That makes this technique a valuable tool in finding the fun in a system, and something a QA team could only accomplish with considerably more time (and cost).

Tozour uses the algorithms not only to balance test games, but also to make design decisions. As the blog shows, it’s just as useful for finding the optimum locations for galactic warp gates if you want them as close as possible to particular planets, or calculating the quickest paths between all your objectives. Machine learning is growing in popularity in development circles, and I interviewed Tozour about the technique in the first issue of the new Grab It Magazine.

The most fascinating thing, however, is the ease of participation. These aren’t big, expensive tools or algorithms we’re talking about. Sure, those exist — but everything mentioned above can be done in Excel, or LibreOffice. Anything with a Solver tool using genetic algorithms. I had to have fun with this.

So began possibly the nerdiest thing I’ve ever done, and I loved every second of it. Loading up LibreOffice, my goal was to optimise the first seven turns of Neptune’s Pride 2. The 4X genre is ideal for this kind of theorycrafting — with all the formulas in place, one can start a new game, enter in all the variables, and have the spreadsheet solve for the ideal player moves. Whatever the game requires — tax rates, infrastructure built, etc — the algorithm can calculate exactly what you should do for the optimum result. The perfect build order.

NP2 is about building ships to conquer stars, to build more ships, to conquer more stars. I built my spreadsheet around the amount of ships built by my empire, up to the seventh turn, then told the Solver to optimise the “Total Ships Built” cell. It was a massive spreadsheet, riddled with errors, and the first few (okay, many) attempts yielded no results. Even with the errors fixed, the Solver was crumbling under the weight of myriad variables. I had included Economy, Industry, and Science buildings on each star, as well as what Science I should be researching at any given point in time. As Science affects infrastructure and vice versa, it was a loop of variables feeding back to each other. And amongst it all was a complex formula (and at one point referring to a separate Python script) to calculate the cost of buildings, the cost of which rises if you build more than one in a turn.

It wasn’t going to work until I reduced variables, so I found a few shortcuts: It’s fair to say that when you start researching something, you don’t change halfway through, so I took out the variables for what to research every single hour. Then I removed it altogether, since the Solver would always tell me to research Manufacturing, and in reality, early game empires should be trading for all tech anyway.

Then I took out the ability to get more than one building at any star during one turn, since that’s rarely done in the early game — even though it broke my heart to discard those toiled-over formulas. A few other smaller shortcuts later, and tweaks such as making sure the Solver spent as much money as possible every turn, and it was working. I would tell it to optimise my game of NP2, and it would spit out a number. After playing around with the numbers in the spreadsheet, I found that I couldn’t improve the result at all.

To test it, I brought on the help of former GameArena editor Joab Gilroy, with whom I regularly play Neptune’s Pride 2. We played an isolated 1v1 game, in which I was able to bring 844 ships to bear against his 549 on the eighth turn. I deemed it a success.

Next was testing it in the wild, where no amount of theorycrafting would save me from the fundamentally diplomatic nature of the game. Two vs one never goes well for the one in NP2’s early game. But if I could avoid being double-teamed, I should be able to make a decent start.

After a few 8 player games, and a few 64 player games, the spreadsheet continues to win. Sometimes the scientific test itself is ruined by an AFK or some diplomatic happenstance, but no matter the game, whoever the poor schmuck next to me is has the maximum amount of ships possible coming their way before long, and I gobble up that empire for a good start to the game.

It’s a good bit of fun, if you’ve got the dedication, and I’ll be looking for other games to try and break using the same method. To some, it’s understandably a little farther than they’re willing to go in terms of formulating the ideal strategy, and one friend even described it as hacking. But it’s an enjoyable new way to theorycraft, while teaching oneself about spreadsheets and algorithms, not to mention a new aspect of game design.

The Cheapest NBN 1000 Plans

Looking to bump up your internet connection and save a few bucks? Here are the cheapest plans available.

At Kotaku, we independently select and write about stuff we love and think you'll like too. We have affiliate and advertising partnerships, which means we may collect a share of sales or other compensation from the links on this page. BTW – prices are accurate and items in stock at the time of posting.


3 responses to “How I Broke Neptune’s Pride 2”