Closed scrom closed 8 years ago
furthermore, "smash bottle on floor" responds with "You attack the bottle. Unfortunately you can't move the floor to use as a weapon."
need to fix the case where smash/break "on" X checks the thing you're trying to smash is movable, not the destination.
specific test cases to examine: UsingLiquidContainerAsWeaponTwiceLosesLiquidContents and SmashLiquidContainerLosesContents
the use of wording in the response to the player is also pretty poor as it's assembled from break/destroy + drain/empty and its own actions to produce awful grammar.
it turns out throwing breakable things (once broken already) also has "interesting results". throwing a broken bottle at the wall returns with: "Oh dear. You destroyed the wreckage that was once some wreckage that was once a bottle. It's not the most durable of weapons."
thing there's some issues there around use of name after being damaged
decision:
Simpler fix implemented and tested for "smash". "Throw" also fixed - easier than expected.
Player.hit is almost as complex and overloaded as creature.tick. It handles about 10 assorted violent verbs along with weapon handling etc.
It needs breaking out into component functions for each major section of logic and potentially assembling differently depending on verb, recipient and weapon
specific examples that aren't fully implemented are:
"shake" and "rattle" translate as bare knuckle fights These need more explicit handling as "bash" items in some way. Perhaps implementing shake or rattle as its own action that (like drop) occasionally bashes an item. If the item is collectible wording would be that you pick it up, shake it and drop it (or similar).