Bugs and Feature Requests for PlanetsCentral and other VGAP software

[Posting] Rob Failed
Thread opener
Posted Sun, 2020-06-28 19:25 GMT

Fairly often when playing the Privateers I get this message:

We have encountered an enemy ship in space, but we haven't been able to board it.
Our transporter chief says this was just a random misfortune that can happen from time to time.

But almost always I don't think it's a real rob failure. Is it possible that PHost checks all ships with mission Rob and applies the random chance-to-fail, and sends that fail message even if there wasn't any enemy ships for it to rob? If so, wouldn't it make more sense for the fail-check to happen only if a ship is actually attempting to rob an enemy? Or is there another explanation as to why I'm seeing this message so often, yet never seeing any of these mystery unrobbable enemy ships?

[Posting] Re: Rob Failed
Posted Sun, 2020-06-28 20:49 GMT

I have read somewhere there is a 1% default chance of failing the rob. So perhaps, you have wasted your 99 sucesfull assaults and this time the victim escaped unharmly... :eek: :tongue:

[Posting] Re: Rob Failed
Thread opener
Posted Sun, 2020-06-28 21:40 GMT

I have read somewhere there is a 1% default chance of failing the rob.

Yes, that's not in question (the default RobFailureOdds is 1).
What is in question is why I'm getting messages about a failed rob when there is (as far as I can tell, especially from how frequently I get this message) no enemy ship there to rob.

What it looks like to me is the logic is currently:

if (rand(0,100) < RobFailureOdds) then
  SendMessage("Rob Failed")
elseif (EnemyShipPresent) then
  RobEnemy()
end

But I think it should look like

if (EnemyShipPresent) then
  if (rand(0,100) < RobFailureOdds) then
    SendMessage("Rob Failed")
  else
    RobEnemy()
  end
end
[Posting] Re: Rob Failed
Posted Mon, 2020-06-29 19:15 GMT

Hi James T. Plagerism,

your analysis is pretty much to the point: PHost decides once that the mission will fail ("oh crap, I cannot get the engine to start. I'm back in my bunk."), not for each found victim ship ("oops, we cannot get through their shields; let's try the next victim").

This means you'll always rob all or nothing.

It has always been this way in PHost. It started getting visible when I added some messages to tell you why nothing happened. But it can be proven even without messages: given a universe with 20 groups of 1 Privateer MCBR and 24 Fed MDSF each, we'll get a result like this (number of ships robbed per group):

 24  0  0  0  0 24  0  0 24 24 24  0 24 24 24 24  0 24 24 24

Interestingly, Tim-Host uses the other interpretation and rolls a die for each encountered victim. The same test case looks like this in THost 3.22.40:

  8  8  9 13 13 14 10 14 13 13 14 15 12 14 14  9  9 11 12  9

I tend to consider Tim's behaviour more logical here, especially given that RobCloakedChance works the same way (tested for each victim) also in PHost. Any other opinions on that matter? Then I might even change it :smile:

--Stefan

[Posting] Re: Rob Failed
Thread opener
Posted Mon, 2020-06-29 21:06 GMT

PHost decides once that the mission will fail ("oh crap, I cannot get the engine to start. I'm back in my bunk."), not for each found victim ship ("oops, we cannot get through their shields; let's try the next victim").

I tend to consider Tim's behaviour more logical here, especially given that RobCloakedChance works the same way (tested for each victim) also in PHost. Any other opinions on that matter? Then I might even change it :smile:

I think per-ship makes more sense. If you could make the change then all the Pirates in the galaxy will thank you... and everyone else will be mad. :tongue:

Separate from the decision to change the rob failure from per-turn to per-victim, I think PHost should definitely be changed to only send a message about the rob failure if there was a viable target for robbing, if the mission is set to rob but there are no potential victims around then the Pirate wouldn't really know if things were going to fail because they never tried. It just adds confusion to the Pirate player seeing false warnings about robs that never happened.

But if you're willing to change the PHost behavior for RobFailureOdds (and the documentation, of course) then I'm all for that.

[Posting] Re: Rob Failed
Posted Tue, 2020-06-30 19:46 GMT

Hi James T. Plagerism,

your analysis is pretty much to the point: PHost decides once that the mission will fail ("oh crap, I cannot get the engine to start. I'm back in my bunk."), not for each found victim ship ("oops, we cannot get through their shields; let's try the next victim").

This means you'll always rob all or nothing.

It has always been this way in PHost. It started getting visible when I added some messages to tell you why nothing happened. But it can be proven even without messages: given a universe with 20 groups of 1 Privateer MCBR and 24 Fed MDSF each, we'll get a result like this (number of ships robbed per group):

 24  0  0  0  0 24  0  0 24 24 24  0 24 24 24 24  0 24 24 24

Interestingly, Tim-Host uses the other interpretation and rolls a die for each encountered victim. The same test case looks like this in THost 3.22.40:

  8  8  9 13 13 14 10 14 13 13 14 15 12 14 14  9  9 11 12  9

I tend to consider Tim's behaviour more logical here, especially given that RobCloakedChance works the same way (tested for each victim) also in PHost. Any other opinions on that matter? Then I might even change it :smile:

--Stefan

hold on pls. This looks cracy. The rob failur odds for PHost is usually 1%. Which means a mean of 0.2 in 20 stacks. Which is far far far far far away from 8. (maybe 16 sigma?)

Is this check done for every ship to rob, so you rob 24 ships you got a rough 24% chance for complete fail?? Does that mean I can protect my ships against robbing by banding them together???

Then again I can't explain the THost numbers with anything around 1% chance. If that roll is done for any MCBR and victim separetely than it looks like 50% failur odds and you got lucky.

[Posting] Re: Rob Failed
Posted Wed, 2020-07-01 15:53 GMT

hold on pls. This looks cracy. The rob failur odds for PHost is usually 1%. Which means a mean of 0.2 in 20 stacks. Which is far far far far far away from 8. (maybe 16 sigma?)

For the test, I used RobFailureOdds=50, sorry for omitting that detail.

With the default of 1%, there would be a good chance to see only successes and not being able to clearly divide between both variants.

This test is going into an automated testsuite which classifies 100+ host versions into "good" or "buggy". With a RobFailureOdds=50, seeing 24 successes in THost is essentially impossible (that's a 1-in-16-million chance, the RNG probably doesn't even have that much entropy).

--Stefan

This is a testing version.
It may be incomplete, and have more bugs (or features) than the public live version at planetscentral.com.