mirror of
https://gitlab.com/Deukhoofd/DeukBot4.git
synced 2026-10-10 17:04:00 +00:00
Ask user what he wants an opinion about if nothing is given
This commit is contained in:
1 file changed
+4
@@ -9,6 +9,10 @@ namespace DeukBot4.Utilities
|
||||
public static async Task<string> GetOpinion(CommandRequest request)
|
||||
{
|
||||
var extend = request.Parameters[0].AsString().ToLowerInvariant();
|
||||
if (string.IsNullOrWhiteSpace(extend))
|
||||
{
|
||||
return "Think about what?";
|
||||
}
|
||||
var random = new Random(extend.GetHashCode());
|
||||
var positive = random.Next(-20, 80) < (int) request.RequestPermissions;
|
||||
|
||||
|
||||
Reference in new issue
Block a user