• 0 Posts
  • 4 Comments
Joined 10 months ago
cake
Cake day: March 4th, 2024

help-circle

  • At that point I would argue composition/traits are the way to go.

    “This extends Draggable”. That’s great but now we can’t extend “Button” to override the click handler.

    Traits: You wanna have Health, and do Damage, but don’t want to implement InventoryItem? No problem. You wanna be an Enemy and InventoryItem? Go for it. What’s this function take? Anything that implements InventoryItem + Consumable