No suitable method found for openInventory

Discussion in 'Spigot Plugin Help' started by luan2809, Jul 7, 2021.

  1. Hi, I'm trying to create and open Inventory by a command but it keep show the error below. I added the command to onEnable and my yml file.
    upload_2021-7-7_10-9-0.png

    Here is the code:
    I tried to replace owner: null to owner: this but it doesn't works too
    upload_2021-7-7_10-8-52.png

    This code in a file named Commands
    upload_2021-7-7_10-9-21.png
     
  2. Please learn java
     
    • Agree Agree x 1
  3. Change public Invento getInventory() to public Inventory getInventory(). You want to return an inventory, not an instance of your class that has the inventory.
     
    • Agree Agree x 1