File tree Expand file tree Collapse file tree 2 files changed +6
-5
lines changed
Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Original file line number Diff line number Diff line change 33using SER . Code . Helpers . ResultSystem ;
44using SER . Code . TokenSystem . Tokens ;
55using SER . Code . TokenSystem . Tokens . VariableTokens ;
6+ using SER . Code . VariableSystem . Variables ;
67
78namespace SER . Code . ArgumentSystem . Arguments ;
89
910public class LiteralVariableArgument ( string name ) : Argument ( name )
1011{
11- public override string InputDescription => "A literal variable name (doesnt have to be real) " ;
12+ public override string InputDescription => "Any existing literal variable e.g. $text or $playerId " ;
1213
1314 [ UsedImplicitly ]
14- public DynamicTryGet < LiteralVariableToken > GetConvertSolution ( BaseToken token )
15+ public DynamicTryGet < LiteralVariable > GetConvertSolution ( BaseToken token )
1516 {
1617 if ( token is not LiteralVariableToken literalVariableToken )
1718 {
1819 return $ "Value '{ token . RawRep } ' is not a syntactically valid literal variable.";
1920 }
2021
21- return literalVariableToken ;
22+ return new ( ( ) => literalVariableToken . TryGetVariable ( ) ) ;
2223 }
2324}
Original file line number Diff line number Diff line change @@ -78,9 +78,9 @@ public Elevator[] GetElevators(string argName)
7878 return GetValue < Elevator [ ] , ElevatorsArgument > ( argName ) ;
7979 }
8080
81- public LiteralVariableToken GetLiteralVariable ( string argName )
81+ public LiteralVariable GetLiteralVariable ( string argName )
8282 {
83- return GetValue < LiteralVariableToken , LiteralVariableArgument > ( argName ) ;
83+ return GetValue < LiteralVariable , LiteralVariableArgument > ( argName ) ;
8484 }
8585
8686 public Item [ ] GetItems ( string argName )
You can’t perform that action at this time.
0 commit comments