Author: Normand M. Blais
Date: 14:51:42 01/08/03
Go up one level in this thread
Hi Dann,
Thank you for answering my post. I have one question: what is the meaning of
"numjug" in the function below? I know that "mv_ctrl" means "moves to time
control" but "numjug"?
NMB
>Here is Pepito's time managment routine:
>//------------------------------------------------------------------------------
>entero32 AllocTime(int mv_ctrl, int numjug, entero32 time_left, int inc)
>{
> entero32 allocated;
> if (inc) {
> return (entero32) (inc * (time_left / ((float) time_left + inc)) +
>time_left / 35.0f + 0.5f);
> } else if (mv_ctrl) {
> allocated = (time_left / (mv_ctrl - ((numjug / 2) % mv_ctrl)) * 80 /
>100);
> if (time_left < 1000)
> allocated = allocated * 80 / 100;
> } else
> allocated = time_left / 40;
>
> CONTROL_INC = allocated > 300 ? 50000 : 20000;
>
> Log("mv_ctrl: %d, time_left: %d, allocated: %d\n", mv_ctrl, time_left,
>allocated);
>
> return allocated;
>
>}
This page took 0 seconds to execute
Last modified: Thu, 15 Apr 21 08:11:13 -0700
Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.