RogueException
2c075e186a
Added support for custom ModuleBase command contexts. Added SocketCommandContext/RpcCommandContext.
2016-12-23 16:57:30 -04:00
AntiTcb
5118ed876b
Can target classes now.
2016-12-19 17:54:06 -05:00
FiniteReality
d2d7b4dce7
Make _typeReaderTypeInfo static
...
Seems I missed this originally, whoops.
2016-12-03 23:49:05 +00:00
FiniteReality
156483bf71
Rename overridenType to overridenTypeReader
...
The previous name was causing some confusion
2016-12-03 23:49:05 +00:00
FiniteReality
f11f416024
Add IDependencyMap to parameter preconditions
2016-12-03 23:49:05 +00:00
FiniteReality
b7a5ee6542
Parameter preconditions and typereader overriding
2016-12-03 23:49:05 +00:00
RogueException
08ae9e4e86
Fixed logic in precondition attribute docstrings
2016-11-27 01:13:29 -04:00
RogueException
2a33bb0c12
Escaped amp in XML example.
2016-11-27 01:07:19 -04:00
RogueException
a0c9ba92db
Merge branch 'dev' into feature/more-preconditions
2016-11-26 23:41:45 -04:00
Christopher F
fb99b019a0
Fix issues with DefaultRunMode
...
For a command to use the DefaultRunMode, it must now have it's RunMode set to RunMode.Default (this is the default value on CommandAttribute now).
2016-11-26 22:04:02 -05:00
Christopher F
1ed4f703bf
Cache the current application on DiscordSocketClient
2016-11-26 14:59:20 -05:00
Christopher F
f9c5e229d0
Add CommandServiceConfig, DefaultRunMode
...
This adds an (optional) CommandServiceConfig, as well as a DefaultRunMode for commands.
This resolves #368 (for commands where a RunMode is not explicitly specified, a custom default value should be used)
2016-11-25 18:49:35 -05:00
Christopher F
defc8f1c4e
Add docstrings to preconditions.
2016-11-25 18:09:18 -05:00
Christopher F
ea148db08b
Add RequireBotPermission, rename RequirePermission
...
This is a breaking change.
Adds a precondition that requires the bot has a specified permission (Resolves #211 ).
Renames RequirePermission to RequireUserPermission.
2016-11-25 17:48:08 -05:00
Christopher F
fdecfe6bd4
Add RequireOwner Precondition
...
This precondition will require that the invoker of the command is the owner of the bot.
2016-11-25 17:44:37 -05:00
RogueException
c7ac85455f
Added a configurable run mode for commands
2016-10-10 21:16:34 -03:00
RogueException
635819b89f
Reduced command module lifetime to a single command execution. Removed ModuleAttribute.
2016-10-10 20:27:16 -03:00
RogueException
708f9fe514
Added CommandContext, fixed commands compile errors
2016-10-04 09:54:44 -03:00
FiniteReality
accb3e27b8
Add PriorityAttribute and sortby priority in Search
2016-09-15 18:43:06 +01:00
Khionu Terabite
b6c634b8b5
Renamed Description/Summary Attributes to Summary/Remarks, as per discussion in #239
2016-09-06 16:19:43 -04:00
RogueException
23a0316252
Split IMessage into IUserMessage and ISystemMessage
2016-08-27 19:07:22 -03:00
FiniteReality
95cf63243d
Implement Command Aliases
...
This implementation could probably be more efficient, but I
opted for clarity and simplicity where possible.
2016-08-26 22:28:35 +01:00
RogueException
9951112908
Readded AutoLoad setter
2016-08-18 20:21:36 -03:00
RogueException
06e81cbcca
Merge pull request #206 from FiniteReality/issue/203
...
Add NameAttribute for overriding Name in commands/modules
2016-08-18 11:30:13 -03:00
RogueException
6d766d5f98
Cleaned up command attributes
2016-08-18 11:28:12 -03:00
FiniteReality
252d89000d
Fix comment copy+paste fail
2016-08-18 14:09:47 +01:00
FiniteReality
8b864d4b9e
Fix #203 by adding a NameAttribute to override Name
2016-08-18 13:50:02 +01:00
RogueException
ac49f4b8b0
Rename RequirePermission -> RequirePermissionAttribute
2016-08-16 00:42:59 -03:00
RogueException
63d3b93975
Removed Discord.Commands.Attributes.Preconditions namespace
2016-08-09 23:44:10 -03:00
RogueException
dcb603acd7
Cleaned up permission checks, added Permissions.Has(enum) methods
2016-08-09 18:18:50 -03:00
RogueException
0b9f9b16a9
Merge pull request #178 from DigiTechs/command_tweaks
...
Command tweaks
2016-08-09 17:31:10 -03:00
Finite Reality
f2d80de343
Fix error with RequirePermission precondition
2016-08-07 17:23:26 +01:00
Finite Reality
c77c84bec7
Remove ContextType.Invalid
2016-08-06 00:43:11 +01:00
Finite Reality
6db3f52ac1
eplace DM/Guild preconditions with context
...
The new RequireContextAttribute works just like RequireDM/RequireGuild,
but is more powerful as developers can specify multiple 'contexts' for
their command to require using the ContextType flags.
2016-08-06 00:15:11 +01:00
Finite Reality
86092f9253
Rename Synopsis to Summary to improve clarity
2016-08-05 00:17:29 +01:00
Finite Reality
11f1163ec2
Add Command and module instance parameters to CheckPermissions
...
After a small discussion with Joe4evr on discord, a way of retrieving the
state of a module appeared to be needed. The new override should provide
enough context to a bot dev to allow them to do what they want.
2016-08-04 23:31:21 +01:00
Finite Reality
046d56cab5
Add module-level preconditions and precondition for individual permissions
2016-08-04 19:36:14 +01:00
Finite Reality
0e920da21f
Complete Preconditions implementation
2016-08-03 17:21:38 +01:00
Finite Reality
a5393dc937
Rename Permission to Precondition
2016-08-03 16:50:51 +01:00
Finite Reality
47089448dd
Fix Synopsis/Description mix-up
2016-08-03 16:33:26 +01:00
Finite Reality
757c36ccd1
Rename and move things about
2016-08-03 16:09:58 +01:00
Finite Reality
8c0d4b6123
Improve command documentation features
2016-08-02 23:08:33 +01:00
Finite Reality
eb38bdd437
Fix indentation
2016-08-02 17:54:52 +01:00
Finite Reality
772fd97080
Implement initial command permissions system
...
After our initial discussion on the matter (see #172 ) this is the system
that we all seem to have agreed on. As a result, I have implemented a
simple system which effectively implements permissions, while being
extensible and tweakable so bot devs can decide what they want to do for
permissions.
As for default 'permissions', I'm not sure what the best approach would be
here; bot devs are likely to implement their own permissions 'levels' and
use those. I think the most we could do for now is add attributes to
require certain users (by id) and certain roles (by id and possibly by
name?) This would probably be the best option for now as it requires less
work from us, nor do we know the *exact* approach bot devs want to take
with permissions.
2016-08-02 17:29:39 +01:00
Khionu Terabite
846a1746a2
Added Command.Synopsis for seperation of short and long descriptions, this being intended for long.
2016-07-30 18:09:38 -04:00
RogueException
c5569a44ea
Renamed Unparsed -> Remainder. Fixed non-string remainder parameters.
2016-07-29 23:10:13 -03:00
Finite Reality
f7455c389b
Improve DI system
2016-07-21 00:23:49 +01:00
Christopher F
6e42acba68
Add Autoload to Module Attribute
...
[UNTESTED] Adds an optional parameter to the Module attribute, "autoload", which defaults to true.
Specifies whether or not the assembly crawler should load this module.
2016-07-20 17:20:37 -04:00
RogueException
7bb890cbfe
Added command groups, fixed several bugs
2016-06-27 06:56:24 -03:00
RogueException
f59b6b9004
Implemented command type readers, parser and service.
2016-06-26 03:35:40 -03:00