[POLL] Minigame library features

Discussion in 'Plugin Development' started by caseif, Feb 28, 2014.

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


    I'll lead by saying that this probably doesn't technically belong here, but I need to reach plugin developers, and this is the best subforum for that purpose.

    Now that that's out of the way, I've just started work on a project called MGLib. It's basically a library designed to ease the process of creating a minigame plugin. But, I've run into a small problem: I don't really know what to include. So far, I'd like to include a round management system (which handles things like arena importing/creation, lobbies, teleporting players, and starting/ending rounds in the minigame). That's about it. My question is this: what features would you, as a plugin developer, expect to see in such a library? I'm open to pretty much anything, so long as it's relevant. Just explain methods you would expect/like to see in the API class.

    A bit of technical info: the library functions as a Bukkit plugin. The server owner installs MGLib.jar, but it doesn't do anything until plugins actually start hooking into it. This is done by creating a new instance of its API class (currently com.headswilllol.mglib.api.Minigame (should I shorten it?)) and then building off of its non-static methods to create your own minigame plugin. This way, there's no need to include any of its code; you'll be able to call its methods so long as the server owner has the library installed, and there's also no need to update your plugin to include any of MGLib's new code.
    The Fancy Whale likes this.
  2. Offline


    Custom mobs, throwing of items and guns. Maybe a world reset and would saving and reloading? Also disguising should probably be in there. Also you sould probably shorten the package names.
  3. Offline


    World resets are a part of round management. I like the idea of guns and disguising, but I'm not quite sure what you mean by item throwing. I'll also consider shortening the API's package name to make it easier to import. Thanks for the input!
  4. Offline


    For example throwing mob eggs like a snow ball.
  5. Offline


  6. Offline


    I don't know how practical that would be. I feel like a small percentage of plugins would use it, so it wouldn't really be worth the effort. I don't actually know if that's even possible with just the API.

    Sounds interesting. Mind elaborating?
  7. Offline


    Teams, area management, listener hooks, rollback, teams/FFA, goals (CTF, LMS), think of mini games you've played, and how to simplify the process of making a mini game such as that.
    Europia79 likes this.
  8. Offline


    Option to generate structurs, like walls and such, for example, an obstacle mini game like a maze where you would have moving walls all the time - a structure generating engine would be nice for that.
  9. Offline


    But, what could the library provide that would be easier than directly using the Bukkit API?
  10. Offline


    The algorithms to generate the structures. For example - createWall(location, height), then you could play with it an add functions like moveWall (location, how much, direction) or have wall objects and such. Then you could make functions like removing the wall, making it temporarily invisible and such.
  11. Offline


    Hm, I see your point. I think that would slip to a lower priority though, as I couldn't see a large portion of plugins using it. But, I'll definitely consider it.

    Bumping in case anyone else has suggestions.​

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
    Last edited by a moderator: Jun 7, 2016
  12. Offline


    I am using your library atm and I like it. One thing that I do miss is teams. I have no clue how to create teams with your MGPlayer class.
  13. Offline


    MGLib currently doesn't have native team support, but what you can do is create a class which extends MGPlayer and has a field for a team, then supply it as the default player class with setPlayerClass() in the config manager.
  14. Offline


    I disagree with adding 'throwing items' and guns. It's a generic minigame library, not all minigames use guns and most are better without guns.

    Structure generation isn't necessary for a generalized minigame library. In fact, I discourage it: You should always encourage plugin users to build their own maps to have the most fun.

    I would have to agree with xTrollxDudex . You are making a generic minigame library so it shouldn't be too specific or leaning on one game type. So, include native team and ffa support, creating, deleting arenas, joining a lobby, leaving an arena, spectating, region protection, a lot of events to listen to, and probably a lot of custom events as a developer API because this is a library, after all.
    Zupsub and Europia79 like this.
  15. Offline


    I think the most important thing for developers is the availability of a public method that ENDS the mini-game... So that developers can end it based on their own conditions.

    Anything beyond that (and what you already mentioned) is just icing on the cake.

    Your idea is basically going to alleviate a lot of the work on people developing mini-games and allow them to focus on the rules and mechanics of their game... So it might attract a lot of inexperience developers (and to be fair, experienced ones too that know they shouldn't re-invent the wheel)... so my other suggestion would just be good documentation for all these new developers... That way, you don't have to answer a million of the same question... because it's in the documentation.

    Even if it's an extra bukkit dev page with some good links and an FAQ.

    Here are some good links all new devs should be familiar with

    I see a lot of questions about Scoreboards, so maybe a link for that too.

    This is a really good suggestion.
  16. Offline


  17. Offline

    The Fancy Whale

  18. Offline


    Something I'd really like to see is a complete spectator api.
    Currently, it is very difficult to handle, say, mob tracking.
    It is very difficult to make a mob stop tracking you once it's already targeted your player. Especially with the regular bukkit api. That poses great difficulties for us developers if we want to make our spectators worth more than just a way to get mobs to follow an invisible entity.
  19. Offline


    The Fancy Whale

    I wasn't requesting any features. He was asking what we "expect to see in such a library"

    AoH_Ruthless & xTrollxDudex have the best answers in my opinion: Sticking to the basics first and foremost, and putting yourself in the shoes of the end-users.

    Occasionally, I'll see a thread asking about a good mini-game library, so I'm sure ShadyPotato will get some more good suggestions too.
  20. Offline


    When making arena there should be an option for a teamed game and how many teams then setting who is on what team, also a option to make a no team arena. It would also be cool if there was a setWinner thing then you put in a team or player and then maybe a PlayerWinEvent and a TeamWinEvent.
  21. Offline


    I would like to see kits and join signs and I would love to see GUI shops that allow you to buy things for that game
  22. Offline

    The Fancy Whale

    That's for the developers to make. I believe the purpose of MGLib is for round and arena management not for the actual game features. That is all up to the developer. As far as join signs go, they have been implemented already and work great!

    Europia79 Sorry for the confusion, I meant more that the feature for ending a game is already implemented.

    monkeymanboy The teams are in the planned features, but MGLib can't tell when a player/team wins. Your plugin has to keep score and when the round ends can give points/credit/announce winners or whatever.
  23. Offline


    The Fancy Whale
    That's why I think there should be a function the plugin will keep track of the score then it will tell MGLib that a play/team one then MGLib could end that game and call the TeamWinEvent or PlayerWinEvent
  24. Offline


    That was added in a recent vanilla snapshot.
  25. Offline


    I really think this api is very useful;)

    You probably should add multiple spawns for all players / players in a team.

    Don't know whether it is already added, but the API should register commands to create arenas/lobby signs/spawns etc. So that the server owner can set these things and the plugin dev haven't to worry about.
    Also integration for WorldGuard/WorldEdit would be nice.

    It would be nice if you could add a option for the server owner (maybe minigame specific) to set, whether player who play in a minigame should be teleported to a free lobby for the next round after a round ended, so that the don't have to rejoin threw a sign.

    If you add teams also enable the server owner to set blocks/signs/entities for team selection.

    Multiple kits would be also nice, so that the plugin calls a method like Minigame#registerKits(Kit[]).
    Each Kit has a name and description and and an auto-flag.
    The server owner can set blocks/signs/entities to select a kit and the plugin is notified that player x has choosen kit y. If the player hasn't choosen any kit, the lib would give them the kit with the auto-flag.

    Since kits will probably not free for players, the server owner can set a price for that kit and your API will automatically withdraw the player using Vault. (Whether it will be one time or each time can be configured by the server owner)
    Players with a specific permisson (also configured by server owner) can use this kit for free or have the ability to buy it.

    Ok, long list but requested features. ;)

    Easiest possibility would be setting the player in creative mode.
  26. Offline


    Guns - CrackShot
    Disguising - There are plenty of plugins for that.

    It should be a minigame API, not a "code everything for us" API. Guns are for a gun API, disguising is for a disguise API. World reset/saving, however, is actually relevant to a minigame API.
    caseif and The Fancy Whale like this.
  27. Does it support multiple games being run at the same time?
  28. Offline

    The Fancy Whale

    Keeping score shouldn't be too difficult. Also, if you are able to keep score, you can create your own events as well for player/team winning and distribute prizes at that point. Not all games have a single winner/team or a set win time so I think it is easier to allow for the developer to fully customize the game play.

    Yes it does

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
    Last edited by a moderator: Jun 7, 2016
  29. Offline


    Would you mind sending a link to any sort of documentation providing further information into how this is achieved with bukkit api? As I have long been unable to come up with any sort of answer myself.
  30. Offline


    maybe a score board if that hasn't already been suggested.
Thread Status:
Not open for further replies.

Share This Page