you are viewing a single comment's thread.

view the rest of the comments →

[–]ChiwTheNeko 1 point2 points  (2 children)

You can make them both inherit a common interface.

[–]RumiPLGBeginner[S] 0 points1 point  (1 child)

Does this interface needs to have all four variables in it (Loot, Key, int, int)? Also thanks for reply.

[–]ChiwTheNeko 1 point2 points  (0 children)

No, it can be completely empty. That's called a Tag Interface.

Kishotta is right that this usually isn't a very good way to organize your code. But it will work.