X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=include%2Fmode.h;h=894e7bef27b0f1c803a2eedb29c864fdb03369d4;hb=f7a563946c0f0f555440c30f91608880c9ebce89;hp=d00ec30211ab11bb1026a0a639bf4647350ff260;hpb=b7904e23726dfa497d276e193827c2e8685443eb;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/include/mode.h b/include/mode.h index d00ec3021..894e7bef2 100644 --- a/include/mode.h +++ b/include/mode.h @@ -211,6 +211,10 @@ class CoreExport ModeHandler : public Extensible */ char GetModeChar(); + /** For user modes, return the current parameter, if any + */ + virtual std::string GetUserParameter(User* useor); + /** * Called when a mode change for your mode occurs. * @param source Contains the user setting the mode. @@ -232,6 +236,14 @@ class CoreExport ModeHandler : public Extensible */ virtual void DisplayList(User* user, Channel* channel); + /** In the event that the mode should be given a parameter, and no parameter was provided, this method is called. + * This allows you to give special information to the user, or handle this any way you like. + * @param user The user issuing the mode change + * @param dest For user mode changes, the target of the mode. For channel mode changes, NULL. + * @param channel For channel mode changes, the target of the mode. For user mode changes, NULL. + */ + virtual void OnParameterMissing(User* user, User* dest, Channel* channel); + /** * If your mode is a listmode, this method will be called to display an empty list (just the end of list numeric) * @param user The user issuing the command