PyvesB / advanced-achievements

:fireworks: Popular plugin that adds unique and challenging achievements to Minecraft servers.
https://www.spigotmc.org/resources/83466
GNU General Public License v3.0
199 stars 215 forks source link

Something... Not sure if its a bug or an config mistake. #905

Closed Remski01 closed 3 years ago

Remski01 commented 3 years ago

Sorry if this is the wrong place, but we have an issue that it doesnt count up in the progress bar,

Version:

setting:

Breaks:
  gold_ore1:
    '1000':
      Goal: Mijn 1000 gold ore.
      Message: PLACEHOLDER (GPM)1
      Name: break_1000_gold_ore
      DisplayName: Econoom 1
      Type: normal
      Reward:
        Command:
          Execute: lp user PLAYER permission set bossshop.voteshop.gpm1
          Display:
          - Krijg 1 EUR per minuut dat je online bent.
PyvesB commented 3 years ago

Hello @Remski01 ! 👋🏻

I think it should be gold_ore instead of gold_ore1. 😉

Remski01 commented 3 years ago

Ow, thoughed it didnt look to there. We have multiple one related to the gold ore, is it not going break with the others? (I thoughed it looked to _gold_ore line and not before the :

(I ask this because i cant test it myself, #AtWork)

PyvesB commented 3 years ago

The Name parameter (containing _gold_ore) is used in commands and to mark the achievement as completed in the database, but not for any other logic on the statistics. You could call it this_achievement_is_the_best, it would still work, though once players have started receiving the achievement, you should not change the Name as the database key will no longer match.

If you've got multiple achievements related to gold ore, you should all put them in the same section:

Breaks:
  gold_ore:
    '1000':
      Goal: Mijn 1000 gold ore.
      Message: PLACEHOLDER (GPM)1
      Name: break_1000_gold_ore
      DisplayName: Econoom 1
      Type: normal
      Reward:
        Command:
          Execute: lp user PLAYER permission set bossshop.voteshop.gpm1
          Display:
          - Krijg 1 EUR per minuut dat je online bent.
    '10000':
      Goal: Mijn 10000 gold ore.
      Message: PLACEHOLDER (GPM)2
      Name: break_10000_gold_ore
      DisplayName: Econoom 2
      Type: normal
      Reward:
        Command:
          Execute: lp user PLAYER permission set bossshop.voteshop.gpm2
          Display:
          - Krijg 2 EUR per minuut dat je online bent.
Remski01 commented 3 years ago

Ahha, now i understand. Thanks for the quick respons :+1:

Would like to ask to keep the ticket open though, will close it if it works as intended after testing when i'm home.

Remski01 commented 3 years ago

Yes, that worked. But i now have an other question.

Is it not posibble to have a second color in the Display: section under Rewards? When trying we get this error: https://pastebin.com/YV11bwC1

if its not possible could you look into adding support for it?

Remski01 commented 3 years ago

Tested it again but diffrent, seem that it was caused by setting it this way: ` Display:

but not longer an issue when its

` Display:

So might worth to take a look at if possible in case other people having issue's with it that also trying it on there first run. Other then that i havo no more questions. Plugins works as intended. Thanks for the great plugin.

(Will keep ticket open till you close it so that the ^ wont get forgetten)

Remski01 commented 3 years ago

And other small issue. Interesting thing. Question. How can i remove the default prefix. Because...

If you set

# Set the format of the header used for most chat messages (default: "§7[%ICON%§7]").
ChatHeader: "§7[%ICON%§7]"

to

# Set the format of the header used for most chat messages (default: "§7[%ICON%§7]").
ChatHeader: 

Its going remove the whole both lines from the config file and display the default prefix. And if you set it to "" its still going show the default prefix.

PyvesB commented 3 years ago

Setting it to "" should work, but maybe that's an area where Paper differs from Spigot in the underlying API behaviour. Alternatively, you could simply set it to §r, that should work everywhere.

PyvesB commented 3 years ago

Tested it again but diffrent, seem that it was caused by setting it this way: Display: - &2test &6test &2test &5test

but not longer an issue when its

Display: - test &6test &2test &5test

So, the first one is invalid YAML, whereas the second one isn't. You can check through http://yaml-online-parser.appspot.com/ to convince yourself 😉

Remski01 commented 3 years ago

Ahha, i see. Then still a last question. Is there a api check if some have enabled or disabled to receive the notifs when someone received a achievment? (/aach toggle)

PyvesB commented 3 years ago

There is no such API. Do you want to check whether a player has called /aach toggle programmatically, i.e. from another plugin using Java code?

Remski01 commented 3 years ago

We are looking to ad an soort of SettingsGUI where a bunch of settings can be found. But this would need to be possible to be checked.

I myself dont know much about coding. Just know this sort of information could be pulled from an api, what our custom plugin could do, but you saying there is none is going make it difficult.

Could you look into a way to allow an plugin to pull this sort of information? Or (if possible) add an placeholder what would display its status.

With that said. I read it have an type urgement. And have not yet tested it myself. But by gueesing i would so the Type is what sort as Break, place, craft etc, as where just using /aach toggle disables all

PS:

PyvesB commented 3 years ago

Could you please open a new issue for the toggle status API feature request? Like that we can close this one which has deviates quite a bit from the initial purpose. 😉

Remski01 commented 3 years ago

Ya sure, just wanted to know first if you would like todo this as we might drop this idea of our other toggle plugins have no interest in adding this feature. By the sound you look to be interested in adding this. So have it noted. If the other plugins are also willing to add support for this, i will make the pull request. If not, well. Then you want see it unless they reconsider it later down the road.