Open Magnymbus opened 2 years ago
After some messing around, it seems like it's only detected properly when it's the first part of the token. If any part of the full identifier precedes the "<" it won't find the ">".
Wait... That means it's probably interpreting that as a lessthan rather than a bracket
The extension is (at least for now) ZenScript only. CraftTweaker had an upgrade on Minecraft 1.13+ and upgrade ZenScript to a new language which has similar grammar to the old one, called ZenCode. ZenCode support is WIP. I don't have enough time to develop it, and I'm not familiar with Minecraft in higher version.(Still playing GT New Horizon)
Progress in the past: Lexer and parser are completed, but not integrated in the extension.
For your problem, I believe it's treated as LESS_THAN.
Type parameter exists in ZenCode, which uses <
(called T_LESS
or LT
):
https://github.com/Yesterday17/ZenScript/blob/ba6526e3752c08fd4d0f959d5f664bf254890bbc/server/parser/zencode/ZenCode.bnf#L25
But LT
only exists in bracket handler in ZenScript:
https://github.com/Yesterday17/ZenScript/blob/ba6526e3752c08fd4d0f959d5f664bf254890bbc/server/parser/zenscript/zsParser.ts#L660
Just wanted to pop back in to let you know that this seems to actually be fixed in the current build and is only giving me bracket errors in the version on marketplace. In fact, a lot of weird errors are gone now that I've cloned from master rather than using the release.
getting expecting token of type BR_CLOSE, even though the closing bracket is there and the script works in game. I tried going through the JSON and javascript to try and fix it myself but I have no idea why only the first set is working. I thought it might be a weird regex edge case, but that didn't work.
Here's my script BTW. The bracket pairs in question are the
<Container>
s