1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-07-22 17:18:39 +00:00

Only apply "touch_punch_gesture" when wielded item has no on_use callback (#15098)

This commit is contained in:
grorp 2024-09-12 23:41:47 +02:00 committed by GitHub
parent 8617993386
commit af67353f7a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 17 additions and 5 deletions

View file

@ -71,7 +71,8 @@ struct TouchInteraction
TouchInteraction();
// Returns the right mode for the pointed thing and resolves any occurrence
// of TouchInteractionMode_USER into an actual mode.
TouchInteractionMode getMode(PointedThingType pointed_type) const;
TouchInteractionMode getMode(const ItemDefinition &selected_def,
PointedThingType pointed_type) const;
void serialize(std::ostream &os) const;
void deSerialize(std::istream &is);
};