AppliedEnergistics / Applied-Energistics-2

A Minecraft Mod about Matter, Energy and using them to conquer the world..
https://appliedenergistics.github.io/
Other
1.42k stars 649 forks source link

Format Cells by Mod with Cell Workbench #1000

Closed mcgraj3 closed 9 years ago

mcgraj3 commented 9 years ago

Feature request:

Format a cell on the Cell Workbench by mod type (instead of just sorting by unique items). This would be a convenient way to store different blocks/items by mod. This would also prevent newer items that haven't been added to a cell via the Cell Workbench get correctly stored in the appropriate cell.

BoboSims commented 9 years ago

I second this request. But I would also like to be able to configure View cells to filter by Mod!

thatsIch commented 9 years ago

I think there were several issues with this idea.

BoboSims commented 9 years ago

I don't doubt that. I'm sure it's a complicated matter. That LogisticsPipes have solved this issue, doesn't mean AE2 can do it too (tongue in cheek). :-P

thatsIch commented 9 years ago

With several issues, I mean for starters, that the original author rejected this idea, I think

BoboSims commented 9 years ago

I see. Doesn't negate the fact that I would like it. But if it isn't going to happen, then that's how it is. I'll accept that. :)

mcgraj3 commented 9 years ago

To me, this just seems like a no-brainer. EnderIO also has Mod Item Filters, which basically allow sorting by mod. Up to three mods can be applied per filter (input) so it is a workaround to implement it: have a "sorting chest" that outputs to an EnderIO Item Conduit, each routing to an ME Chest for each mod. The problem with this is that if you exceed the largest cell size's unique item or stack count, you need another ME Chest.

I realize how powerful AE2 is, but with so many Tekkit/FTB/custom mod packs out there that have quite a lot of mods, this should be a key feature and not overlooked.

thatsIch commented 9 years ago

Just because Mod XYZ has feature ABC, this gives no reason to actually implement this. By that logic we should implement a furnace which outputs 100x iron from 1 single iron ore because you have modpacks with 300 mods in them which require iron.

mcgraj3 commented 9 years ago

@thatslch I don't understand your logic and your reply seems condescending in wording, something not really constructive to the nature of GitHub issue tracking, even for a feature request.

I would like to request @AlgorithmX2 to chime in here for validity on whether or not this could/would be implemented, and if not why or what problems arise from such a feature. I am not the first person to ask for it and I am sure that many would be interested in mod-formatted cells.

ross-lanes commented 9 years ago

@mcgraj3 @AlgorithmX2 already showed his support for this when he migrated #73. It looks likes some work was already done on this by @cjo9900 but he never submitted a pull request as far as I can tell.

I would love to have this due to how I build. I usually have areas dedicated to a specific mod so having access to items from that mod only would be nice. However, I could see this being implemented by an AE2 add on like Extra Cells 2.

thatsIch commented 9 years ago

View Cells are different than formatting storage cells though

scorpion451 commented 9 years ago

Also badly wanting this to be added. I'd suggest that being able to set a particular keyword search as the filter for a view or storage cell would be a very user-friendly way to go about it.

Searching your network for something like @mystcraft already will give you all items from the mystcraft mod. Being able to lock that view into a cell would allow you to not only set a filter by mod, but also to set up a storage cell that stored all the ingots you produce, even ones you don't have on hand at the moment, by setting the filter to "ingots". You can already do the same thing manually, this would just be a way to save a lot of tedious clicking and reformatting for new items, and give a way to extract things that otherwise can't be easily extracted automatically due to their metadata, like hybrid saplings from forestry.

If there's a balance rationalization for why this isn't a thing already, maybe make it an expensive upgrade to the fuzzy card?

yueh commented 9 years ago

String based filters are the worst in terms of user-friendliness, they are just a quick way for the developer to implement and leave potential issues to the users.

Also they only work clientside as the server does not know anything about the localization and what "ingots" really means (and how should this be translated, if someone else looks at the filter?) Which means we have to lock the user into a single probably unknown language. Also what about mods which are not available in that particular language or have incomplete translations?

The next issue which probably is prevent it, is that cells can only filter actual items and only up to 63 items. So it would be limited to mods with up to 63 items, maybe actually a bit more through some tricks with the oredictionary. That is mostly a vanilla limitation as it does not know about mods and so it needs every actual item to filter and not just a placeholder. Changing it would be more or less a completely rewrite of how AE2 handles the data everywhere.

scorpion451 commented 9 years ago

I actually feel the current way of setting filters is the one that leaves issues to the users. Its the thing that makes you have to set separate filters for each of 6 different copper ingots from different mods, when all it would really take is one look at the name and/or the ore dictionary to recognize that "hey, all of these 6 different things named copper ingot that are totally interchangeable are the same thing, and can probably be stored in the cell flagged to contain any one of them" Not really seeing how any of this is any different than being able to search the database as it currently exists either. It doesn't need to know what an ingot is. It just needs to look for anything with the string "ingot" in its name based on whatever the user's language is, exactly like it does already. This is actually far more useful than dealing with things like hard ids, because if I search for book, I also get bookcases, bookshelves, book binders, etc. This actually reduces the criteria from 63 to 1: just like an inverter card can let you define an thing to whitelist an infinite number of things that are not a gold ingot, this would filter an infinite number of things that have book in the name.

yueh commented 9 years ago

If you want to filter any copper ingots, just add a fuzzy card and a single copper ingot. This will match any copper ingot (as long as their mod did not forget to oredict them).

But about the other points. The server does exactly know nothing about the users language (just consider that 2 players can play on the same server and still use different languages). The search in terminals is done by the client, the server just sends a list of items to it and it can do whatever it want with it. But the other way is not possible, because you would need to sort it on the client. So you have to trust the client, if it says sorting "1 Diamond, 1 Torch, 1 Coal" => "1 million diamonds, 1 billion Torches, 42 Coal" that this is right. And also what happens, if the uses goes offline?

It is really not possible on server side. Trust me here.

And if you want to really disprove me, show me a mod which matches these requirements. Because that is really required for a string based filter and different languages.

  1. Does not enforce the use of english names or item ids (the strings like minecraft:stone)
  2. Allows changing the language. Like configure the filter while using english and then switch to another one will not break it.
  3. Allows being used by multiple players on the same server using different languages. For example user A uses english and configures it to "ingot", player B uses latin and will see that the filter is set to "talea" and if B changes it to "liber", A will see "book"
scorpion451 commented 9 years ago

The mod already has a search function that works identically to what I am describing: a simple string search without any semantic parsing or translation. It blindly looks for anything with the letters you type in, and returns the items that match. If I type in "ing" in the search bar, I will get shown ingots, fishing rods, grinding stones, and anything else with "ing" in the name. If I type in @chisle 2 I get everything from the chisle 2 mod. This is just being able to save that same criteria as a view cell or a filter on a storage cell. If the multiple languages are the issue, flag that cell as using the English or German or French names, or whatever language the person who set it was using. That would be two variables: a string and a language.

yueh commented 9 years ago

You completely missed the point with server and client. It also violates 3. as 2 players viewing the same terminal will not see the same result.

scorpion451 commented 9 years ago

Is that really a problem? Two players opening a vanilla ender chest will see different things also.

Cisien commented 9 years ago

The search in the terminal is only on the client. The server doesn't know that the copier ingot is named copper ingot. For all the server knows, it could be named pink unicorns. This is where the issue comes when doing any kind of text filtering in a server environment. #3 may not be hugely important here, but #1 and #2 are basically show stoppers.

XFactHD commented 9 years ago

I think the view cells and the storage cells could use the ore dictionary names (for example ingotCopper) because the ore dictionary isn't a client side thing. In terms of filtering by mod, does the server know the string that you type into the NEI search bar to only look at one mod (for example @mod.AppliedEnergistics2)?

Cisien commented 9 years ago

Using the ore dictionary name violates one of the main tenants of AE, which is to not expose the inner workings of the game. Plus, not everything is in the ore dictionary.

Now, it might be possible to do something with the client data to populate the cell with the ids of the item and possibly figure out the other items for the mod from that. We can't rely on nei being on the server.

Like you said earlier, of anyone has the knowledge and spare time, they are welcome to do a pr, since our focus is on squashing the major bugs in AE today

yueh commented 9 years ago

If you would have read what I have written early, the cells are already using the oredict with a fuzzy card.

It is completely irrelevant how the mod filter works, say filter by the exact mod name or by an item + upgrade. There is no equality system for mod items like the oredict. Some mods might even consist of multiple submods (like buildcraft), so it will work extremely inconsistent. And it will always be limited to filter 63 items as we have to prepopulate the cells with the items (with an amount of 0). So it will only work for mods with <= 63 items or only the first 63 items of a mod.

mcgraj3 commented 9 years ago

My thread topic revolves around AE2 Storage Cells being formatted like EnderIO's Mod Item Filter (for Item Conduits), because it works and works well. However, there are only so many ME Chests one can make for each cell before madness sets in, hence the reason for this feature request: to format cells themselves for use in an ME Drive.

I can already search by mod in the Crafting Terminal (Sort by Inventory Tweaks, Search Box Mode NEI Synchronized Auto). It's just that my OCD tingles every time I think about what is stored where, but as long as it is all connected to the system, I will just consider it a vast cornucopia of storage magic. :/

I suppose this feature request can be closed.