mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Golem now spawns in dungeon.
This commit is contained in:
parent
99aba78422
commit
e39770d1d9
@ -16,6 +16,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||||||
- Fireflies
|
- Fireflies
|
||||||
- Fullscreen modes now show two options (exclusive and borderless)
|
- Fullscreen modes now show two options (exclusive and borderless)
|
||||||
- Added banlist and `/ban`, `/unban`, and `/kick` commands for admins
|
- Added banlist and `/ban`, `/unban`, and `/kick` commands for admins
|
||||||
|
- A new dungeon boss (venture there and discover it yourself)
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
|
||||||
|
@ -357,7 +357,7 @@ impl Tool {
|
|||||||
recover_duration: Duration::from_millis(250),
|
recover_duration: Duration::from_millis(250),
|
||||||
knockback: 25.0,
|
knockback: 25.0,
|
||||||
base_healthchange: -200,
|
base_healthchange: -200,
|
||||||
range: 10.0,
|
range: 5.0,
|
||||||
max_angle: 120.0,
|
max_angle: 120.0,
|
||||||
},
|
},
|
||||||
GroundShockwave {
|
GroundShockwave {
|
||||||
|
@ -1,9 +1,7 @@
|
|||||||
use crate::{
|
use crate::comp::{
|
||||||
comp::{
|
|
||||||
golem,
|
golem,
|
||||||
item::{Item, ItemKind},
|
item::{Item, ItemKind},
|
||||||
Alignment, Body, CharacterAbility, ItemConfig, Loadout,
|
Alignment, Body, CharacterAbility, ItemConfig, Loadout,
|
||||||
},
|
|
||||||
};
|
};
|
||||||
use rand::Rng;
|
use rand::Rng;
|
||||||
use std::time::Duration;
|
use std::time::Duration;
|
||||||
@ -81,8 +79,7 @@ impl LoadoutBuilder {
|
|||||||
_ => {},
|
_ => {},
|
||||||
};
|
};
|
||||||
|
|
||||||
let active_item =
|
let active_item = if let Some(ItemKind::Tool(tool)) = main_tool.as_ref().map(|i| i.kind()) {
|
||||||
if let Some(ItemKind::Tool(tool)) = main_tool.as_ref().map(|i| i.kind()) {
|
|
||||||
let mut abilities = tool.get_abilities();
|
let mut abilities = tool.get_abilities();
|
||||||
let mut ability_drain = abilities.drain(..);
|
let mut ability_drain = abilities.drain(..);
|
||||||
|
|
||||||
|
@ -1,10 +1,7 @@
|
|||||||
use super::SysTimer;
|
use super::SysTimer;
|
||||||
use crate::{chunk_generator::ChunkGenerator, client::Client, Tick};
|
use crate::{chunk_generator::ChunkGenerator, client::Client, Tick};
|
||||||
use common::{
|
use common::{
|
||||||
comp::{
|
comp::{self, bird_medium, Alignment, CharacterAbility, Player, Pos},
|
||||||
self, bird_medium,
|
|
||||||
Alignment, CharacterAbility, Player, Pos,
|
|
||||||
},
|
|
||||||
event::{EventBus, ServerEvent},
|
event::{EventBus, ServerEvent},
|
||||||
generation::get_npc_name,
|
generation::get_npc_name,
|
||||||
msg::ServerMsg,
|
msg::ServerMsg,
|
||||||
|
@ -2115,6 +2115,15 @@ impl FigureMgr {
|
|||||||
skeleton_attr,
|
skeleton_attr,
|
||||||
)
|
)
|
||||||
},
|
},
|
||||||
|
CharacterState::GroundShockwave(_) => {
|
||||||
|
anim::golem::ShockwaveAnimation::update_skeleton(
|
||||||
|
&target_base,
|
||||||
|
(vel.0.magnitude(), time),
|
||||||
|
state.state_time,
|
||||||
|
&mut state_animation_rate,
|
||||||
|
skeleton_attr,
|
||||||
|
)
|
||||||
|
},
|
||||||
// TODO!
|
// TODO!
|
||||||
_ => target_base,
|
_ => target_base,
|
||||||
};
|
};
|
||||||
|
@ -13,7 +13,6 @@ use common::{
|
|||||||
comp::{self},
|
comp::{self},
|
||||||
generation::{ChunkSupplement, EntityInfo},
|
generation::{ChunkSupplement, EntityInfo},
|
||||||
lottery::Lottery,
|
lottery::Lottery,
|
||||||
npc,
|
|
||||||
store::{Id, Store},
|
store::{Id, Store},
|
||||||
terrain::{Block, BlockKind, Structure, TerrainChunkSize},
|
terrain::{Block, BlockKind, Structure, TerrainChunkSize},
|
||||||
vol::{BaseVol, ReadVol, RectSizedVol, RectVolSize, Vox, WriteVol},
|
vol::{BaseVol, ReadVol, RectSizedVol, RectVolSize, Vox, WriteVol},
|
||||||
@ -509,22 +508,13 @@ impl Floor {
|
|||||||
);
|
);
|
||||||
let chosen = chosen.choose();
|
let chosen = chosen.choose();
|
||||||
let entity = EntityInfo::at(tile_wcenter.map(|e| e as f32))
|
let entity = EntityInfo::at(tile_wcenter.map(|e| e as f32))
|
||||||
.with_scale(4.0)
|
.with_level(rng.gen_range(1, 5))
|
||||||
.with_level(rng.gen_range(75, 100))
|
|
||||||
.with_alignment(comp::Alignment::Enemy)
|
.with_alignment(comp::Alignment::Enemy)
|
||||||
.with_body(comp::Body::Humanoid(comp::humanoid::Body::random()))
|
.with_body(comp::Body::Golem(comp::golem::Body::random_with(
|
||||||
.with_name(format!(
|
rng,
|
||||||
"Cult Leader {}",
|
&comp::golem::Species::StoneGolem,
|
||||||
npc::get_npc_name(npc::NpcKind::Humanoid)
|
)))
|
||||||
))
|
.with_name("Stonework Defender".to_string())
|
||||||
.with_main_tool(comp::Item::new_from_asset_expect(
|
|
||||||
match rng.gen_range(0, 1) {
|
|
||||||
//Add more possible cult leader npc_weapons here
|
|
||||||
_ => {
|
|
||||||
"common.items.npc_weapons.sword.cultist_purp_2h_boss-0"
|
|
||||||
},
|
|
||||||
},
|
|
||||||
))
|
|
||||||
.with_loot_drop(comp::Item::new_from_asset_expect(chosen));
|
.with_loot_drop(comp::Item::new_from_asset_expect(chosen));
|
||||||
|
|
||||||
supplement.add_entity(entity);
|
supplement.add_entity(entity);
|
||||||
|
Loading…
Reference in New Issue
Block a user