[update] Allowed a parser to parse the first term with minus.
This commit is contained in:
parent
937a4fa09a
commit
16aeda8612
@ -120,6 +120,10 @@ private class RuleSet {
|
||||
static Expression ParseExpressionFromFirstTerm(Term term) {
|
||||
return Expression([term]);
|
||||
}
|
||||
static Expression ParseExpressionFromFirstNegativeTerm(
|
||||
@(TokenType.Sub) Token, Term term) {
|
||||
return Expression([term * -1f]);
|
||||
}
|
||||
static Expression ParseExpressionFromFollowingAddedTerm(
|
||||
Expression expr, @(TokenType.Add) Token, Term term) {
|
||||
return expr + term;
|
||||
|
@ -2,6 +2,6 @@ $define beat {0}
|
||||
|
||||
$repeat i 100 {
|
||||
A [$i*5+$beat..($i+1)*5+$beat] {
|
||||
damage = 1;
|
||||
damage = -1;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user