What I have typed wrong???

Discussion in 'Plugin Development' started by hihii55, May 5, 2012.

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

    hihii55

    I got an error while parsing my plugin's plugin.yml. Can you help me?

    plugin.yml:
    Show Spoiler

    name: mcGuns
    main: org.hihii55.mcGuns.McGuns
    version: Alpha 0.1-dev
    authors: [hihii55]
    description: mcGuns gives you to use modern weapons, like guns, grenades, molotov cocktails, etc. They do not look like guns. Their name plate is the original, but they still are guns. They have different properties. Even sniper is in development.
    commands:
    mcguns:
    description: The main help page of mcGuns
    guns:
    description: The main help page of mcGuns
    gun:
    description: The main help page of mcGuns
    permissions:
    mcguns.*:
    description: Gives ALL mcGuns permissions
    children:
    mcguns.help: true
    mcguns.use.*: true
    mcguns.admin.*: op
    mcguns.info: true
    mcguns.owner: false
    mcguns.help:
    description: Gives access to use the main/help command
    mcguns.use.*:
    description: Gives access to do default things
    children:
    mcguns.use.craft.*: true
    mcguns.use.shoot.*: true
    mcguns.use.holding.*: true
    mcguns.admin.*:
    description: Gives access to use admin commands/things
    children:
    mcguns.admin.adminhelp: op
    mcguns.admin.inifiteammo: op
    mcguns.admin.seize: op
    mcguns.admin.givegun.*: op
    mcguns.admin.giveammo.*: op
    mcguns.use.craft.*:
    description: Gives access to player to craft guns
    children:
    mcguns.use.craft.pistol.*: true
    mcguns.use.craft.assaultrifle.*: true
    mcguns.use.craft.shotgun.*: true
    mcguns.use.craft.sniper.*: true
    mcguns.use.shoot.*:
    description: Gives access to shoot/throw
    children:
    mcguns.use.shoot.pistol.*: true
    mcguns.use.shoot.assaultrifle.*: true
    mcguns.use.shoot.shotgun.*: true
    mcguns.use.shoot.sniper.*: true
    mcguns.admin.givegun.*:
    description: Gives access to make guns from nothing, like /give
    children:
    mcguns.admin.givegun.pistol.*: op
    mcguns.admin.givegun.assaultrifle.*: op
    mcguns.admin.givegun.shotgun.*: op
    mcguns.admin.givegun.sniper.*: op
    mcguns.admin.adminhelp:
    description: Gives access to use /mcguns admin-command
    mcguns.use.shoot.pistol.*:
    children:
    mcguns.use.shoot.pistol.deserteagle
    mcguns.use.shoot.pistol.m1911
    mcguns.use.shoot.pistol.g18
    mcguns.admin.givegun.pistol.*:
    children:
    mcguns.admin.givegun.pistol.deserteagle
    mcguns.admin.givegun.pistol.m1911
    mcguns.admin.givegun.pistol.g18



    you can also read this at pastebin:
    http://pastebin.com/LE23qJuK

    The errors/server log:
    Show Spoiler

    [SEVERE] Could not load 'plugins/mcGuns.jar' in folder 'plugins'
    org.bukkit.plugin.InvalidDescriptionException: Invalid plugin.yml
    at org.bukkit.plugin.java.JavaPluginLoader.getPluginDescription(JavaPluginLoader.java:203)
    at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager.java:132)
    at org.bukkit.craftbukkit.CraftServer.loadPlugins(CraftServer.java:207)
    at org.bukkit.craftbukkit.CraftServer.<init>(CraftServer.java:183)
    at net.minecraft.server.ServerConfigurationManager.<init>(ServerConfigurationManager.java:53)
    at net.minecraft.server.MinecraftServer.init(MinecraftServer.java:156)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:422)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:492)
    Caused by: mapping values are not allowed here
    in "<reader>", line 40, column 21:
    children:
    ^

    at org.yaml.snakeyaml.scanner.ScannerImpl.fetchValue(ScannerImpl.java:733)
    at org.yaml.snakeyaml.scanner.ScannerImpl.fetchMoreTokens(ScannerImpl.java:305)
    at org.yaml.snakeyaml.scanner.ScannerImpl.checkToken(ScannerImpl.java:179)
    at org.yaml.snakeyaml.parser.ParserImpl$ParseBlockMappingKey.produce(ParserImpl.java:563)
    at org.yaml.snakeyaml.parser.ParserImpl.peekEvent(ParserImpl.java:161)
    at org.yaml.snakeyaml.parser.ParserImpl.checkEvent(ParserImpl.java:146)
    at org.yaml.snakeyaml.composer.Composer.composeMappingNode(Composer.java:230)
    at org.yaml.snakeyaml.composer.Composer.composeNode(Composer.java:160)
    at org.yaml.snakeyaml.composer.Composer.composeMappingNode(Composer.java:237)
    at org.yaml.snakeyaml.composer.Composer.composeNode(Composer.java:160)
    at org.yaml.snakeyaml.composer.Composer.composeMappingNode(Composer.java:237)
    at org.yaml.snakeyaml.composer.Composer.composeNode(Composer.java:160)
    at org.yaml.snakeyaml.composer.Composer.composeDocument(Composer.java:123)
    at org.yaml.snakeyaml.composer.Composer.getSingleNode(Composer.java:106)
    at org.yaml.snakeyaml.constructor.BaseConstructor.getSingleData(BaseConstructor.java:121)
    at org.yaml.snakeyaml.Yaml.loadFromReader(Yaml.java:480)
    at org.yaml.snakeyaml.Yaml.load(Yaml.java:411)
    at org.bukkit.plugin.PluginDescriptionFile.<init>(PluginDescriptionFile.java:42)
    at org.bukkit.plugin.java.JavaPluginLoader.getPluginDescription(JavaPluginLoader.java:198)
    ... 7 more

    Please! Can you help me? :'(
     
  2. You have too much spacing on one "children" node, if you looked at the line the error said you would've seen it:
    Code:
        mcguns.use.craft.*:
            description: Gives access to player to craft guns
            children:
                mcguns.use.craft.pistol.*: true
                mcguns.use.craft.assaultrifle.*: true
                mcguns.use.craft.shotgun.*: true
                mcguns.use.craft.sniper.*: true
        mcguns.use.shoot.*:
            description: Gives access to shoot/throw
                children:
                mcguns.use.shoot.pistol.*: true
                mcguns.use.shoot.assaultrifle.*: true
                mcguns.use.shoot.shotgun.*: true
                mcguns.use.shoot.sniper.*: true
        mcguns.admin.givegun.*:
            description: Gives access to make guns from nothing, like /give
            children:
                mcguns.admin.givegun.pistol.*: op
                mcguns.admin.givegun.assaultrifle.*: op
                mcguns.admin.givegun.shotgun.*: op
                mcguns.admin.givegun.sniper.*: op
    
    Can you see the offset children ? :p
     
  3. Offline

    hihii55

    Thanks a lot :)
     
Thread Status:
Not open for further replies.

Share This Page