hedgewars/CCHandlers.inc
changeset 83 207c85fbef51
parent 81 d74e0e914b50
child 95 1ef5e2c41115
equal deleted inserted replaced
82:2f4f3236cccc 83:207c85fbef51
    65 if CurrentTeam = nil then OutError(errmsgIncorrectUse + ' "/name"', true);
    65 if CurrentTeam = nil then OutError(errmsgIncorrectUse + ' "/name"', true);
    66 SplitBySpace(id, s);
    66 SplitBySpace(id, s);
    67 if s[1]='"' then Delete(s, 1, 1);
    67 if s[1]='"' then Delete(s, 1, 1);
    68 if s[byte(s[0])]='"' then Delete(s, byte(s[0]), 1);
    68 if s[byte(s[0])]='"' then Delete(s, byte(s[0]), 1);
    69 if id = 'team' then CurrentTeam.TeamName:= s
    69 if id = 'team' then CurrentTeam.TeamName:= s
    70 else if (id[1]='h')and(id[2]='h')and(id[3]>='0')and(id[3]<='7') then
    70 else if (id[1] = 'h') and (id[2] = 'h')
       
    71      and (id[3] >= '0') and (id[3] <= chr(ord('0')+cMaxHHIndex)) then
    71    CurrentTeam.Hedgehogs[byte(id[3])-48].Name:= s
    72    CurrentTeam.Hedgehogs[byte(id[3])-48].Name:= s
    72 else OutError(errmsgUnknownVariable + ' "' + id + '"')
    73 else OutError(errmsgUnknownVariable + ' "' + id + '"')
    73 end;
    74 end;
    74 
    75 
    75 procedure chGrave(var s: shortstring);
    76 procedure chGrave(var s: shortstring);