Stupid or unlucky?

Discuss anything related to warbarons.

Stupid or unlucky?

Postby Zajoman » Mon Aug 30, 2010 6:03 pm

My hero has 2 command. The Spider is in a level 2 city so his strength is 9. I know, but 8 guys with at least 4 and at most 8 strength deal one single hit? Is this supposed to happen? Or should I rely only on superoverwhelming odds?
Attachments
StupidOrUnlucky01.png
StupidOrUnlucky01.png (89.65 KiB) Viewed 6880 times
StupidOrUnlucky02.png
StupidOrUnlucky02.png (102.32 KiB) Viewed 6880 times
Zajoman
 
Posts: 107
Joined: Thu Aug 12, 2010 6:56 pm

Re: Stupid or unlucky?

Postby KGB » Mon Aug 30, 2010 8:39 pm

Zajoman,

Welcome to the world of insane battle results :cry:

I've posted a long thread (insane combat rolls) on this very topic before and others have weight in on it.

Battles like the one you just experienced totally ruin games. My belief is that the game *must* have a averaging function in it to drop all results that fall outside of a 90% combat normal distribution (in other words if 8 light infantry fight 8 light infantry the winner should always have between 1-3 men left, none of the extremes where you see one side survive with 5, 6, 7 or 8). What you experienced is <1% (more like 1/100th of 1%) and should be dropped and replayed for being FAR outside the norm.

There is a new experimental combat coming in Beta3 but unfortunately it will do nothing to prevent this kind of result which is the real problem.

KGB
KGB
 
Posts: 3030
Joined: Tue Feb 16, 2010 12:06 am

Re: Stupid or unlucky?

Postby Zajoman » Tue Aug 31, 2010 3:13 am

I agree. And I feel something's wrong with the calculation, too, as this kind of battle happened to me three times in like 5 turns. I was on the verge of conceding that game twice, for two successive turns, just because of those battles. Was these insane results also happening in W2 or DLR? I played DLR recently and I lost a battle the advisor said I would win 9 out of 10 times, but it's still nothing compared to this gem.
Zajoman
 
Posts: 107
Joined: Thu Aug 12, 2010 6:56 pm

Re: Stupid or unlucky?

Postby piranha » Tue Aug 31, 2010 11:15 am

We know that there is a problem with too extreme results, that a couple of extreme rolls can make you lose or win a game and that it ruins the fun.

We plan to do something about it, but we want to be careful when we alter the calculations.
I know that there is one suggestion to run each battle many times and pick something that is closer to the average result.
We are not going to make it work like that for beta3, we are testing another easier solution for beta3.

There are two reasons, the first one is simply that it will take more time to make it so we want to test this other solution first. The second one is all battle calculations are calculated on the server to prevent cheating and PHP is a slow language so if we can avoid something that requires a lot of extra calculation it would be nice.


There also the factor that the battle system used isn't completely easy to grasp in terms of the chance to win or lose.
I'm not denying that extreme results happen but sometimes people think they are more extreme than they are.
If we had used HP which was our original idea it would probably be easier to estimate your winning chances when you know that a unit can deal 10-15 damage per roll and the enemy units have 60 HP each for example.

In the end in some far away beta we might try give this as a game hosting option to see what works the best.

If I look at this example I also think that the attacker should have won.
But I'm not sure its as extreme as it might appear first.
If I'm right it is 14% chance for each STR 4 light infantry to kill the STR 9 spider. Even the heavy cav is only 35% chance to kill the spider.
Its obviously unlucky but it probably looks as way more extreme than what it is.

The beta3 solution will be to have hits for each real hit point that you can set when you host. For example you can have 2 per real hit, or 3 per real hit.
It will reduce extreme outcomes, but it will also make good units better. We want to test that and if there are still crazy results we will work more on this for beta4.
User avatar
piranha
Site Admin
 
Posts: 1189
Joined: Fri Feb 12, 2010 9:44 pm

Re: Stupid or unlucky?

Postby Zajoman » Tue Aug 31, 2010 11:48 am

Piranha,

I cannot agree with you on this. Yes, if you consider individual encounters of 1v1 in that battle, the Spider has a good chance of winning all of them. But the battle is 8v1 so while the Spider starts at a high percentage chance of hitting, every next roll drops his chance of hitting considerably. If the Spider has an 80% chance to hit, he most likely will hit, but the chance of a successive hit is lower than those 80%. In this case, he had 15 successive hits, which would be crazy even against 8 plain Light Infanry units.
Zajoman
 
Posts: 107
Joined: Thu Aug 12, 2010 6:56 pm

Re: Stupid or unlucky?

Postby KGB » Tue Aug 31, 2010 2:02 pm

OK,

I ran this battle through my simulation program.

The results were that you should win 98.2% of the time against the spider. You should average 5.2 men left.

In other words the *average* result is your hero wins with you losing 3 light infantry.

The 90th percentile (where things should be cut off) is that you'd lose the 5 light infantry and 1 Hv Cavalry.

That seems reasonable to me on the worst possible combat result that you'd be left with only the hero + Hv Calv.

Incidentally, I ran this same combat using the new combat system (3 hits for 1 turn units, 4 hits for 2 turn units) and so you get 1 9/4 spider vs 5 4/3 lt Inf, 2 7/4 Hv Calv and 1 8/3 hero (I assumed 3 hits on the hero). The result is the hero wins 99.0% of the time with 5.4 men left. In other words, there is no appreciable difference regardless of which combat system is used. That should be obvious because the spider got 2 more hits at 9 strength while the hero stack got 5 hits at 4 strength + 4 hits at 7 strength + 1 hit at 8 strength which is almost the number of the original battle.

KGB

P.S. I can post the program if anyone is interested though I've posted similar ones before in other threads.
KGB
 
Posts: 3030
Joined: Tue Feb 16, 2010 12:06 am

Re: Stupid or unlucky?

Postby piranha » Tue Aug 31, 2010 2:51 pm

Yes please id would be cool if you post it. It might help testing ideas and others might be interested too.
User avatar
piranha
Site Admin
 
Posts: 1189
Joined: Fri Feb 12, 2010 9:44 pm

Re: Stupid or unlucky?

Postby Zajoman » Tue Aug 31, 2010 3:43 pm

I used your previous program, ported it to JavaScript, ran it and got 100% winning chance from ten million attempts. I have no idea how JS deals with numbers, so I assume the result is not exact, but at least it gives me the idea.
Zajoman
 
Posts: 107
Joined: Thu Aug 12, 2010 6:56 pm

Re: Stupid or unlucky?

Postby piranha » Tue Aug 31, 2010 4:13 pm

Where can I find this program?
User avatar
piranha
Site Admin
 
Posts: 1189
Joined: Fri Feb 12, 2010 9:44 pm

Re: Stupid or unlucky?

Postby Zajoman » Tue Aug 31, 2010 4:39 pm

Code: Select all
int main(void)
{
   int hitsStack1 = 16;
   int hitsStack2 = 16;
   int strStack1 = 6;
   int strStack2 = 4;
   int winsStack1 = 0;
   int winsStack2 = 0;
   int unitsLeftStack1 = 0;
   int unitsLeftStack2 = 0;

   srand(time(NULL));

        // Do this battle 10000 times
   for (int i=0; i<10000; i++)
   {
      while (hitsStack1 > 0 && hitsStack2 > 0)
      {
         int rollStack1 = (rand()%20) + 1;
         int rollStack2 = (rand()%20) + 1;
         
         if (rollStack1 <= strStack1 && rollStack2 > strStack2) hitsStack2--;
         if (rollStack2 <= strStack2 && rollStack1 > strStack1) hitsStack1--;
      }
      
      if (hitsStack1 == 0)
      {
         winsStack2++;
         unitsLeftStack2 = unitsLeftStack2 + (hitsStack2+1)/2;
      }
      if (hitsStack2 == 0)
      {
         winsStack1++;
         unitsLeftStack1 = unitsLeftStack1 + (hitsStack1+1)/2;
      }
      
      hitsStack1 = 16;
      hitsStack2 = 16;
   }
   
   printf ("6 Strength Stack won %d battles with an average of %f units left\n", winsStack1, unitsLeftStack1/10000.0);
   printf ("4 Strength Stack won %d battles with an average of %f units left\n", winsStack2, unitsLeftStack2/10000.0);
   printf ("The 6 Strength Stack winning percentage is %f\n", (float)winsStack1/10000.0*100.0);
}
Zajoman
 
Posts: 107
Joined: Thu Aug 12, 2010 6:56 pm

Next

Return to Game discussion

Who is online

Users browsing this forum: No registered users and 6 guests

cron
Not able to open ./cache/data_global.php