'use' changes then unequips gear

Fluxxdog

Active member
Code:
> use Snow Suit

Putting on Snow Suit...
Equipment changed.
Putting on little box of fireworks...
Equipment changed.

> use hookah

Putting on ittah bittah hookah...
Equipment changed.
Putting on little box of fireworks...
Equipment changed.

> use leather mask

Putting on leather mask...
Equipment changed.
Putting on intimidating coiffure...
Equipment changed.
Verifying ingredients... <==This is from Item Manager's Creatable section using "create and use"
Verifying ingredients for basic meat helmet (1)...
Searching for "helmet recipe"...
Search complete.
Purchasing helmet recipe (1 @ 100)...
You acquire an item: helmet recipe
You spent 100 Meat
Purchases complete.
Creating 1 meat stack...
You acquire an item: meat stack
You lose 100 Meat
Successfully created meat stack (1)
Creating basic meat helmet (1)...
You acquire an item: basic meat helmet
Successfully created basic meat helmet (1)
Putting on basic meat helmet...
Equipment changed.
I had made a custom button that would equip the Snow Suit if I clicked it. Never used it as other programs would generally automate it. Tried it today and ended up finding all this out. I didn't want to plop a bug report because I could be wrong, but I remember 'use'ing a piece of equipment would equip it. Where did I go wrong?
 

lostcalpolydude

Developer
Staff member
You haven't told us anything about the button you made. It appears to be making a checkpoint before equipping the item and then restoring the checkpoint afterward.
 

Theraze

Active member
I think the point is just that "use <equippable item>" no longer leaves the item equipped.
> use disco ball

Wielding disco ball...
Equipment changed.
Wielding Rock and Roll Legend...
Equipment changed.
That was just typed into the gCLI right now. It equipped my disco ball... and immediately re-equipped my RnRL. No checkpoints or other actions done on my side on purpose.

Possible that the fix for this is to remove equippable items from "use" and force people to employ the equip command instead.
 

Veracity

Developer
Staff member
The issue is in UseItemCommand

Code:
		SpecialOutfit.createImplicitCheckpoint();
		UseItemCommand.use( command, parameters );
		SpecialOutfit.restoreImplicitCheckpoint();
That may be intended to leave you in your initial outfit if it changes out to buy something, but it means that the "use" command no longer works on equipment, as the OP noticed.

The command either needs to say "use the equip command" (much as it does when you try to do something other than "eat" with food or "drink" with booze) or handle the checkpointing differently.
 

Fluxxdog

Active member
Honestly, I thought use just makes sense for the few piece of equipment that have some actual use, like stinky cheese. It just means that instead of an Item button, I'll just use a Command button for that Snow Suit.
 

Bale

Minion
The command either needs to say "use the equip command" (much as it does when you try to do something other than "eat" with food or "drink" with booze) or handle the checkpointing differently.

I favor the former option. Use should only work on an equipment, if that equipment actually has a [use] link.
 

Veracity

Developer
Staff member
Use should only work on an equipment, if that equipment actually has a [use] link.
The knowledge of which those items might be - bricko equipment (which break into bricks), sticker weapons (which change form) - is currently known only to UseItemRequest, not to the UseItemCommand.

I take it that you do not like the "create and use" button on the Item Manager, which is perfectly happy to create equipment and "use" - which is to say, "equip" - it?

(Which is funny, since I think it does UseItemRequest, not EquipmentRequest to do that, which means that if you try to "create and use" a BRICKO hat, it will make it and then break it into bricks.)
 

lostcalpolydude

Developer
Staff member
In the Storage section, I thought about replacing "pull and closet" with "pull and use", but I didn't feel like sorting out what should happen with equipment. Especially when the code I ran locally for a while would equip a juju mask but fold a stinky cheese diaper.
 

Fluxxdog

Active member
Heh, that'll be fun. "Oh hey, look at what I made! And now it's broken. What what?" Maybe separate buttons for create and use and create and equip? It'd be possible to detect if the current highlighted item was equipable or not and whether it's usable or not.
 

zarqon

Well-known member
I use the "Create and Use" button fairly regularly during runs, but the apparent solution there would be to change the behavior of the button depending on whether you are in the "Creatable" tab (all items, use "use) or the "Create" tab of the Equipment section (all equipment, use "equip").
 
Top