Hero has items in slots, create new item.

Husky

Local Lurker
Reaction score
120
I haven't mapped in years and I was playing around with the editor a bit for the first time, so bear with me.

What I want is; "If a unit has item X in slot 1, and item Y in slot 2 and then USES item X (in slot 1) it adds item Z to the hero's inventory"

Code:
    Events
        Unit - A unit Uses an item
    Conditions
        (Item being manipulated) Equal to (Item carried by (Hero manipulating item) of type |cffffcc00Bundle of Sticks|r)
        |cffffcc00Bundle of Sticks|r 0000 <gen> Equal to (Item carried by (Hero manipulating item) in slot 1)
        |cffffcc00Tinder|r 0004 <gen> Equal to (Item carried by (Hero manipulating item) in slot 2)
    Actions
        Hero - Give (Item carried by (Hero manipulating item) of type Fireplace) to (Hero manipulating item)

That was what I had, but it didn't work. Re-familiarise me! :p
 

AceHart

Your Friendly Neighborhood Admin
Reaction score
1,495
Event:
- A unit uses an item
Conditions:
- Item type of (Item being manipulated) equal to "item 1"
- ((Triggering unit) has item of type "item 1") equal to true (optional, given you just now used it...)
- ((Triggering unit) has item of type "item 2") equal to true
Actions:
- Hero - Create "item 3" for (Triggering unit)

You probably also want to remove items 1 and 2.
And, why limit people to one particular slot? That's annoying at best.
 

Husky

Local Lurker
Reaction score
120
Thanks Ace.

And the slot thing was to avoid collisions, otherwise players would be getting items they didn't want... or is there a way around that?
 

Husky

Local Lurker
Reaction score
120
What kind of "collisions"?

For example:

Wood + Stone = Building 1
Wood + Stone + Clay = Building 2

Say if the player had all 3 of those items in their inventory and used "wood", it may create building 1 instead of building 2 (but that player wanted building 2, not 1) for the reason that both buildings use Wood and Stone.

I may be wrong, but this was the assumption I got.


EDIT: Hmm, your trigger didn't work either. Hold on, let me fiddle.
 

AceHart

Your Friendly Neighborhood Admin
Reaction score
1,495
> but that player wanted building 2, not 1

And, what if he wanted 1 and got 2 instead?
Seems like there's some need for a better plan here...

> Hold on ...

While waiting for you to post yours?
 

Husky

Local Lurker
Reaction score
120
Code:
    Events
        Unit - A unit Uses an item
    Conditions
        (Item-type of (Item being manipulated)) Equal to |cffffcc00Bundle of Sticks|r
        ((Triggering unit) has an item of type |cffffcc00Bundle of Sticks|r) Equal to True
        ((Triggering unit) has an item of type |cffffcc00Tinder|r) Equal to True
    Actions
        Hero - Create Fireplace and give it to (Triggering unit)

That was my version.

AceHart said:
Seems like there's some need for a better plan here...

It's a bit hard to explain, but the system does work. There may be an alternative, better system but I've yet to discover it. Feel free to shoot ideas.
 

AceHart

Your Friendly Neighborhood Admin
Reaction score
1,495
> That was my version.

Ok...
And, what exactly is "it doesn't work"? Nothing? Wrong item? Crash? A random cat died? Your food started moving on its own?
 

Husky

Local Lurker
Reaction score
120
> That was my version.

Ok...
And, what exactly is "it doesn't work"? Nothing? Wrong item? Crash? A random cat died? Your food started moving on its own?

As in, nothing happened. I used the item and... nada. No '3rd' item.
 

AceHart

Your Friendly Neighborhood Admin
Reaction score
1,495
Hm...

You made sure the unit actually has those items?
You can use "item 1"? As in, it does have some active ability?
It's not charged and removed because it's now out of charges?
No cats hurt? Damn... well, better luck next time.
 

Husky

Local Lurker
Reaction score
120
You made sure the unit actually has those items? - Yeah, placed them right in front of him.

You can use "item 1"? As in, it does have some active ability? - This is probably it. You can 'click' the item, but nothing active happens. I thought all you needed was the 'click' and you'd be good to go. Seems not.

It's not charged and removed because it's now out of charges? - No.

No cats hurt? Damn... well, better luck next time. - No cats ;) . Dogs though? Well...
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • Monovertex Monovertex:
    How are you all? :D
    +1
  • Ghan Ghan:
    Howdy
  • Ghan Ghan:
    Still lurking
    +3
  • The Helper The Helper:
    I am great and it is fantastic to see you my friend!
    +1
  • The Helper The Helper:
    If you are new to the site please check out the Recipe and Food Forum https://www.thehelper.net/forums/recipes-and-food.220/
  • Monovertex Monovertex:
    How come you're so into recipes lately? Never saw this much interest in this topic in the old days of TH.net
  • Monovertex Monovertex:
    Hmm, how do I change my signature?
  • tom_mai78101 tom_mai78101:
    Signatures can be edit in your account profile. As for the old stuffs, I'm thinking it's because Blizzard is now under Microsoft, and because of Microsoft Xbox going the way it is, it's dreadful.
  • The Helper The Helper:
    I am not big on the recipes I am just promoting them - I use the site as a practice place promoting stuff
    +2
  • Monovertex Monovertex:
    @tom_mai78101 I must be blind. If I go on my profile I don't see any area to edit the signature; If I go to account details (settings) I don't see any signature area either.
  • The Helper The Helper:
    You can get there if you click the bell icon (alerts) and choose preferences from the bottom, signature will be in the menu on the left there https://www.thehelper.net/account/preferences
  • The Helper The Helper:
    I think I need to split the Sci/Tech news forum into 2 one for Science and one for Tech but I am hating all the moving of posts I would have to do
  • The Helper The Helper:
    What is up Old Mountain Shadow?
  • The Helper The Helper:
    Happy Thursday!
    +1
  • Varine Varine:
    Crazy how much 3d printing has come in the last few years. Sad that it's not as easily modifiable though
  • Varine Varine:
    I bought an Ender 3 during the pandemic and tinkered with it all the time. Just bought a Sovol, not as easy. I'm trying to make it use a different nozzle because I have a fuck ton of Volcanos, and they use what is basically a modified volcano that is just a smidge longer, and almost every part on this thing needs to be redone to make it work
  • Varine Varine:
    Luckily I have a 3d printer for that, I guess. But it's ridiculous. The regular volcanos are 21mm, these Sovol versions are about 23.5mm
  • Varine Varine:
    So, 2.5mm longer. But the thing that measures the bed is about 1.5mm above the nozzle, so if I swap it with a volcano then I'm 1mm behind it. So cool, new bracket to swap that, but THEN the fan shroud to direct air at the part is ALSO going to be .5mm to low, and so I need to redo that, but by doing that it is a little bit off where it should be blowing and it's throwing it at the heating block instead of the part, and fuck man
  • Varine Varine:
    I didn't realize they designed this entire thing to NOT be modded. I would have just got a fucking Bambu if I knew that, the whole point was I could fuck with this. And no one else makes shit for Sovol so I have to go through them, and they have... interesting pricing models. So I have a new extruder altogether that I'm taking apart and going to just design a whole new one to use my nozzles. Dumb design.
  • Varine Varine:
    Can't just buy a new heatblock, you need to get a whole hotend - so block, heater cartridge, thermistor, heatbreak, and nozzle. And they put this fucking paste in there so I can't take the thermistor or cartridge out with any ease, that's 30 dollars. Or you can get the whole extrudor with the direct driver AND that heatblock for like 50, but you still can't get any of it to come apart
  • Varine Varine:
    Partsbuilt has individual parts I found but they're expensive. I think I can get bits swapped around and make this work with generic shit though

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top