Package com.pahimar.ee3.api

Examples of com.pahimar.ee3.api.EnergyValue.compareTo()


                WrappedStack factoredWrappedStack = new WrappedStack(wrappedStack, 1);
                EnergyValue factoredEnergyValue = EnergyValueHelper.factorEnergyValue(energyValue, wrappedStack.getStackSize());

                if (preAssignedMappings.containsKey(factoredWrappedStack))
                {
                    if (factoredEnergyValue.compareTo(preAssignedMappings.get(factoredWrappedStack)) < 0)
                    {
                        preAssignedMappings.put(factoredWrappedStack, factoredEnergyValue);
                    }
                }
                else
View Full Code Here


                                                }
                                                else
                                                {
                                                    EnergyValue itemValue = energyValueRegistry.stackMappings.get(new WrappedStack(itemStack));

                                                    if (itemValue.compareTo(lowestValue) < 0)
                                                    {
                                                        lowestValue = itemValue;
                                                    }
                                                }
                                            }
View Full Code Here

                                        {
                                            if (valuedItemStack.getItemDamage() == OreDictionary.WILDCARD_VALUE || wrappedItemStack.getItemDamage() == OreDictionary.WILDCARD_VALUE)
                                            {
                                                EnergyValue stackValue = energyValueRegistry.stackMappings.get(valuedStack);

                                                if (stackValue.compareTo(lowestValue) < 0)
                                                {
                                                    lowestValue = stackValue;
                                                }
                                            }
                                            else if (wrappedItemStack.getItem().isDamageable() && wrappedItemStack.isItemDamaged())
View Full Code Here

                                            }
                                            else if (wrappedItemStack.getItem().isDamageable() && wrappedItemStack.isItemDamaged())
                                            {
                                                EnergyValue stackValue = new EnergyValue(energyValueRegistry.stackMappings.get(valuedStack).getEnergyValue() * (1 - (wrappedItemStack.getItemDamage() * 1.0F / wrappedItemStack.getMaxDamage())));

                                                if (stackValue.compareTo(lowestValue) < 0)
                                                {
                                                    lowestValue = stackValue;
                                                }
                                            }
                                        }
View Full Code Here

                if (factoredExchangeEnergyValue != null)
                {
                    if (stackValueMap.containsKey(factoredKeyStack))
                    {
                        if (factoredExchangeEnergyValue.compareTo(stackValueMap.get(factoredKeyStack)) == -1)
                        {
                            stackValueMap.put(factoredKeyStack, factoredExchangeEnergyValue);
                        }
                    }
                    else
View Full Code Here

                    EnergyValue computedValue = EnergyValueHelper.computeEnergyValueFromList(recipeInputs);
                    computedValue = EnergyValueHelper.factorEnergyValue(computedValue, recipeOutput.getStackSize());

                    if (computedValue != null)
                    {
                        if (computedValue.compareTo(lowestValue) < 0)
                        {
                            lowestValue = computedValue;
                        }
                    }
                }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.