- sm_com_restrictions | Default = 0 | "Enables/Disables ND Commander Restrictions"
- sm_com_min_level | Default = 1 | "Minimum level allowed to apply for commander."
- sm_com_max_level | Default = 60 | "Maximum level allowed to apply for commander."
- sm_com_restrict_time | Default = 60 | "Number of seconds after round start remove restrictions. [0 == Never Remove]" This exists in case no one on [min,max] applies for commander. If set greater than 0, the restrictions will be removed after t seconds.
- Players must have spawned at least once before they can apply. I don't see any way around this since levels are not loaded until they have spawned.
- Spam clicking apply would cause "ND_GetPlayerRank" to crash, so I added a 1.5 second timer to prevent it from restarting while the previous instance has not yet finished running. Unfortunately, this means that all clients cannot apply within 1.5 seconds of each other, so if you can think of a better way to code this, please let me know.
Attached Files commander_restrictions.smx (5.0 KB) Get Plugin or Get Source (commander_restrictions.sp - 4.3 KB)
Wyświetl pełny artykuł