Subversion Repositories Games.Chess Giants

Rev

Rev 154 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 154 Rev 156
Line 1620... Line 1620...
1620
        ch = ascpv[cv_p_cpv[cp]];
1620
        ch = ascpv[cv_p_cpv[cp]];
1621
        if (cv_c_cpv[cp] == c_w)
1621
        if (cv_c_cpv[cp] == c_w)
1622
          ch = map_upper(ch);
1622
          ch = map_upper(ch);
1623
        else
1623
        else
1624
          ch = map_lower(ch);
1624
          ch = map_lower(ch);
1625
        bv[bi++] = ch;
1625
        bv[bi++] = (char) ch; // Pierre-Marie Baty -- added type cast
1626
      };
1626
      };
1627
    };
1627
    };
1628
    if (ps != 0) {
1628
    if (ps != 0) {
1629
      bv[bi++] = '0' + ps;
1629
      bv[bi++] = '0' + ps;
1630
      ps = 0;
1630
      ps = 0;
Line 3900... Line 3900...
3900
        flag = 0;
3900
        flag = 0;
3901
      else {
3901
      else {
3902
/* perform enumeration */
3902
/* perform enumeration */
3903
        start_time = time(NULL);
3903
        start_time = time(NULL);
3904
        acn = EPDEnumerate(depth);
3904
        acn = EPDEnumerate(depth);
3905
        acs = time(NULL) - start_time;
3905
        acs = (liT) (time(NULL) - start_time); // Pierre-Marie Baty -- added type cast
3906
/* update the grand total */
3906
/* update the grand total */
3907
        *totalptr += acn;
3907
        *totalptr += acn;
3908
/* record the updated field: acd */
3908
/* record the updated field: acd */
3909
        EPDAddOpInt(epdptr, epdso_acd, depth);
3909
        EPDAddOpInt(epdptr, epdso_acd, depth);
3910
/* record the updated field: acn */
3910
/* record the updated field: acn */
Line 3971... Line 3971...
3971
/* loop through moves */
3971
/* loop through moves */
3972
  for (pi = 0; pi < count; pi++) {
3972
  for (pi = 0; pi < count; pi++) {
3973
/* handle move number indication */
3973
/* handle move number indication */
3974
    if ((c == c_w) || ((pi == 0) && (sc == c_b))) {
3974
    if ((c == c_w) || ((pi == 0) && (sc == c_b))) {
3975
      sprintf(tv, "%hd.", n);
3975
      sprintf(tv, "%hd.", n);
3976
      length = strlen(tv);
3976
      length = (siT) strlen(tv); // Pierre-Marie Baty -- added type cast
3977
      if ((column + 1 + length) >= columnL) {
3977
      if ((column + 1 + length) >= columnL) {
3978
        strcpy((b + index), "\n");
3978
        strcpy((b + index), "\n");
3979
        index++;
3979
        index++;
3980
        column = 0;
3980
        column = 0;
3981
      };
3981
      };
Line 3990... Line 3990...
3990
      n++;
3990
      n++;
3991
    };
3991
    };
3992
/* handle ellipsis */
3992
/* handle ellipsis */
3993
    if ((pi == 0) && (sc == c_b)) {
3993
    if ((pi == 0) && (sc == c_b)) {
3994
      sprintf(tv, "...");
3994
      sprintf(tv, "...");
3995
      length = strlen(tv);
3995
      length = (siT) strlen(tv); // Pierre-Marie Baty -- added type cast
3996
      if ((column + 1 + length) >= columnL) {
3996
      if ((column + 1 + length) >= columnL) {
3997
        strcpy((b + index), "\n");
3997
        strcpy((b + index), "\n");
3998
        index++;
3998
        index++;
3999
        column = 0;
3999
        column = 0;
4000
      };
4000
      };
Line 4008... Line 4008...
4008
      column += length;
4008
      column += length;
4009
    };
4009
    };
4010
/* handle move */
4010
/* handle move */
4011
    m = gpmptr->gpm_m;
4011
    m = gpmptr->gpm_m;
4012
    EPDSANEncode(&m, san);
4012
    EPDSANEncode(&m, san);
4013
    length = strlen(san);
4013
    length = (siT) strlen(san); // Pierre-Marie Baty -- added type cast
4014
    if ((column + 1 + length) >= columnL) {
4014
    if ((column + 1 + length) >= columnL) {
4015
      strcpy((b + index), "\n");
4015
      strcpy((b + index), "\n");
4016
      index++;
4016
      index++;
4017
      column = 0;
4017
      column = 0;
4018
    };
4018
    };
Line 4027... Line 4027...
4027
    gpmptr = gpmptr->gpm_next;
4027
    gpmptr = gpmptr->gpm_next;
4028
    c = inv_cv[c];
4028
    c = inv_cv[c];
4029
  };
4029
  };
4030
/* append game termination marker */
4030
/* append game termination marker */
4031
  sprintf(tv, "%s", gtimstrv[gamptr->gam_gtim]);
4031
  sprintf(tv, "%s", gtimstrv[gamptr->gam_gtim]);
4032
  length = strlen(tv);
4032
  length = (siT) strlen(tv); // Pierre-Marie Baty -- added type cast
4033
  if ((column + 1 + length) >= columnL) {
4033
  if ((column + 1 + length) >= columnL) {
4034
    strcpy((b + index), "\n");
4034
    strcpy((b + index), "\n");
4035
    index++;
4035
    index++;
4036
    column = 0;
4036
    column = 0;
4037
  };
4037
  };