Struct rust_sc2::client::RunnerSingle [−][src]
pub struct RunnerSingle<'a, B> where
B: Player + DerefMut<Target = Bot> + Deref<Target = Bot>, { pub computer: Computer, pub realtime: bool, pub save_replay_as: Option<&'a str>, // some fields omitted }
Runner for games vs built-in AI.
Fields
computer: ComputerComputer opponent configuration.
realtime: boolPlay games in real time mode or not.
save_replay_as: Option<&'a str>Save replay after the game in given path.
Implementations
impl<'a, B> RunnerSingle<'a, B> where
B: Player + DerefMut<Target = Bot> + Deref<Target = Bot>, [src]
impl<'a, B> RunnerSingle<'a, B> where
B: Player + DerefMut<Target = Bot> + Deref<Target = Bot>, [src]pub fn new(
bot: &'a mut B,
computer: Computer,
map: &str,
sc2_version: Option<&'a str>
) -> Self[src]
bot: &'a mut B,
computer: Computer,
map: &str,
sc2_version: Option<&'a str>
) -> Self
Constructs new single player runner.
pub fn launch(&mut self) -> SC2Result<()>[src]
Launches SC2 client and connects bot to the API.
pub fn run_game(&mut self) -> SC2Result<()>[src]
Runs requested game.
pub fn set_map(&mut self, map: &str)[src]
pub fn close(&mut self)[src]
Manually closes SC2 client.
Auto Trait Implementations
impl<'a, B> RefUnwindSafe for RunnerSingle<'a, B> where
B: RefUnwindSafe,
impl<'a, B> RefUnwindSafe for RunnerSingle<'a, B> where
B: RefUnwindSafe, impl<'a, B> Send for RunnerSingle<'a, B> where
B: Send,
impl<'a, B> Send for RunnerSingle<'a, B> where
B: Send, impl<'a, B> Sync for RunnerSingle<'a, B> where
B: Sync,
impl<'a, B> Sync for RunnerSingle<'a, B> where
B: Sync, impl<'a, B> Unpin for RunnerSingle<'a, B>
impl<'a, B> Unpin for RunnerSingle<'a, B>impl<'a, B> !UnwindSafe for RunnerSingle<'a, B>
impl<'a, B> !UnwindSafe for RunnerSingle<'a, B>