[Bug] Transmute resources using Buccaneers


#1

###Summary: By recruiting multiple buccaneers on one ship and then cancelling them in a different order , one can end up with a different distribution of special resources than one had at the start.

Steps to reproduce: Start the turn with 2 Octopus, 2 Serpent, 1 Clam, 1 Mermaid. Recruit Ballooner. Recruit Pointer. Cancel Ballooner. Cancel Pointer. Now have 1 Octopus, 1 Serpent, 2 Clam, 2 Mermaid. (See below for visual steps)

Reproducibility: Every time

Severity: Moderate (Makes it easy to obtain any distribution of special resources)

Expected Results: After cancelling all buccaneer recruitments, one should have the same resources one started with.

###Example:
Initial resources:

  1. Buy Ballooner:

  2. Buy Pointer:

  3. Cancel Balloner:

  4. Cancel Pointer:

Final comparison:


#2

That does look like it’s something that can be exploited. I’m not sure how it’s code, but I think something like a queue might work.

I assume each ship has an attribute of the existing number of Buccaneers on the ship at the turn’s start. For my example, let’s say it’s 0. Let’s also say that the player has 10 of each resource at the start of the turn. The player queues up 5 buccaneers on a ship. The resulting queue would look like this:

Now let’s say that the player decides to cancel the build for the Scoper, at list rank 3.

The player gets the 3 serpents and 3 mermaids back, and the Bosser and Sneaker move up 1 slot each in the queue.

In the process, he would gain back 1 mermaid, whale, octopus, and clam.

As long as the queue is run through every time a change is made to it to reconcile the expenditures, I think this would work.


#3

Good catch @Bessel!

You’re right @penguiniffic, we’ll have to record he purchase order and refund accordingly. Although it might still be a bit weird if they refund only the purchase that cost 1/1, and they order something else while they have other Buccaneers still ordered, they’ll miss out on a 1/1 price.


#4

@IHG-BlightedPea - in my example, if the Ballooner was canceled, the player would get 1 clam and 1 mermaid refunded. Then when the rest of the queue is reconciled, 1 octopus and 1 serpent would be refunded as the Pointer moves up to the #1 slot in the list. By virtue of that, the Pointer now becomes the 1/1 price I believe.


#5

But shouldn’t the refunding process cascade through the other purchases?

Player purchases three buccaneers: Ballooner 1/1, Pointer 2/2, Bosser 3/3.
Player refunds Ballooner.
Other purchases get retroactively adjusted: Pointer 1/1, Bosser 2/2


#6

Yes that would work. Might be a bit confusing where the extra resources came from on refund.

The other alternative is that you can only hire 1 Buccaneer per ship per turn.


#7

It could definitely be confusing - I can see that. I wonder if you put an events tab for each ship that keeps track of all the upgrades / purchases / refunds? That way, if someone is confused, they can click over to that and it would show:

  • Purchase Ballooner: cost 1 clam, 1 mermaid
  • Purchase Pointer: cost 2 octopi, 2 serpent
  • Cancel Ballooner: refund 1 clam, 1 mermaid
  • Refund Pointer: cost adjustment 1 octopi, 1 serpent

#8

I don’t think it would be that confusing where the resources came from. Up until I discovered the bug, that’s how I assumed things worked to begin with.

I personally really like being able to hire multiple buccaneers in a turn. I don’t like having to plan things in advance, and I like betraying my plans to my opponents (e.g. by hiring a slaver/dredger as I approach another ship). That said, I have felt at times that Buccaneer purchases work quite a bit differently from Attack/Health/Armor upgrades, since the upgrades can only increment at most +1/+4/+1 each turn.


#9

I personally don’t think you should be able to hire Buccaneers while at sea. Aside from those acquired from slaving, all buccaneers should be purchased while at port at a settlement, but that’s a conversation for another thread (indeed there already is such a thread).