veloren/common/sys/src/lib.rs

39 lines
1.2 KiB
Rust
Raw Normal View History

2021-03-18 13:01:03 +00:00
#![feature(label_break_value, bool_to_option, option_unwrap_none, array_map)]
2021-03-16 07:56:43 +00:00
#![allow(clippy::option_map_unit_fn)]
2020-12-04 22:24:56 +00:00
mod aura;
mod beam;
mod buff;
2020-03-07 19:02:54 +00:00
pub mod character_behavior;
2019-06-09 14:20:20 +00:00
pub mod controller;
mod interpolation;
pub mod melee;
2019-11-04 00:57:36 +00:00
mod mount;
pub mod phys;
#[cfg(feature = "plugins")] pub mod plugin;
2021-04-04 03:04:02 +00:00
pub mod projectile;
mod shockwave;
2020-12-01 12:13:07 +00:00
pub mod state;
mod stats;
// External
use common_ecs::{dispatch, System};
use specs::DispatcherBuilder;
pub fn add_local_systems(dispatch_builder: &mut DispatcherBuilder) {
dispatch::<mount::Sys>(dispatch_builder, &[]);
dispatch::<controller::Sys>(dispatch_builder, &[&mount::Sys::sys_name()]);
dispatch::<character_behavior::Sys>(dispatch_builder, &[&controller::Sys::sys_name()]);
dispatch::<stats::Sys>(dispatch_builder, &[]);
dispatch::<buff::Sys>(dispatch_builder, &[]);
dispatch::<phys::Sys>(dispatch_builder, &[
&controller::Sys::sys_name(),
&mount::Sys::sys_name(),
&stats::Sys::sys_name(),
2020-03-07 19:02:54 +00:00
]);
dispatch::<projectile::Sys>(dispatch_builder, &[&phys::Sys::sys_name()]);
dispatch::<shockwave::Sys>(dispatch_builder, &[&phys::Sys::sys_name()]);
dispatch::<beam::Sys>(dispatch_builder, &[&phys::Sys::sys_name()]);
dispatch::<aura::Sys>(dispatch_builder, &[]);
}