Code Monkey home page Code Monkey logo

afkpluspapi's People

Contributors

dart2112 avatar notalexnoyle avatar

Watchers

 avatar

Forkers

notalexnoyle

afkpluspapi's Issues

Not properly be parsed by PlaceholderAPI

I can't seem to get it to properly be parsed by PlaceholderAPI.
I've installed the latest version of both AFK+ from the Spigot resource page and AFKPlusPAPI from the GitHub release.
No warnings/errors in console and the base functionality works great!

The issue is the placeholder is not being evaluated. When I run:
papi parse (any online player) %AFKPlus_Status%
in the console or in-game, it simply returns:
%AFKPlus_Status%
(same with %AFKPlus_AFKTime%).

Using Paper #90 1.16.1.

Missing AFKPlus:jar:3.2.4 needed for building

When building the plugin with mvn I get this error:

[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  31.727 s
[INFO] Finished at: 2021-11-05T12:05:27+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project afkpluspapi: Could not resolve dependencies for project net.lapismc:afkpluspapi:jar:0.3.0: Could not find artifact net.lapismc:AFKPlus:jar:3.2.4 in spigotmc-repo (https://hub.spigotmc.org/nexus/content/repositories/snapshots/) -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException

How can I build the plugin?

NullPointerException triggered by player login when AFKPlus_Status placeholder is used in tablist

When using the AFKPlus_Status placeholder provided by Afkpluspapi, there is sometimes an NullPointerException caused initially when a player logs in:

[12:33:28] [Server thread/INFO]: [redacted][/redacted:57564] logged in with entity id 86942 at ([survival]545.6999999880791, 42.0, 164.30000001192093)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: java.lang.NullPointerException
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at net.lapismc.afkplus.AFKPlus.getPlayer(AFKPlus.java:92)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at net.lapismc.afkplus.api.AFKPlusPlayerAPI.getPlayer(AFKPlusPlayerAPI.java:56)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at net.lapismc.afkpluspapi.PAPIHook.onPlaceholderRequest(PAPIHook.java:26)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at me.clip.placeholderapi.PlaceholderHook.onRequest(PlaceholderHook.java:34)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at me.clip.placeholderapi.replacer.CharsReplacer.apply(CharsReplacer.java:156)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at me.clip.placeholderapi.PlaceholderAPI.setPlaceholders(PlaceholderAPI.java:69)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at me.clip.placeholderapi.PlaceholderAPI.setPlaceholders(PlaceholderAPI.java:97)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at hu.montlikadani.tablist.bukkit.utils.Variables.setPlaceholders(Variables.java:241)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at hu.montlikadani.tablist.bukkit.utils.Variables.replaceVariables(Variables.java:162)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at hu.montlikadani.tablist.bukkit.TabListPlayer.getSuffix(TabListPlayer.java:261)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at hu.montlikadani.tablist.bukkit.TabListPlayer.getCustomTabName(TabListPlayer.java:267)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at hu.montlikadani.tablist.bukkit.tablist.groups.ReflectionHandled.setTeam(ReflectionHandled.java:81)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at hu.montlikadani.tablist.bukkit.Groups.setPlayerTeam(Groups.java:165)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at hu.montlikadani.tablist.bukkit.Groups.updatePlayers(Groups.java:292)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at hu.montlikadani.tablist.bukkit.Groups.lambda$startTask$0(Groups.java:269)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at org.bukkit.craftbukkit.v1_16_R3.scheduler.CraftTask.run(CraftTask.java:99)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at org.bukkit.craftbukkit.v1_16_R3.scheduler.CraftAsyncTask.run(CraftAsyncTask.java:54)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at com.destroystokyo.paper.ServerSchedulerReportingWrapper.run(ServerSchedulerReportingWrapper.java:22)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[12:33:28] [Craft Scheduler Thread - 1251/WARN]: 	at java.lang.Thread.run(Thread.java:748)

This repeats about 10 times

Followed by:

[17:07:18] [Craft Scheduler Thread - 2140/WARN]: java.lang.NullPointerException
[17:07:18] [Craft Scheduler Thread - 2139/WARN]: java.lang.NullPointerException

Being spammed in the console every second.

I've also noticed while another player logged in (in the same server session as the above errors), another exception:

[17:07:16] [Server thread/INFO]: [redacted][/redacted:60944] logged in with entity id 168899 at ([survival]-126.66186848210126, 84.0, -7052.463444635633)
[17:07:17] [Craft Scheduler Thread - 2135/WARN]: [TabList] Plugin TabList v5.5.2 generated an exception while executing task 100751312
java.lang.NullPointerException: null

I am using this plugin for my tablist: https://www.spigotmc.org/resources/animated-tab-tablist.46229

This error does not happen every time a player logs in, but only rarely.
When the player which triggered the issue leaves, the NullPointerException warnings do not stop being spammed in the console.

Versions:
AFKPlus -> 3.2.6 (latest)
Afkpluspapi -> 0.2.0 (latest)
TabList -> 5.5.2 (latest)
PlaceholderAPI -> 2.10.9 (latest)
Server is running on PaperMC build #455 (1.16.5)

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.