I haven’t opened your project file but here are some thoughts:
For the right click issue:
I’d remove the wait actions. They just complicate when stuff runs.
When you right click, the two right click events are run in order from the top down. So the first sets stuff up so the second can run. Maybe using one right click event and else in sub events would be a workable solution.
On right click
— slot empty ?
—— place object in slot
— — add one to item count in slot
For your second issue it’s basically you want to pick two instances at the same time. There are two strategies for that.
One is to pick them one at a time, save the info you want to some variables and then pick the other. IIDs are useful here sometimes. So that would look like:
— pick a object
—— set firstObjColor to object.color
— pick a different object
— object.color = firstObjColor
—— console log: can craft
Or if you want to use an iid to make picking the first object later easier:
— pick first obj
—— set firstObj to obj.iid
— pick other object
— obj.color = obj(firstObj).color
—— log colors match
Anyways the other way to handle picking two instances of the same object type is to make a family with just that type. So if the object is “sprite”, make a family, add sprite, and call it “otherSprite”
Then you could do this:
Sprite.x = 100
— do something