Coder Social home page Coder Social logo

Comments (5)

quantiom avatar quantiom commented on July 27, 2024

This is very unlikely to be happening with just calls to getVanishedPlayers and isPlayerVanished, the whole plugin would not work correctly if these two methods did not return the correct values. Could you please show me how you are calling them? Thanks.

from advancedvanish.

TheSheepGoesBa avatar TheSheepGoesBa commented on July 27, 2024

I'm calling it using this code: AdvancedVanishAPI.INSTANCE.getVanishedPlayers(). I found it weird that I had to use AdvancedVanishAPI.INSTANCE to call anything in the API rather than just AdvancedVanishAPI.method. I followed all of the instructions to install it on the wiki.

from advancedvanish.

quantiom avatar quantiom commented on July 27, 2024

You need to use AdvancedVanishAPI.INSTANCE because AdvancedVanishAPI is a Kotlin object and you are accessing it in Java. That is fine though (assuming that you have depend: [AdvancedVanish] in your plugin.yml). Could you please use /vanish and then show the output of AdvancedVanishAPI.INSTANCE.getVanishedPlayers().size()?

from advancedvanish.

TheSheepGoesBa avatar TheSheepGoesBa commented on July 27, 2024

I see, that makes sense. AdvancedVanishAPI.INSTANCE.getVanishedPlayers().size() always outputs 0 no matter if I am in vanish or not. I am using softdepend: [AdvancedVanish] but I don't think that should be an issue.

from advancedvanish.

quantiom avatar quantiom commented on July 27, 2024

The problem was that he was shading the whole AdvancedVanish plugin into his plugin, so he was accessing a different instance of it. Closing this as completed now.

from advancedvanish.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.