mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
a9d3f984f0
* Added chat message when an item is picked up * Changed InventoryUpdateEvent::Collected to InventoryUpdateEvent::Collected(Item) to facilitate the client being aware of what was picked up * Added SfxInventoryEvent enum to allow different sounds to be used based on the item type. The RON mapping/de-serialization doesn't support matching on structs so we have to give it fixed enum values which are determined in TryFrom<&InventoryUpdateEvent> for SfxEvent * Refactored InventoryManip::Pickup arm of match in inventory_manip::handle_inventory for clarity/better warning messages * Fixed a bug that prevented the CollectFailed event from being raised when a player's inventory is full * Added a panic for the situation where an item is pushed into the players inventory and then the deletion of the entity fails as this would indicate an item dupe bug - this could potentially be reworked to pull the item back from the player's inventory but this seems like there's be a more correct transactional way to do this. * Added two temporary sounds to prove the per-item sound functionality (pickup sounds for Swords and Staffs) |
||
---|---|---|
.. | ||
consumable | ||
add_failed.wav | ||
add_item.wav | ||
drop_item.wav | ||
open_inventory.wav | ||
pickup_staff.wav | ||
pickup_sword.wav |