Flight Timer
What is and does it?
This plugin allows server-owners to limit the time that players can fly. For example: by default a player can fly for 10 seconds, and has a cool-down of 5 minutes. If you have a higher rank, you could have a flight time of 5 minutes and just a cooldown of 20 seconds. This way, flying is not overpowered and can still be given as a reward in game.
How to use the plugin as a Player?
Every player has a flight timer. This is the time you can fly. If the flight-timer is empty, than you will drop down of the sky and you will enter a cool-down. The cool-down length depends on your rank. You can check your status by using the command '/fly check'. This command also shows you your rank. You can use the command '/fly' to start fling and again '/fly' to stop flying. If you stop fling your flight-timer will stop counting down. If you want to see how much flight-time you have left, you can use the command '/fly check'.
How to use the plugin as a Server Owner?
In the config file you will find by default a rank.op and a rank.default node. Every rank has two variables: airTime (the time a player can fly) and cooldownTime(The time the player has to wait before flying again). This is the default config:
rank: op: airTime: -1 cooldownTime: -1 default: airTime: 10 cooldownTime: 300
You may never delete the op and default rank because these are auto-assigned. If they are missing, the console will be flooded with errors. You can add custom ranks by adding the ranks to the config. An example of a custom config is this:
rank: op: airTime: -1 cooldownTime: -1 default: airTime: 5 cooldownTime: 600 Vip: airTime: 30 cooldownTime: 20 VipPlus: airTime: 60 cooldownTime: 10 Admin: airTime: -1 cooldownTime: -1
In this example there are 3 custom ranks. Here is what these ranks do:
| name | who | fly time | cool-down time |
|---|---|---|---|
| default | everyone without a special permission gets this rank | 5 seconds | 10 minutes |
| op | every operator. The Operator rank overwrites all other permission nodes. | forever flying | no cool-down |
| Vip | everyone with the flight.Vip permission. | 30 seconds | 20 seconds |
| VipPlus | everyone with the flight.VipPlus permission. | 60 seconds | 10 seconds |
| Admin | everyone with the flight.admin permission. | forever flying | no cool-down |
So in short, you can add ranks and give those ranks by giving the player the permission flight.rankname. If you have a airTime of -1 than the player can fly forever.
If something is unclear, leave a comment and i will do my best to explain it.
Help me
If you find any bugs or problems, please create a ticket at the Github repository. This way i will be able to fix it as fast as possible. You can also just leave a comment here, but it might take some more time for me to notice. Also there might be spelling faults in the plugin. This is something i would love to fix. So if you find any spelling errors, please tell me. Next if you have things that could be improved, just send me a message and we can talk about it.
Code
If you want to see how the plugin works behind the scenes, you can look at the Source Code hosted on Github.

