-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
support for filter variants #7
Comments
Just to add a note on how strictness filtering is done in other filters: Usually you have a base version of said filter which acts as "league start" filter into early maps, this will most likely show way to much loot, but that is need in a league start situation as bad items can still be worth something and you need some gear for your char. It also likely contains a detailed leveling section which is only need for your first character in the league(later characters will have mostly twinked leveling gear, which means you don't really pick up any gear on your way to maps.) Now when you get into mid tier maps your most likely gonna switch to some stricter filters; the way this is done the easiest is: (I will use StupidFatHobbits filters as an example, as i base my filter on his) This is an example from the "normal" filter Show BaseType "Vaal Axe" "Coronal Maul" "Exquisite Blade" Rarity = Rare SetFontSize 34 SetBorderColor 128 0 0 This is from the Strict version: Hide BaseType "Vaal Axe" "Coronal Maul" "Exquisite Blade" Rarity = Rare SetFontSize 34 SetBorderColor 128 0 0 So what you really want is an easy way to toggle the Show/Hide when compiling the filter, this could for example be done by having a tag in front of Show in filter_spirit. Something like this maybe? BaseType ["Vaal Axe", "Coronal Maul", "Exquisite Blade"]{ SetBackgroundColor color_rare_t3 SetFontSize font_t5 SetBorderColor color_rare_border_t3 @Strict(Hide) Show } When you then complie in filter_spirit you could do something like this: filter_spirit_cli.exe -g -version=Strict "location/to/filter_spirit/file.txt" "location/to/filter/filter.filter" Which then would change all the lines that has the @strict(x) with was on the line before. So in the example above it would simply change "Show" to "Hide". You could also have that function add an action if there the line is empty without the @strict command beeing called. Like this: BaseType ["Vaal Axe", "Coronal Maul", "Exquisite Blade"]{ SetBackgroundColor color_rare_t3 SetFontSize font_t5 SetBorderColor color_rare_border_t3 @Strict(DisableDropSound True) @Strict(Hide) Show } Which when compiled with the "-version=Strict" [option] shown above would change the block from "Show" to "Hide" and add the "DisableDropSound" "True" to the block as well. What do you think about this idea for implementing strictness versioning? You also want to be able to add the PlayDefaultDropSound = False to any block that is tagged with |
I don't like this approach, for these reasons:
The second strictness approach appeals more to me, because:
I have updated the issue intial comment to better outline what is the goal of the feature. This should help in designing it and give a direction for propositions. |
Another idea: each block could be marked with a tag and then one could form multiple variants from tags:
pros:
cons:
|
A bit of thinking and I actually prefer your idea of
We only need an idea of better syntax, something that will allow to write one |
Been away for Christmas, but i really like that you came back to this idea. It makes it so there will be minimal effort to convert current filters to work with it. I think it could work really well i this instance, just need to figure out a good syntax. |
Adding label and pinning for awarness. We need more ideas for the variant support, perhaps someone with experience in other languages could help. We basically need:
The current idea of something like
|
I'm still uncertain on this and GGG just relased a big filters improvement annoucement - https://www.pathofexile.com/forum/view-thread/2771031 However, I have been fiddling with the grammar to also support loading/debugging real filters and started to think about rewriting FS grammar so that it is as close to real filters as possible. I won't remove The only ambiguity I have found is when someone would write
|
Ok, this took a while, but it is finally done.
I won't explain it here in detail (just read documentation) but I think it's the best implementation possible that satisfies all of my goals for finely-grained strictness editing. I have even added some reasoning to the documentation. |
We need a feature which will allow to generate filters with multiple variants/strictness levels from 1 template.
Current idea: decorate blocks (something akin to Python's decorators) and then specify which blocks should be present in each variant.
Edit: cleaner goals - a list of what is must-have:
Show
, generate withHide
, do not generate). In a lot of cases you want the 3rd one - the difference is that items not explicitly hidden may be caught by later blocks - this means that syntax like@Strict(Show) @UberStrict(Hide)
is not enough, because (example):Show
toHide
. The feature should allow to avoid code duplication.The text was updated successfully, but these errors were encountered: