Filled Detect GameMode

Discussion in 'Plugin Requests' started by sasukebartioso, Nov 29, 2015.

Thread Status:
Not open for further replies.
  1. Offline

    sasukebartioso

    Hey guys,
    I was just wondering if anyone knows of or has the ability to make a plugin that detects gamemodes. As I run MobArena and some players have gamemode I was wondering if a plugin could be made so as that it detects a players gamemode and if it is a gamemode other than survival they have to change gamemode. I have tried doing this with inventories that restrict creative but despite blocking all mob arena commands they can still be accessed. So if anyone knows of or can make this plugin I would be very grateful...<3

    PLUGIN CATEGORY: Admin

    SUGGESTED NAME: RestrictedCommands

    WHAT I WANT: Basically I'd like for the plugin to detect if the player is in a gamemode other than survival then prompt them to change it.

    IDEAS FOR COMMANDS: No need for commands

    PERMISSIONS: restrictedcommands.comands

    WHEN I'D LIKE IT: When ever is good really
     
    Last edited: Nov 29, 2015
  2. Offline

    Mrs. bwfctower

  3. Offline

    Scimiguy

    When is it meant to detect that?
     
  4. Offline

    sasukebartioso

    If a player is in creative and tries to run a command that is listed as being blocked i.e. /ma j etc
     
  5. Offline

    Mrs. bwfctower

    @sasukebartioso So you'd specify commands in a config file (of this plugin), and if any of those commands are run, it puts the sender in survival mode?
     
  6. Offline

    sasukebartioso

    Yes, either it set's the person's game mode or prompts them to change it. I feel that the latter option would be preferable because it would further prevent any mixing up of the inventories in MobArena
     
  7. Offline

    Mrs. bwfctower

  8. Offline

    sasukebartioso

    I can't seem to be able to find a means of detecting a gamemode or blocking a command in said gamemode
     
  9. Offline

    crysis992

    Gonna make the plugin for you tomorrow if none wants to.
     
  10. Offline

    sasukebartioso

    If it's a too much work I really don't want to bother you. I appreciate any and all input n this thread but if you did it would be amazing
     
  11. Offline

    Mrs. bwfctower

    Just always run the command "/gamemode <player> 0"
     
  12. Offline

    sasukebartioso

    So would I be able to subscript this so that if any player above a certain rank runs the command /ma j
    then the command /gm <player> 0 would run automatically
     
  13. Offline

    Mrs. bwfctower

    I believe so.
     
  14. Offline

    sasukebartioso

    You wouldn't have any idea how to would you?
     
  15. Offline

    Mrs. bwfctower

    @sasukebartioso In the config.yml:
    Code:
    commands:
      /ma:
      - console: /gamemode <player> 0
    Not tested, but I think it should work.
     
  16. Offline

    sasukebartioso

    Tested and player still gets creative inv upon leaving
     
  17. Offline

    crysis992

    Download: *Here*

    Commands:
    /rcmd - Reload the configuration (Required Permission: rcmd.reload)

    Permissions:
    rcmd.bypass - This permission allows you to bypass the restriction.
     
    sasukebartioso likes this.
  18. Offline

    sasukebartioso

    You sir are a God among men. I hope you feel the love flowing through my screen right now <33333333333
     
  19. Offline

    Scimiguy

    Edit the title of this thread and mark it as filled
     
Thread Status:
Not open for further replies.

Share This Page