Skip to content
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

Color upgrade recipe change #1125

Merged
merged 4 commits into from
Dec 26, 2024
Merged

Conversation

Eldrinn-Elantey
Copy link
Contributor

Replacing vanilla dyes with dyes from GregTech

A long time ago when setting up the autocraft of things from Nuclear Control noticed that the color module has a recipe with vanilla dyes. I found its recipe in the code and wanted to change it to use a similar color from other mods, but did not find how to do it, so I specified the use of dyes from GregTech. Is it possible to specify the use of dyes from any mod?

Replacing vanilla dyes with dyes from GregTech
@Dream-Master
Copy link
Member

atm it choose all dyes not onla gt dyes. limit it to gt dyes i would not approve

@Dream-Master
Copy link
Member

image
image
image
image
that is how it looks like now. seems it use ore dict

@Eldrinn-Elantey
Copy link
Contributor Author

I'm talking about the recipe in the assembly machine

@Eldrinn-Elantey
Copy link
Contributor Author

image

@Dream-Master
Copy link
Member

ah ok. can this use all oredict items as well?

@Eldrinn-Elantey
Copy link
Contributor Author

I wanted to do exactly through the dictionary, but I have not found an example in the code how to do it. Please tell me how to specify the dictionary and I will fix it.

@Eldrinn-Elantey
Copy link
Contributor Author

Eldrinn-Elantey commented Dec 26, 2024

I found this example in the code. GTOreDictUnificator.get(OrePrefixes.dye, Materials.Red, 1L) But having checked it in the game it also accepted only vanilla red dye.

GTValues.RA.stdBuilder()
                    .itemInputs(
                            GTOreDictUnificator.get(OrePrefixes.dust, Materials.Sugar, 1L),
                            GTOreDictUnificator.get(OrePrefixes.cell, Materials.Fuel, 1L),
                            GTOreDictUnificator.get(OrePrefixes.cell, Materials.SulfuricAcid, 1L),
                            GTOreDictUnificator.get(OrePrefixes.cell, Materials.Acetone, 1L),
                            GTModHandler.getModItem(PamsHarvestCraft.ID, "pepperoniItem", 1L, 0),
                            GTOreDictUnificator.get(OrePrefixes.dye, Materials.Red, 1L),
                            GTUtility.getIntegratedCircuit(1))
                    .itemOutputs(GTModHandler.getModItem(OpenComputers.ID, "item", 1L, 18))
                    .fluidInputs(FluidRegistry.getFluidStack("mead", 1000)).duration(10 * MINUTES).eut(TierEU.RECIPE_HV)
                    .addTo(assemblerRecipes);

@FourIsTheNumber
Copy link
Contributor

I wanted to do exactly through the dictionary, but I have not found an example in the code how to do it. Please tell me how to specify the dictionary and I will fix it.

Not possible, assembler recipe with gt dyes should be correct

@Dream-Master
Copy link
Member

image
show only vanilla item

but maybe we can implement it to use all colors . would be great

@Eldrinn-Elantey
Copy link
Contributor Author

I wanted to do exactly through the dictionary, but I have not found an example in the code how to do it. Please tell me how to specify the dictionary and I will fix it.

Not possible, assembler recipe with gt dyes should be correct

Now a recipe with vanilla dye

@Dream-Master
Copy link
Member

go ahead use gt dyes until we find a solution use all dyes

@FourIsTheNumber
Copy link
Contributor

Currently no support for proper oredict in machines, this can’t be done with the existing system for gt recipes. For now default should be using the gt dyes and if someone wants to rewrite how recipes work it can be changed

@Eldrinn-Elantey
Copy link
Contributor Author

When I was looking for an example of specifying all colors, I noticed that for example for Steve's Carts components that are made in the assembler separate recipes for dyes from different mods

@Dream-Master Dream-Master added the bug fix Fix a bug. Please link it in the PR. label Dec 26, 2024
@Dream-Master Dream-Master requested a review from a team December 26, 2024 02:09
@Eldrinn-Elantey
Copy link
Contributor Author

Shall we change the vanilla dyes in the recipe to dyes from GT now, or wait for a way to develop a way to specify dyes from any mods?

@Dream-Master
Copy link
Member

Shall we change the vanilla dyes in the recipe to dyes from GT now, or wait for a way to develop a way to specify dyes from any mods?

yes us gt ones

@Eldrinn-Elantey
Copy link
Contributor Author

If I have correctly specified the use of GT colorants in the recipe, it can be merged

GTValues.RA.stdBuilder() // Color upgrade
                .itemInputs(
                        ItemList.Color_01.get(1L),
                        ItemList.Color_02.get(1L),
                        ItemList.Color_04.get(1L),
                        GTOreDictUnificator.get(OrePrefixes.circuit, Materials.HV, 1L))
                .itemOutputs(getModItem(IC2NuclearControl.ID, "ItemUpgrade", 1, 1, missing)).duration(20 * SECONDS)
                .eut(TierEU.RECIPE_HV).addTo(assemblerRecipes);

@Dream-Master Dream-Master enabled auto-merge (squash) December 26, 2024 21:06
@Dream-Master Dream-Master merged commit 5caa161 into GTNewHorizons:master Dec 26, 2024
4 checks passed
Dream-Master pushed a commit that referenced this pull request Dec 28, 2024
Co-authored-by: Martin Robertz <dream-master@gmx.net>
(cherry picked from commit 5caa161)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug fix Fix a bug. Please link it in the PR.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants