Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pzdebug command #92

Open
Bennn3t opened this issue Oct 27, 2023 · 5 comments
Open

pzdebug command #92

Bennn3t opened this issue Oct 27, 2023 · 5 comments
Labels
look into further Might not be worth it or possible, look into further

Comments

@Bennn3t
Copy link

Bennn3t commented Oct 27, 2023

Would there be a way of making a command to globally debug all polyzones, /pzdebug [distance]?

This could be extremely useful when trying to quickly enable the debug option without having to enable it within the code and then restart the script.

@mkafrin mkafrin added the look into further Might not be worth it or possible, look into further label Oct 29, 2023
@mkafrin
Copy link
Owner

mkafrin commented Oct 29, 2023

@Bennn3t It's been thought of before but will have to think about it, cause it would add overhead. Either an event handler would need to be added to every zone, or PZ would need to keep track of every enabled zone in memory. Maybe if it was behind some global dev/debug mode flag it'd be fine, cause I just don't want it effecting production performance.

To add, this can be kind of done now by using a ComboZone for your zones (which is good practice anyways) and then looping through those zones to call the draw method on them based on their distance.

@Bennn3t
Copy link
Author

Bennn3t commented Oct 30, 2023

@mkafrin I understand your point, but I don't think it'll impact the production performance since it's only activated when the client enables the debug option. I remember using it on a server a few months ago, but I can't recall the exact method. However, working with polyzones using that command was much simpler back then. Now, toggling the debug through setting debugPoly feels like a hassle.

I hope you take a closer look at this because I truly believe it would be a fantastic addition to the PolyZone resource. It could be just as helpful to others as it was for me and my previous server.

@Chisomraph
Copy link

when i do /pzcreate box i dont see it
any idea what i should do?

@Bennn3t
Copy link
Author

Bennn3t commented Dec 1, 2023

@Chisomraph
This issue has no relevance to this thread, open a new issue.

@gullithisouza
Copy link

I find the polyzone debug option very useful. Imagine an example where we want to wage a war between gangs where an invasion will be carried out in that area, only if it is permitted and demonstrated.

Then we will create a command "invasion 3 on" ([polyzone id] [show]) to show a certain polyzone already created.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
look into further Might not be worth it or possible, look into further
Projects
None yet
Development

No branches or pull requests

4 participants