Parkour

Parkour

570k Downloads

Cannot clear prize?

tonydew opened this issue ยท 2 comments

commented

Hosted Server running: paper_1.19.2.jar
Parkour plugin: (Version: [1.8 - 1.19] - 7.0.2 - Jun 25, 2022 - Release)
Maybe related to: #98

TL;DR: /pa reset prize our_course_name not clearing list of commands entered as prize.

This plugin is great, thank you! We're having a lot of fun on our server.

Issue: We have a parkour course that we give a command as a prize. It works as expected, but we made a mistake in the command and went to change it. Eventually we figured out that the commands stack as you add them, not overwrite. We then found reset the command for the prize: /pa reset prize our_course_name

We get the confirmation and success messages after \pa yes but after testing, the prizes remain. So we have the same stack of commands applying every time the course is completed.

Am I missing something, or is this a bug?

I've been able to fix it in the meantime by directly editing plugins/Parkour/courses/our_course_name.json file and removing the stacked commands from the "Prize" array.

commented

Hi, thank you for raising this.
Yes I agree this is a bug and I'll fix it in a small release soon.

commented

I have had another thought for this - because commands cover all Parkour events and not just prizes I think it's safer to have a dedicated command to reset the Course commands.
Using "/pa reset commands (course)" will remove all per-course commands.
Available in a snapshot here, pending release: https://github.com/A5H73Y/Parkour/releases/tag/master-RELEASE.57