forked from embee/woomy
		
	Merge branch 'next' of https://github.com/mudkipscience/woomy into next
This commit is contained in:
		
						commit
						0c98c5b803
					
				
					 2 changed files with 12 additions and 2 deletions
				
			
		| 
						 | 
					@ -4,7 +4,8 @@ exports.conf = {
 | 
				
			||||||
  aliases: [],
 | 
					  aliases: [],
 | 
				
			||||||
  permLevel: 'User',
 | 
					  permLevel: 'User',
 | 
				
			||||||
  requiredPerms: [],
 | 
					  requiredPerms: [],
 | 
				
			||||||
  cooldown: 2000
 | 
					  cooldown: 2000,
 | 
				
			||||||
 | 
					  joinArguments: 1
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
exports.help = {
 | 
					exports.help = {
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -106,6 +106,15 @@ module.exports = async (client, message) => {
 | 
				
			||||||
    message.flags.push(args.shift().slice(1))
 | 
					    message.flags.push(args.shift().slice(1))
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  let argsPossiblyJoined = args;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  if(cmd.conf.joinArguments) {
 | 
				
			||||||
 | 
					    if(args.length > cmd.conf.joinArguments && args.length > 1)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        argsPossiblyJoined[cmd.conf.joinArguments - 1] = args.slice(cmd.conf.joinArguments - 1).join(' ');
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  client.logger.log(`Command ran: ${cmd.help.name}`)
 | 
					  client.logger.log(`Command ran: ${cmd.help.name}`)
 | 
				
			||||||
  cmd.run(client, message, args, level, data)
 | 
					  cmd.run(client, message, argsPossiblyJoined, level, data)
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue