-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add new struct CmdResult to represent properties of command
- Loading branch information
Showing
5 changed files
with
78 additions
and
61 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,7 @@ version = "0.1.0" | |
authors = ["Maxwell Anderson <[email protected]>"] | ||
edition = "2018" | ||
license = "MIT" | ||
description = "A text adventure written in Rust" | ||
description = "A text adventure dungeon crawler game written in Rust" | ||
readme = "README.md" | ||
repository = "https://github.com/Maxgy/kingslayer" | ||
keywords = ["text", "adventure", "game", "dungeon", "crawler"] | ||
|
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 |
---|---|---|
|
@@ -7,6 +7,7 @@ mod errors; | |
mod item; | ||
mod pathway; | ||
mod player; | ||
mod results; | ||
mod room; | ||
mod utils; | ||
mod world; |
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,13 @@ | ||
pub struct CmdResult { | ||
pub is_action: bool, | ||
pub command: String, | ||
} | ||
|
||
impl CmdResult { | ||
pub fn new(is_action: bool, command: &str) -> Self { | ||
Self { | ||
is_action, | ||
command: command.to_string(), | ||
} | ||
} | ||
} |
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 |
---|---|---|
@@ -1,5 +1,3 @@ | ||
from subprocess import call | ||
|
||
call(["cargo", "fmt"]) | ||
call(["cargo", "update"]) | ||
call(["cargo", "run", "--release"]) |