
Originally Posted by
Dgby714
well Players is a type that doesn't include "LogsType" in it so you can use "Strings[0]" instead so here
Your declare players will look something like this
Code:
procedure DeclarePlayers;
begin
with Players[0] do
begin
... //other players crap like nick and pass
Strings[0] := 'Willow'; //Logtype here =)
... // maybe some other varables
end;
end;
then too use that "Strings[0]" you can do
Code:
case LowerCase(Players[CurrentPlayer].Strings[0]) of
'willow', 'willows': CutWillows;
'someothertree', 'alias': CutOtherTree;
else
CutTheElseTree;
end;
Updated to case because of Frements post =)
"CutTheElseTree;" What? Why would you cut a tree that has already been listed? Wouldn't be:
SCAR Code:
case LowerCase(Players[CurrentPlayer].Strings[0]) of
'willow', 'willows': CutWillows;
'someothertree', 'alias': CutOtherTree;
else
TerminateScript;
end;
Also it would look like this correct?:
SCAR Code:
procedure KindOfLogs;
begin
if not LoggedIn then Exit;
case LowerCase(Players[CurrentPlayer].Strings[0]) of
'tree', 'trees': CutTrees;
'oak', 'oaks': CutOaks;
'willow', 'willows': CutWillows;
'maple', 'maples': CutMaples;
'yew', 'yews': CutYews;
'magic', 'magics': CutMagics;
else
TerminateScript;
end;
end;