hedgewars/uScript.pas
changeset 13954 cc312e22592b
parent 13933 429945a9b8db
child 13976 2828ec67c47c
equal deleted inserted replaced
13953:e98e2fc556a7 13954:cc312e22592b
  3570     if (mybuf <> nil) and ((sz^) > 0) then
  3570     if (mybuf <> nil) and ((sz^) > 0) then
  3571         begin
  3571         begin
  3572             for i:= 0 to sz^-1 do
  3572             for i:= 0 to sz^-1 do
  3573                 begin
  3573                 begin
  3574                     if (lastChar = '-') and (mybuf[i] = '-') then
  3574                     if (lastChar = '-') and (mybuf[i] = '-') then
  3575                         inComment := true
  3575                         inComment := false  // FIXME - set to false because lua considers --[====[ ]=====] Non-comment stuff to be sensible
  3576                     // gonna add any non-magic whitespace and skip - just to make comment avoidance easier
  3576                     // gonna add any non-magic whitespace and skip - just to make comment avoidance easier
  3577                     else if not inComment and (byte(mybuf[i]) > $20) and (byte(mybuf[i]) < $7F) and (mybuf[i]<>'-') then
  3577                     else if not inComment and (byte(mybuf[i]) > $20) and (byte(mybuf[i]) < $7F) and (mybuf[i]<>'-') then
  3578                         begin
  3578                         begin
  3579                         AddRandomness(byte(mybuf[i]));  // wish I had the seed...
  3579                         AddRandomness(byte(mybuf[i]));  // wish I had the seed...
  3580                         CheckSum := CheckSum xor GetRandom($FFFFFFFF);
  3580                         CheckSum := CheckSum xor GetRandom($FFFFFFFF);