Page 1 of 1

WOK4 Online Battle Odds Calculator

Posted: Wed Jan 07, 2004 9:04 pm
by Mullog
Just for fun I have written a new battle odds calculator for WOK4. It will run 5000 battles and report the average results. The number of armies, levels, and so on, you specify.

The calculator can be found on my web server: http://rag.no/wok/AttCalc.php

You are free to use this as much as you want, but please tell me what you think of it!



Mullog

Posted: Wed Jan 07, 2004 9:15 pm
by gm_al
Alternative link on the WOK server:

http://kaomaris.com/AttCalc.php

Thanx for that great tool, Rune !! A showcase of what KaoBase V2 will be in terms of good work....

Posted: Thu Jan 08, 2004 11:06 am
by Polymorphic
And there I was ThinKing this had been done before...

Posted: Thu Jan 08, 2004 11:48 am
by Saladin
Yeah Martijn van der Kooij had one in his MKKaoView, but Rune's battle calculator is an online version! :D

Posted: Sat Jan 10, 2004 10:42 pm
by Mullog
Saladin wrote:Yeah Martijn van der Kooij had one in his MKKaoView, but Rune's battle calculator is an online version! :D
I hadn't noticed this version until now, but I must agree that they are remarkably similar! The only one I knew of was the one called Battle Calculator for WOK4 (V2.5). I tried to use it once, but it was so slow that it took several minutes to calculate the results on a fast computer! That was my reason to write my own... I actually wrote two calculators. The first one was in Excel, but then I got the idea that I could write an online version! And here it is...



Mullog

Posted: Sun Jan 11, 2004 6:47 pm
by Saladin
Mullog wrote:The only one I knew of was the one called Battle Calculator for WOK4 (V2.5). I tried to use it once, but it was so slow that it took several minutes to calculate the results on a fast computer!
Yeah it was pretty crap...but still thumbs up for the effort Craig. :lol:

Posted: Sun Jan 25, 2004 3:06 pm
by korexus
The old calculator is slow because it runs in Q-Basic, which is DOS based and windows doesn't like it. :wink: It used to be faster, honest.

I just tried using the online version and spotted a bug. You appear to be rounding the PATT and PDEF to the nearest integer for calculations, wheras WoK 4 uses the smallest integer less than or equal to the power. It doesn't make a huge difference andisn't hard to fix. But i htough you should know... :)


korexus.

Posted: Sun Jan 25, 2004 3:19 pm
by korexus
Two more points:

If both the PATT and PDEF are 0, the manager will set them both to 1 in order to stop a continuous draw. (TK's calculator doesn't do this either but I never could get him to change it...)

And, rather weirdly, when I tried inputting EFFs of 1 for attackers and defenders, they got change to 100 and 99 respectively.

Neither of these points is especially important as they'll only ever come up if both people fighting have EFFs of less than 10. (Even lower if level or defence are good) But if you want everything to be neatened up you may want to check them. :wink:

~korexus. Bug finder extraordinaire!

Posted: Sun Jan 25, 2004 4:09 pm
by Bjorn
I didn't use the WOK4 calculator much, as it is fairly easy to come up with the expected loss ratio if you know the PATT and PDEF at the start of the battle. Sure, there might be a slight change due to the loss of DEF along the way, but nothing major. Given the chance of a slight rounding error, then if PATT>PDEF, then the expected loss ratio is ((PATT/PDEF)-.55)/.45). The loss ratio is number of expected defender losses for each attacker lost.

If PDEF is greater then just swap PATT and PDEF in the equation and the result is the expected number of attackers lost for each defender.

Still waiting for the WOK5 battle calculator. Now THERE is something useful.

Posted: Sun Jan 25, 2004 5:32 pm
by Brykovian
Bjorn wrote:Still waiting for the WOK5 battle calculator. Now THERE is something useful.
Yeah -- something like that would be *amazing*! ;)

-Bryk

Posted: Sun Jan 25, 2004 7:36 pm
by Polymorphic
Brykovian wrote:
Bjorn wrote:Still waiting for the WOK5 battle calculator. Now THERE is something useful.
Yeah -- something like that would be *amazing*! ;)

-Bryk
Just give me until I've learnt the WOK5 rules then :)

Posted: Mon Jan 26, 2004 7:50 pm
by Mullog
Ah! Bugs!

They will always be there. But I will try to fix them. :)

I am sure a WOK5 calculator would be useful, but there wont be one unless I have a WOK5 game to play... Still waiting for a certain game to start...

Posted: Mon Jan 26, 2004 10:39 pm
by korexus
No, I can't imagine how long it would take to write a WoK 5 calculator. With all the troop types and everything combat would be a nightmare!
And if you got tempted to put in bits for the other parts of WoK 5. (economy and so on) it could take *years*...

korexus

:wink: