sanguis::server::entities::doodad::doodad( sanguis::server::environment::load_context &_load_context, sanguis::doodad_type const _doodad_type ) : sanguis::server::entities::with_body( _load_context.model_size( sanguis::load::model::doodad_path( _doodad_type ) ), sanguis::server::optional_mass() ), sanguis::server::entities::with_id( _load_context.next_id() ), sanguis::server::entities::with_links(), doodad_type_{ _doodad_type }, dead_{ false } { }
sanguis::server::entities::friend_::friend_( sanguis::friend_type const _friend_type, sanguis::server::environment::load_context &_load_context, sanguis::server::damage::armor_array const &_armor, sanguis::server::health const _health, sanguis::server::entities::movement_speed const _movement_speed, sanguis::server::ai::create_function const &_ai, sanguis::server::weapons::unique_ptr &&_weapon ) : sanguis::server::entities::ifaces::with_team(), sanguis::server::entities::with_ai( _ai, std::move( _weapon ), sanguis::server::auras::container(), sanguis::server::weapons::default_ias(), sanguis::server::weapons::default_irs() ), sanguis::server::entities::with_buffs(), sanguis::server::entities::with_id( _load_context.next_id() ), sanguis::server::entities::with_health( _health, sanguis::server::regeneration( 0.f ), _armor ), sanguis::server::entities::with_links(), sanguis::server::entities::with_velocity( _load_context.model_size( sanguis::load::model::friend_path( _friend_type ) ), // TODO sanguis::server::optional_mass(), sanguis::server::entities::movement_speed_initial( sanguis::server::entities::property::initial_zero( _movement_speed.get() ) ), sanguis::server::direction( 0.f ) ), friend_type_( _friend_type ) { }
sanguis::server::world::insert_with_id_pair_container sanguis::server::world::generate_single_spawns( sanguis::creator::enemy_type const _enemy_type, sanguis::creator::enemy_kind const _enemy_kind, sanguis::creator::spawn_pos const _pos, sanguis::server::weapons::common_parameters const &_weapons_parameters, sanguis::random_generator &_random_generator, sanguis::server::environment::load_context &_load_context, sanguis::server::world::difficulty const _difficulty ) { return sanguis::server::world::place_multiple( _random_generator, sanguis::server::world::place_with_id_callback( [ &_random_generator, &_weapons_parameters, _enemy_type, _enemy_kind, _difficulty, &_load_context] { return sanguis::server::entities::enemies::create( _random_generator, _weapons_parameters, _enemy_type, _enemy_kind, _difficulty, _load_context, sanguis::server::entities::spawn_owner( sanguis::server::entities::auto_weak_link() ), sanguis::server::entities::enemies::special_chance( 0.05f ) ); } ), _pos.get(), _load_context.model_size( sanguis::load::model::enemy_path( _enemy_type ) ) ); }