PermissionsEx

PermissionsEx

14M Downloads

Refactor contexts

zml2008 opened this issue ยท 0 comments

commented

Blocks: #1923, #2318

Contexts were a good first start, but to allow some more extensive use cases (timed permissions, easily handling GriefDefender, etc) we're going to need to add more powerful matching and prioritizing features.

Key points to consider

  • allow prioritizing contexts (ex. the GD usecase of claim-override -> claim-type -> claim being used in the same position)
  • User-friendly (relative time, claim name, world name) vs. absolute (timestamp, UUID) permissions, and making sure even manually entered user-friendly values are made absolute
  • Calculating permissions remote from the subject's active state, resulting in active +some, or active but without a specific calculator
  • Create context objects that can be shared between upstream and other permissions plugins

Contexts needed

  • Timed (before and after a given time)
  • Region (as used in GriefDefender and GriefPrevention)