Comments (38)
Please use your very advanced human eyes to choose from the small remaining list.
This is a gui tool, you're not piping it into a dumb program upstream.
from justenoughitems.
There are a few upcoming features that mitigate most of the problems brought up here.
- an Item "history" which shows what you've looked up recently, including pinning
- using quotes for search terms that include spaces
from justenoughitems.
Just adding my voice to the crowd, regex is something I'm missing from NEI. If you're that worried about performance, make it an opt-in feature.
from justenoughitems.
you're not piping it into a dumb program upstream.
Are you sure? I'm pretty sure the API lets me get the search results...
(This is a bad joke. Please don't thumbs up.)
from justenoughitems.
The use for regex I had was doing something like +\d\d attack damage
or searching for ME drives with at least 15k bytes used ([12345]\d\d\d of
). Make it optional and everyone will benefit.
from justenoughitems.
Just wanted to add my voice as well in favor of regex. My use case is for finding values where I don't actually know what item I'm searching for. As a specific example, I enjoy modpacks that include ProjectE. I find it useful to be able to use various ranges to track down items with specific EMC values. For example, if I'm looking for an item with maximum EMC, I might do something like "EMC: [1-9][0-9]{2},[0-9]{3},[0-9]{3}" which will show me anything from 100,000,000 EMC to 999,999,999 EMC. This is along the lines of dzaima's comment on Mar 5 where that user wished to look for things with double-digit attack damage or storage items holding a certain amount of stuff.
from justenoughitems.
It's really annoying to not have regular expressions to work with. There are multiple legit use cases.
Also. It's even more annoying that one can't use item id's.
I was really hyped about JEI since NEI had some issues (those npe's argh..) and I read a lot of positive. At first I thought well u gotta adjust your work pattern to JEI but to be honest there are too many things which are missing. Meh.
from justenoughitems.
We have an OR, |
.
from justenoughitems.
If I add start and end line matching, it would be broken by anything with ^ or $ in the name (requiring escaping), and I would have to change the existing prefix for $ (OreDict name) and ^ (colors).
The benefit to me seems minor, and it will only be used by a very tiny group of players, so I do not think the compromises required for implementing it are justified.
from justenoughitems.
@shadowfacts @way2muchnoise @mezz
Anchors are def missing imo
^chest$
Lets say I'm searching this item I can't remember the name of. I just know it was chest something. Since there are tons of items which include chest I want to exclude all items which do not start with chest.
^chest
The are those upgrade items which are called Machine Upgrade X Tier where X is a wildcard. I know the wildcard happens to be only letters. Since there are tons of upgrade items in any kitchensink pack I want to only find them above described upgrades
^machine upgrade [a-z]+ tier$
I'm looking for the best tinkers materials. I want to build a sword. I know the highest damage is 2 digit
So I'm going to pin those 5 items or of 100 down with
max Damage\: [0,9]{2}
When I'm building towards a larger goal I tend to list all the needed items separated by |
So I want to pin down one exact item. Often only possible in combination with the item id.
For example in exu2 there are often duplicates. There is the machine SAG mill and the deco block with the exact same name. Only possible to pin down through the ID.
I'm actually totally new to a anything beyond 1.7.10 - does minecraft still used id's at all? I think I've read something about removing id's in the future. Could be totally wrong tho
On mobile. Excuse any formatting errors. Examples may not be accurate since I don't have access to a minecraft instance right now.
from justenoughitems.
Just another pro for RegEx / ID's
How am I going to only display redstone? I mean just the dust. nothing else. I don't understand how this is supposed to work w/o RegEx or at least ID's
Okay I could combine it with the mod, @minecraft
in this case. But that's still not really helpful
from justenoughitems.
Y'all do realize minecraft:redstone
is just as much of an ID as 331
right?
from justenoughitems.
Sorry I have already explained to you on reddit, and twitter, and IRC.
No regex, I want JEI to run well :). You can search in the middle of names and use spaces for multiple requirements though. "Wren @ildcraf" is valid for instance.
Each character typed narrows down the search (except @ prefix for mod names and space) which makes it very fast and efficient. Regex doesn't have such nice properties, and I would need to run expensive comparisons across every item for each character typed, with no ability to cache results.
Regex is wonderful for all kinds of things, like searching across long sentences of text, refactoring code, or for complex queries, but searching against item names is not one of those things.
I don't think there are real circumstances where regex is more useful than the current search implementation, for this specific application.
from justenoughitems.
Actually you can compile the item list into a long string, and map the positions back to the items.
from justenoughitems.
That doesn't make any sense at all.
You're hyped up about regex without thinking about if it's even useful here.
Please go write a regex HTML parser and report back.
from justenoughitems.
I have a Lua parser in regex... does that count?
from justenoughitems.
from justenoughitems.
You can parse HTML with regex.
from justenoughitems.
What actual regex features do you need for searching Minecraft items? The only one I can think of is | for or.
from justenoughitems.
I'm with @shadowfacts on this one. I don't see much use for regex. An OR feature would be nice but is it really needed? Seems like it is there already
from justenoughitems.
JEI doesn't match spaces, in JEI spaces function like an and operator. So searching for "machine upgrade tier" will match the upgrades you're looking for.
Minecraft still uses numerical IDs internally, but modders and end users don't care about those. Instead everything uses a registry name which is a combination of the domain (minecraft for vanilla, or the mod id) and the name.
from justenoughitems.
JEI doesn't match spaces, in JEI spaces function like an and operator. So searching for "machine upgrade tier" will match the upgrades you're looking for.
Well that's not what I want to do. But I understand.
Minecraft still uses numerical IDs internally, but modders and end users don't care about those
I did not care about them per se but they were pretty helpful.
from justenoughitems.
something i have thought of before, is a way to bookmark certain items, so i can get the same effect as searching for "item1|item2|item3" but i wont loose the entire thing if i right click the search box, or if RS winds up in auto-JEI mode and eats the entire search query
this way, i can pin the stuff i want to craft, and the missing components, and not loose them to a single misclick or badly behaving block
from justenoughitems.
I just want to see Electrical Furnace
- none of the other:
Electrical Furnace
Electrical Furnace Tier 2
Electrical Furnace Tier 3
Electrical Furnace Tier 4
Electrical Furnace Tier 5
How am I going to do this? I have to pin it? Sounds complicated.
from justenoughitems.
Well the example was simple. There are way worse examples.
I mean I get it that you don't like the feature. Just tried to communicate that for me it's very stressful.
from justenoughitems.
Well the example was simple. There are way worse examples.
I mean I get it that you don't like the feature. Just tried to communicate that for me it's very stressful.
I'm sorry it's very stressful, but I believe I have given many reasons for why I will not support regex. What's stressful to me and the vast majority of players is very slow searches in big packs.
Are you sure? I'm pretty sure the API lets me get the search results...
Yeah, for conveniently using it to display items to the player in a GUI in a way that exactly matches JEI.
If you need something different from JEI, you can a search bar to your mod's GUI with your own behavior.
from justenoughitems.
It seems to me the main reason people here still want regex is the start and end line matching. Would that be expensive by itself without the rest of regex, maybe even if only used within exact matches?
from justenoughitems.
Use [[ and ]] instead of ^ and $.
from justenoughitems.
That may work. It seems obscure enough that the only people who would use it are here in this issue though.
from justenoughitems.
Add it to options.txt to make sure it doesn't get set by modpack authors.
from justenoughitems.
Append user UUID to config setting ID to make it impossible to enable by default.
from justenoughitems.
searching for
tin pickaxe head
I expect one item as result
what do I get? all the TINkers construct pickaxe heads. another reason for regex.
from justenoughitems.
That's not a reason for regex, that's a reason for whitespace matching.
from justenoughitems.
Gotta side with KnightMiner on that one, babbelnedd. If you know exactly what you're looking for, you don't need regex. The only time you need regex is when you need to select potentially more than one string. Your use-case could be solved by recognizing double quotes as markers for capturing white space.
from justenoughitems.
JEI can use quotes for capturing white space, "tin pickaxe head"
.
By default, searching mod names require the @
prefix. If you are finding Tinker's items with the search, you may have changed your search config settings so it doesn't require the prefix.
from justenoughitems.
from justenoughitems.
I wanted to put in a thought I had on the subject. I think regex should be allowed for the purpose of history. This also is a feature suggestion for that history system: If a history item lists only one item, clicking it will show recipes and uses, just like clicking the item in JEI. This is both useful for crafting, so you don't have to look through a list more than once, and it's actually a good purpose for regex since many terms are used in many items (just toggle F3+H and search for block or for item and you will see what I mean)
from justenoughitems.
Just FYI-- Yes, in ATM3 configs every search option is set to "enabled" by default except for "color."
These of course are free to be changed by end-users who prefer a less inclusive list of results. With these pack defaults, "tin" search alone has about 8 pages of results.
from justenoughitems.
Related Issues (20)
- [Bug]: Windows Defender detects two latest versions as Trojan Wacatac.B!ml HOT 3
- [Suggestion]: Crafting Tree / Item Values in Bookmarks / Color Coding the bookmarks / Movable Bookmarks HOT 3
- [Suggestion]: Key binding
- [Bug]: Game crashes when enabling Cheat Mode with Forge HOT 2
- Trojan Virus HOT 2
- [Bug]: Latest forge JEI version for 1.20.1 virus has been detected HOT 2
- [Other]: Could not find method deobfProvided() for arguments [mezz.jei:jei_1.19.2:11.0.0.297:api] on object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler HOT 17
- [Bug]: Item tooltips incorrectly report 6 components for each item. MC 1.21 Fabric Server HOT 2
- [Crash]: Unsupported class file major version 65 (Java 21) HOT 9
- [Bug]: Network Protocol Error HOT 5
- [Bug]: As of JEI 15.8.x for Forge, `RenderTooltipEvent.GatherComponents` is no longer fired HOT 7
- [Bug]: 1.20.1 mouse behaviour HOT 1
- [Crash]: Forge 1.20.1 Mouse Moving HOT 2
- [Bug]: Visual Bug when hovering the "+" button in Refined Storage HOT 3
- [Crash]: to view recipes from simplyswords mod HOT 2
- [Crash]: On item hover in Fabric HOT 1
- [Crash]: When searching for gold and browsing to a page of the results in JEI HOT 2
- JEI crashes on singlepalyer world startup, forge 1.20.1 [Crash]: HOT 2
- [Crash]: Crash to Desktop on recipe lookup (Possibly JE Mek Multiblocks) MC 1.20.1 HOT 1
- [Suggestion]: Option to disable Bookmarks entirely, or change bookmark keybind. HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from justenoughitems.