-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* New command: ~msync Tested on my private server, but still check my code since I'm a junior in Rust * # New command: ~msync # Invoked by is now: - Is a subtitle - Shows how to use the command # Includes hahayup's pr that adds ~paths Tested on my private server, but still check my code since I'm a junior in Rust
- Loading branch information
Showing
11 changed files
with
60 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,3 +8,4 @@ pub mod discord; | |
pub mod username; | ||
pub mod heroic; | ||
pub mod whats_where; | ||
pub mod msync; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
use crate::{Context, Error}; | ||
|
||
#[poise::command(prefix_command, slash_command)] | ||
pub async fn msync(ctx: Context<'_>) -> Result<(), Error> { | ||
let mut message = "## Steam download stops? | ||
1. Kill All Bottles: Press `Command`⌘ + `Shift`⇧ + `K` or Go to `File` (near the Apple logo) -> `Kill All Bottles` | ||
2. Change MSync to ESync: `Bottle Configuration` -> `Enhanced Sync` | ||
3. Run Steam".to_owned(); | ||
|
||
if let Context::Prefix(prefix) = ctx { | ||
match prefix.msg.clone().referenced_message { | ||
Some(parent) => { | ||
message += &format!("\n-# This command was invoked by {} using `~{}`", ctx.author().to_string().as_str(), "msync"); | ||
|
||
parent.reply_ping(&ctx, message).await?; | ||
prefix.msg.delete(ctx).await?; | ||
}, | ||
None => { | ||
message += &format!("\n-# This command was invoked using `~{}`", "msync"); | ||
ctx.reply(message).await?; | ||
} | ||
} | ||
} else { | ||
ctx.reply(message).await?; | ||
} | ||
Ok(()) | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters