So I’ve worked with Bukkit plugins before, so the beginning part confuses me a little bit as it is not familiar, but the basic things from the first two lines of code is that it will return a result (ProcessResult, to be exact) which is the text displayed to the player upon execution of the command; it gets the source of the command, most likely of type Player or type Console, and the arguments of the command, everything beyond fg md <h,r> or foxguard modify <handler,region> ; it can throw exceptions when something is off with the command sent to this function; and it creates a basic array with the contents of the arguments in parse.args for easy use. After that, if no additional argument is given, it will return “Must specify a command!” to the user. Next, if the type is of group (so groups, group) it will go into the first if statement, which will immediately return “Must specify an operation!” if no more arguments are sent. It then goes into a switch statement, looking through each potential case of the second argument, the first of which is add. It will then try to return any bad values before it gets too far. So first, is there a third argument? If no, “Must specify a group name!” is returned. Is the third argument “default”? If yes, that is bad, so return “Default group already exists and its name is reserved!” It will then check a different function to check if the group name is valid (don’t know what would be an invalid group name) and if not, return “Not a valid group name!” Then it checks all existing groups, and if it already exists it will return “Group already exists with this name!” If it doesn’t, then it creates the group and looks through additional flags that can be set for the group: the “color” flag will set what color the group is in the handler, default is white; “displayname”, which I’m not quite sure what it does; and “index”, which specifies into which place in the hierarchy of roles the group gets placed.
…and etc. and so forth. It is past midnight where I am, and I have already spent 20 minutes deciphering and writing in plain English about 40 of over 400 lines of code. I would love to help work on this plugin as I would love to be able to specify game rules in certain regions so that keepInventory, fire spread, etc. could be enabled/disabled by region. If you want me to go through some more of the function I would be glad to sometime when I have more energy. I will tell you that I have no idea how the command parser works exactly, but I am a quick learner and can put in 20-40 hours a week depending on actual work and weekend commitments.
I was more looking for someone to be able to look at the code and gather a syntax skeleton of all the commands, their parameters and flags, and what they do.
Can this be used to change biomes? Can I select a set area and change it into a biome of my choice? Unfortunately for me, the world that was created ended up not having a mesa biome. This can be a issue due to certain pixelmon only spawning in the mesa. (Also the mod that you use to change spawn locations doesn’t work…)