#CustomPoolInjector Question

22 messages · Page 1 of 1 (latest)

spare graniteBOT
#

I'm trying to figure out how to use CustomPoolInjector, and I remember using one in an SRC race once that just duped shaman stone and dashmaster, labelled "Extra Charms". How would I go about setting up something similar, where all I wanted to do was duplicate certain items?

I'm sure that there's some other place I could've put this, but it didn't feel quite right going in the dev channels tamershrug

left sequoia
#

I've read through the ReadMe and the examples, but they don't seem to address anything regarding if I just want to add more items, not replace existing ones. Unless I have misunderstood something, in which case I would love the clarification. Thanks all.

stiff magnet
#

This is a sample Custom Pool that simply adds copies of X items to the save, without affecting original copies

#

Simply including items to your custom pool will make extra copies of them

#

While preserving the original

left sequoia
#

So if I add just includeitems: dashmaster, with priority 0.1, there would be 2 dashmasters in the world, with one being guaranteed to be early?

#

And I need to add all the details at the bottom, or are they assumed if I don't input them?

stiff magnet
#

Not sure how much you get to handle priorities with Pool, I normally use CustomConstraint for that end

#

IE of earlier Sprint/Dashmaster injector

#

And realizing the Sprintmaster MIN should be a MAX instead

left sequoia
#

It seems like every instance of MIN and MAX are reversed in their intended purposes tbf, I spent like an hour trying to figure out why it was like that

#

I still haven't figured it out

stiff magnet
#

That's mostly a standard in programming, but basically what MIN does is selecting the minimum value between (your priority) and 0.2 in this case

#

If you used MAX it'd pick the higher value between (your priority) and 0.2

#

So while it does sound a bit unintuitive you get used to it

left sequoia
#

What do you mean by (your priority)? Like the number generated by the randomizer?

stiff magnet
#

Yeah

left sequoia
#

But with MAX 0.2, that's the highest value it could select, thus forcing it to be (approximately) 20% of the way through the randomizer?

stiff magnet
#

Correct

left sequoia
#

Thank you so much that spared me a lot more headache. This is the first time I've actually looked into code with any sort of depth

stiff magnet
#

Anytime! Those two packs are also kinda race-suited so feel free to try them out