mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
point to github specs to access PairedStorage type, fix Loadout sync spam
This commit is contained in:
63
Cargo.lock
generated
63
Cargo.lock
generated
@ -995,17 +995,6 @@ dependencies = [
|
|||||||
"byteorder 1.3.4",
|
"byteorder 1.3.4",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "derivative"
|
|
||||||
version = "1.0.4"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "3c6d883546668a3e2011b6a716a7330b82eabb0151b138217f632c8243e17135"
|
|
||||||
dependencies = [
|
|
||||||
"proc-macro2 0.4.30",
|
|
||||||
"quote 0.6.13",
|
|
||||||
"syn 0.15.44",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "deunicode"
|
name = "deunicode"
|
||||||
version = "1.1.1"
|
version = "1.1.1"
|
||||||
@ -1856,6 +1845,16 @@ dependencies = [
|
|||||||
"serde",
|
"serde",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "hashbrown"
|
||||||
|
version = "0.7.2"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "96282e96bfcd3da0d3aa9938bedf1e50df3269b6db08b4876d2da0bb1a0841cf"
|
||||||
|
dependencies = [
|
||||||
|
"ahash 0.3.8",
|
||||||
|
"autocfg 1.0.0",
|
||||||
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "hermit-abi"
|
name = "hermit-abi"
|
||||||
version = "0.1.13"
|
version = "0.1.13"
|
||||||
@ -3698,16 +3697,17 @@ checksum = "7fdf1b9db47230893d76faad238fd6097fd6d6a9245cd7a4d90dbd639536bbd2"
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "shred"
|
name = "shred"
|
||||||
version = "0.9.4"
|
version = "0.10.2"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "92472b9bafafbcba21935c6444d924e5332742f6778c49504a49a97eaeff6ccc"
|
checksum = "c5f08237e667ac94ad20f8878b5943d91a93ccb231428446c57c21c57779016d"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"arrayvec 0.4.12",
|
"arrayvec 0.5.1",
|
||||||
"hashbrown",
|
"hashbrown 0.7.2",
|
||||||
"mopa",
|
"mopa",
|
||||||
"rayon",
|
"rayon",
|
||||||
"shred-derive",
|
"shred-derive",
|
||||||
"smallvec 0.6.13",
|
"smallvec 1.4.0",
|
||||||
|
"tynm",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
@ -3793,13 +3793,11 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "specs"
|
name = "specs"
|
||||||
version = "0.15.1"
|
version = "0.16.1"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "git+https://github.com/amethyst/specs.git?rev=7a2e348ab2223818bad487695c66c43db88050a5#7a2e348ab2223818bad487695c66c43db88050a5"
|
||||||
checksum = "4943fde8c5d3d14c3d19d2a4c7abbd7b626c270a19e6cd35252294a48feb698c"
|
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"crossbeam-queue 0.1.2",
|
"crossbeam-queue 0.2.3",
|
||||||
"derivative",
|
"hashbrown 0.7.2",
|
||||||
"hashbrown",
|
|
||||||
"hibitset",
|
"hibitset",
|
||||||
"log",
|
"log",
|
||||||
"rayon",
|
"rayon",
|
||||||
@ -3812,7 +3810,7 @@ dependencies = [
|
|||||||
[[package]]
|
[[package]]
|
||||||
name = "specs-idvs"
|
name = "specs-idvs"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
source = "git+https://gitlab.com/veloren/specs-idvs.git#111548cf44e9bb4c43feb12aa3fc253953ac6e4a"
|
source = "git+https://gitlab.com/veloren/specs-idvs.git?branch=specs-16#349153d18c19d238523e4eddd5bec179d38c59c5"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"specs",
|
"specs",
|
||||||
]
|
]
|
||||||
@ -4300,6 +4298,15 @@ version = "0.3.0"
|
|||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "44834418e2c5b16f47bedf35c28e148db099187dd5feee6367fb2525863af4f1"
|
checksum = "44834418e2c5b16f47bedf35c28e148db099187dd5feee6367fb2525863af4f1"
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "tynm"
|
||||||
|
version = "0.1.4"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "367fb781963961b4a90a3362c54b1871caaecb081f011005778242230f39d34e"
|
||||||
|
dependencies = [
|
||||||
|
"nom 5.1.1",
|
||||||
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "unicode-bidi"
|
name = "unicode-bidi"
|
||||||
version = "0.3.4"
|
version = "0.3.4"
|
||||||
@ -4457,7 +4464,7 @@ dependencies = [
|
|||||||
"futures-executor",
|
"futures-executor",
|
||||||
"futures-timer 3.0.2",
|
"futures-timer 3.0.2",
|
||||||
"futures-util",
|
"futures-util",
|
||||||
"hashbrown",
|
"hashbrown 0.6.3",
|
||||||
"image",
|
"image",
|
||||||
"num_cpus",
|
"num_cpus",
|
||||||
"specs",
|
"specs",
|
||||||
@ -4478,7 +4485,7 @@ dependencies = [
|
|||||||
"crossbeam",
|
"crossbeam",
|
||||||
"dot_vox",
|
"dot_vox",
|
||||||
"find_folder",
|
"find_folder",
|
||||||
"hashbrown",
|
"hashbrown 0.6.3",
|
||||||
"image",
|
"image",
|
||||||
"indexmap",
|
"indexmap",
|
||||||
"lazy_static",
|
"lazy_static",
|
||||||
@ -4512,7 +4519,7 @@ dependencies = [
|
|||||||
"futures-executor",
|
"futures-executor",
|
||||||
"futures-timer 3.0.2",
|
"futures-timer 3.0.2",
|
||||||
"futures-util",
|
"futures-util",
|
||||||
"hashbrown",
|
"hashbrown 0.6.3",
|
||||||
"lazy_static",
|
"lazy_static",
|
||||||
"libsqlite3-sys",
|
"libsqlite3-sys",
|
||||||
"portpicker",
|
"portpicker",
|
||||||
@ -4573,7 +4580,7 @@ dependencies = [
|
|||||||
"glsl-include",
|
"glsl-include",
|
||||||
"glutin",
|
"glutin",
|
||||||
"guillotiere",
|
"guillotiere",
|
||||||
"hashbrown",
|
"hashbrown 0.6.3",
|
||||||
"image",
|
"image",
|
||||||
"msgbox",
|
"msgbox",
|
||||||
"num 0.2.1",
|
"num 0.2.1",
|
||||||
@ -4621,7 +4628,7 @@ dependencies = [
|
|||||||
"bincode",
|
"bincode",
|
||||||
"bitvec",
|
"bitvec",
|
||||||
"fxhash",
|
"fxhash",
|
||||||
"hashbrown",
|
"hashbrown 0.6.3",
|
||||||
"image",
|
"image",
|
||||||
"itertools 0.8.2",
|
"itertools 0.8.2",
|
||||||
"lazy_static",
|
"lazy_static",
|
||||||
|
@ -72,3 +72,7 @@ debug = false
|
|||||||
[profile.releasedebuginfo]
|
[profile.releasedebuginfo]
|
||||||
inherits = 'release'
|
inherits = 'release'
|
||||||
debug = 1
|
debug = 1
|
||||||
|
|
||||||
|
# living on the edge
|
||||||
|
[patch.crates-io]
|
||||||
|
specs = { git = "https://github.com/amethyst/specs.git", rev = "7a2e348ab2223818bad487695c66c43db88050a5" }
|
||||||
|
@ -16,7 +16,7 @@ futures-timer = "3.0"
|
|||||||
image = { version = "0.22.3", default-features = false, features = ["png"] }
|
image = { version = "0.22.3", default-features = false, features = ["png"] }
|
||||||
num_cpus = "1.10.1"
|
num_cpus = "1.10.1"
|
||||||
tracing = { version = "0.1", default-features = false }
|
tracing = { version = "0.1", default-features = false }
|
||||||
specs = "0.15.1"
|
specs = "0.16.1"
|
||||||
vek = { version = "0.11.0", features = ["serde"] }
|
vek = { version = "0.11.0", features = ["serde"] }
|
||||||
hashbrown = { version = "0.6", features = ["rayon", "serde", "nightly"] }
|
hashbrown = { version = "0.6", features = ["rayon", "serde", "nightly"] }
|
||||||
authc = { git = "https://gitlab.com/veloren/auth.git", rev = "223a4097f7ebc8d451936dccb5e6517194bbf086" }
|
authc = { git = "https://gitlab.com/veloren/auth.git", rev = "223a4097f7ebc8d451936dccb5e6517194bbf086" }
|
||||||
|
@ -8,9 +8,9 @@ edition = "2018"
|
|||||||
no-assets = []
|
no-assets = []
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
specs-idvs = { git = "https://gitlab.com/veloren/specs-idvs.git" }
|
specs-idvs = { git = "https://gitlab.com/veloren/specs-idvs.git", branch = "specs-16" }
|
||||||
|
|
||||||
specs = { version = "0.15.1", features = ["serde", "nightly", "storage-event-control"] }
|
specs = { version = "0.16.1", features = ["serde", "storage-event-control"] }
|
||||||
vek = { version = "0.11.0", features = ["serde"] }
|
vek = { version = "0.11.0", features = ["serde"] }
|
||||||
dot_vox = "4.0"
|
dot_vox = "4.0"
|
||||||
image = { version = "0.22.3", default-features = false, features = ["png"] }
|
image = { version = "0.22.3", default-features = false, features = ["png"] }
|
||||||
|
@ -7,7 +7,7 @@ use crate::{
|
|||||||
sys::character_behavior::JoinData,
|
sys::character_behavior::JoinData,
|
||||||
};
|
};
|
||||||
use specs::{Component, FlaggedStorage};
|
use specs::{Component, FlaggedStorage};
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
use std::time::Duration;
|
use std::time::Duration;
|
||||||
|
|
||||||
#[derive(Copy, Clone, Hash, Eq, PartialEq, Debug, Serialize, Deserialize)]
|
#[derive(Copy, Clone, Hash, Eq, PartialEq, Debug, Serialize, Deserialize)]
|
||||||
@ -243,5 +243,5 @@ impl From<&CharacterAbility> for CharacterState {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Loadout {
|
impl Component for Loadout {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
use crate::path::Chaser;
|
use crate::path::Chaser;
|
||||||
use specs::{Component, Entity as EcsEntity};
|
use specs::{Component, Entity as EcsEntity};
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
use vek::*;
|
use vek::*;
|
||||||
|
|
||||||
#[derive(Copy, Clone, Debug, PartialEq)]
|
#[derive(Copy, Clone, Debug, PartialEq)]
|
||||||
@ -43,7 +43,7 @@ impl Alignment {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Alignment {
|
impl Component for Alignment {
|
||||||
type Storage = IDVStorage<Self>;
|
type Storage = IdvStorage<Self>;
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Clone, Debug, Default)]
|
#[derive(Clone, Debug, Default)]
|
||||||
@ -72,7 +72,7 @@ impl Agent {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Agent {
|
impl Component for Agent {
|
||||||
type Storage = IDVStorage<Self>;
|
type Storage = IdvStorage<Self>;
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Clone, Debug)]
|
#[derive(Clone, Debug)]
|
||||||
|
@ -17,7 +17,7 @@ use crate::{
|
|||||||
npc::NpcKind,
|
npc::NpcKind,
|
||||||
};
|
};
|
||||||
use specs::{Component, FlaggedStorage};
|
use specs::{Component, FlaggedStorage};
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
use std::{fs::File, io::BufReader};
|
use std::{fs::File, io::BufReader};
|
||||||
|
|
||||||
#[derive(Copy, Clone, Debug, PartialEq, Eq, Hash, Serialize, Deserialize)]
|
#[derive(Copy, Clone, Debug, PartialEq, Eq, Hash, Serialize, Deserialize)]
|
||||||
@ -132,5 +132,5 @@ impl Body {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Body {
|
impl Component for Body {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
@ -1,11 +1,12 @@
|
|||||||
use crate::{
|
use crate::{
|
||||||
comp::{Energy, Loadout, Ori, Pos, Vel},
|
comp::{Energy, Ori, Pos, Vel},
|
||||||
event::{LocalEvent, ServerEvent},
|
event::{LocalEvent, ServerEvent},
|
||||||
states::*,
|
states::*,
|
||||||
sys::character_behavior::JoinData,
|
sys::character_behavior::JoinData,
|
||||||
};
|
};
|
||||||
use serde::{Deserialize, Serialize};
|
use serde::{Deserialize, Serialize};
|
||||||
use specs::{Component, FlaggedStorage, HashMapStorage, VecStorage};
|
use specs::{Component, FlaggedStorage, VecStorage};
|
||||||
|
use specs_idvs::IdvStorage;
|
||||||
use std::collections::VecDeque;
|
use std::collections::VecDeque;
|
||||||
|
|
||||||
/// Data returned from character behavior fn's to Character Behavior System.
|
/// Data returned from character behavior fn's to Character Behavior System.
|
||||||
@ -15,7 +16,7 @@ pub struct StateUpdate {
|
|||||||
pub vel: Vel,
|
pub vel: Vel,
|
||||||
pub ori: Ori,
|
pub ori: Ori,
|
||||||
pub energy: Energy,
|
pub energy: Energy,
|
||||||
pub loadout: Loadout,
|
pub swap_loadout: bool,
|
||||||
pub local_events: VecDeque<LocalEvent>,
|
pub local_events: VecDeque<LocalEvent>,
|
||||||
pub server_events: VecDeque<ServerEvent>,
|
pub server_events: VecDeque<ServerEvent>,
|
||||||
}
|
}
|
||||||
@ -27,7 +28,7 @@ impl From<&JoinData<'_>> for StateUpdate {
|
|||||||
vel: *data.vel,
|
vel: *data.vel,
|
||||||
ori: *data.ori,
|
ori: *data.ori,
|
||||||
energy: *data.energy,
|
energy: *data.energy,
|
||||||
loadout: data.loadout.clone(),
|
swap_loadout: false,
|
||||||
character: data.character.clone(),
|
character: data.character.clone(),
|
||||||
local_events: VecDeque::new(),
|
local_events: VecDeque::new(),
|
||||||
server_events: VecDeque::new(),
|
server_events: VecDeque::new(),
|
||||||
@ -128,7 +129,7 @@ impl Default for CharacterState {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for CharacterState {
|
impl Component for CharacterState {
|
||||||
type Storage = FlaggedStorage<Self, HashMapStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Copy, Clone, Debug, PartialEq, Serialize, Deserialize)]
|
#[derive(Copy, Clone, Debug, PartialEq, Serialize, Deserialize)]
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
use crate::{msg::ServerMsg, sync::Uid};
|
use crate::{msg::ServerMsg, sync::Uid};
|
||||||
use specs::Component;
|
use specs::Component;
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
use std::time::{Duration, Instant};
|
use std::time::{Duration, Instant};
|
||||||
|
|
||||||
/// A player's current chat mode. These are chat types that can only be sent by
|
/// A player's current chat mode. These are chat types that can only be sent by
|
||||||
@ -22,7 +22,7 @@ pub enum ChatMode {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for ChatMode {
|
impl Component for ChatMode {
|
||||||
type Storage = IDVStorage<Self>;
|
type Storage = IdvStorage<Self>;
|
||||||
}
|
}
|
||||||
|
|
||||||
impl ChatMode {
|
impl ChatMode {
|
||||||
@ -180,7 +180,7 @@ impl ChatMsg {
|
|||||||
#[derive(Clone, Debug)]
|
#[derive(Clone, Debug)]
|
||||||
pub struct Group(pub String);
|
pub struct Group(pub String);
|
||||||
impl Component for Group {
|
impl Component for Group {
|
||||||
type Storage = IDVStorage<Self>;
|
type Storage = IdvStorage<Self>;
|
||||||
}
|
}
|
||||||
impl From<String> for Group {
|
impl From<String> for Group {
|
||||||
fn from(s: String) -> Self { Group(s) }
|
fn from(s: String) -> Self { Group(s) }
|
||||||
@ -193,7 +193,7 @@ impl From<String> for Group {
|
|||||||
#[derive(Clone, Debug)]
|
#[derive(Clone, Debug)]
|
||||||
pub struct Faction(pub String);
|
pub struct Faction(pub String);
|
||||||
impl Component for Faction {
|
impl Component for Faction {
|
||||||
type Storage = IDVStorage<Self>;
|
type Storage = IdvStorage<Self>;
|
||||||
}
|
}
|
||||||
impl From<String> for Faction {
|
impl From<String> for Faction {
|
||||||
fn from(s: String) -> Self { Faction(s) }
|
fn from(s: String) -> Self { Faction(s) }
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
use crate::{comp::inventory::slot::Slot, sync::Uid, util::Dir};
|
use crate::{comp::inventory::slot::Slot, sync::Uid, util::Dir};
|
||||||
use specs::{Component, FlaggedStorage};
|
use specs::{Component, FlaggedStorage};
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
use std::time::Duration;
|
use std::time::Duration;
|
||||||
use vek::*;
|
use vek::*;
|
||||||
|
|
||||||
@ -227,7 +227,7 @@ impl Controller {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Controller {
|
impl Component for Controller {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
|
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
|
||||||
@ -237,12 +237,12 @@ pub enum MountState {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for MountState {
|
impl Component for MountState {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
|
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
|
||||||
pub struct Mounting(pub Uid);
|
pub struct Mounting(pub Uid);
|
||||||
|
|
||||||
impl Component for Mounting {
|
impl Component for Mounting {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
use specs::{Component, FlaggedStorage};
|
use specs::{Component, FlaggedStorage};
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
|
|
||||||
#[derive(Clone, Copy, Debug, Serialize, Deserialize)]
|
#[derive(Clone, Copy, Debug, PartialEq, Serialize, Deserialize)]
|
||||||
pub struct Energy {
|
pub struct Energy {
|
||||||
current: u32,
|
current: u32,
|
||||||
maximum: u32,
|
maximum: u32,
|
||||||
@ -9,7 +9,7 @@ pub struct Energy {
|
|||||||
pub last_change: Option<(i32, f64, EnergySource)>,
|
pub last_change: Option<(i32, f64, EnergySource)>,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Clone, Copy, Debug, Serialize, Deserialize)]
|
#[derive(Clone, Copy, Debug, PartialEq, Serialize, Deserialize)]
|
||||||
pub enum EnergySource {
|
pub enum EnergySource {
|
||||||
Ability,
|
Ability,
|
||||||
Climb,
|
Climb,
|
||||||
@ -73,5 +73,5 @@ impl Energy {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Energy {
|
impl Component for Energy {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
@ -11,7 +11,7 @@ use crate::{
|
|||||||
terrain::{Block, BlockKind},
|
terrain::{Block, BlockKind},
|
||||||
};
|
};
|
||||||
use specs::{Component, FlaggedStorage};
|
use specs::{Component, FlaggedStorage};
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
use std::{fs::File, io::BufReader};
|
use std::{fs::File, io::BufReader};
|
||||||
use vek::Rgb;
|
use vek::Rgb;
|
||||||
|
|
||||||
@ -197,12 +197,12 @@ impl Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Item {
|
impl Component for Item {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Clone, Debug, PartialEq, Eq, Hash, Serialize, Deserialize)]
|
#[derive(Clone, Debug, PartialEq, Eq, Hash, Serialize, Deserialize)]
|
||||||
pub struct ItemDrop(pub Item);
|
pub struct ItemDrop(pub Item);
|
||||||
|
|
||||||
impl Component for ItemDrop {
|
impl Component for ItemDrop {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
@ -4,7 +4,7 @@ pub mod slot;
|
|||||||
use crate::assets;
|
use crate::assets;
|
||||||
use item::{Consumable, Item, ItemKind};
|
use item::{Consumable, Item, ItemKind};
|
||||||
use specs::{Component, FlaggedStorage, HashMapStorage};
|
use specs::{Component, FlaggedStorage, HashMapStorage};
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
use std::ops::Not;
|
use std::ops::Not;
|
||||||
|
|
||||||
// The limit on distance between the entity and a collectible (squared)
|
// The limit on distance between the entity and a collectible (squared)
|
||||||
@ -388,7 +388,7 @@ impl InventoryUpdate {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for InventoryUpdate {
|
impl Component for InventoryUpdate {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)] mod test;
|
#[cfg(test)] mod test;
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
use crate::state::Time;
|
use crate::state::Time;
|
||||||
use specs::{Component, FlaggedStorage};
|
use specs::{Component, FlaggedStorage};
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
use vek::*;
|
use vek::*;
|
||||||
|
|
||||||
#[derive(Copy, Clone, Debug, Serialize, Deserialize)]
|
#[derive(Copy, Clone, Debug, Serialize, Deserialize)]
|
||||||
@ -19,7 +19,7 @@ impl Waypoint {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Waypoint {
|
impl Component for Waypoint {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Copy, Clone, Debug, PartialEq)]
|
#[derive(Copy, Clone, Debug, PartialEq)]
|
||||||
@ -30,7 +30,7 @@ impl WaypointArea {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for WaypointArea {
|
impl Component for WaypointArea {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Default for WaypointArea {
|
impl Default for WaypointArea {
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
use crate::sync::Uid;
|
use crate::sync::Uid;
|
||||||
use specs::Component;
|
use specs::Component;
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
|
|
||||||
#[derive(Copy, Clone, Debug, PartialEq, Serialize, Deserialize)]
|
#[derive(Copy, Clone, Debug, PartialEq, Serialize, Deserialize)]
|
||||||
pub enum Object {
|
pub enum Object {
|
||||||
@ -8,5 +8,5 @@ pub enum Object {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Object {
|
impl Component for Object {
|
||||||
type Storage = IDVStorage<Self>;
|
type Storage = IdvStorage<Self>;
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
use crate::{sync::Uid, util::Dir};
|
use crate::{sync::Uid, util::Dir};
|
||||||
use specs::{Component, FlaggedStorage, NullStorage};
|
use specs::{Component, FlaggedStorage, NullStorage};
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
use vek::*;
|
use vek::*;
|
||||||
|
|
||||||
// Position
|
// Position
|
||||||
@ -8,7 +8,7 @@ use vek::*;
|
|||||||
pub struct Pos(pub Vec3<f32>);
|
pub struct Pos(pub Vec3<f32>);
|
||||||
|
|
||||||
impl Component for Pos {
|
impl Component for Pos {
|
||||||
type Storage = IDVStorage<Self>;
|
type Storage = IdvStorage<Self>;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Velocity
|
// Velocity
|
||||||
@ -16,7 +16,7 @@ impl Component for Pos {
|
|||||||
pub struct Vel(pub Vec3<f32>);
|
pub struct Vel(pub Vec3<f32>);
|
||||||
|
|
||||||
impl Component for Vel {
|
impl Component for Vel {
|
||||||
type Storage = IDVStorage<Self>;
|
type Storage = IdvStorage<Self>;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Orientation
|
// Orientation
|
||||||
@ -24,7 +24,7 @@ impl Component for Vel {
|
|||||||
pub struct Ori(pub Dir);
|
pub struct Ori(pub Dir);
|
||||||
|
|
||||||
impl Component for Ori {
|
impl Component for Ori {
|
||||||
type Storage = IDVStorage<Self>;
|
type Storage = IdvStorage<Self>;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Scale
|
// Scale
|
||||||
@ -32,7 +32,7 @@ impl Component for Ori {
|
|||||||
pub struct Scale(pub f32);
|
pub struct Scale(pub f32);
|
||||||
|
|
||||||
impl Component for Scale {
|
impl Component for Scale {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Mass
|
// Mass
|
||||||
@ -40,7 +40,7 @@ impl Component for Scale {
|
|||||||
pub struct Mass(pub f32);
|
pub struct Mass(pub f32);
|
||||||
|
|
||||||
impl Component for Mass {
|
impl Component for Mass {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Mass
|
// Mass
|
||||||
@ -51,14 +51,14 @@ pub enum Collider {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Collider {
|
impl Component for Collider {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Copy, Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
|
#[derive(Copy, Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
|
||||||
pub struct Gravity(pub f32);
|
pub struct Gravity(pub f32);
|
||||||
|
|
||||||
impl Component for Gravity {
|
impl Component for Gravity {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Copy, Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
|
#[derive(Copy, Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
|
||||||
@ -88,7 +88,7 @@ impl PhysicsState {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for PhysicsState {
|
impl Component for PhysicsState {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
// ForceUpdate
|
// ForceUpdate
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
use authc::Uuid;
|
use authc::Uuid;
|
||||||
use specs::{Component, FlaggedStorage, NullStorage};
|
use specs::{Component, FlaggedStorage, NullStorage};
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
|
|
||||||
const MAX_ALIAS_LEN: usize = 32;
|
const MAX_ALIAS_LEN: usize = 32;
|
||||||
|
|
||||||
@ -38,7 +38,7 @@ impl Player {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Player {
|
impl Component for Player {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Clone, Debug, Default, Serialize, Deserialize)]
|
#[derive(Clone, Debug, Default, Serialize, Deserialize)]
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
use crate::{comp, sync::Uid};
|
use crate::{comp, sync::Uid};
|
||||||
use specs::{Component, FlaggedStorage};
|
use specs::{Component, FlaggedStorage};
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
use std::time::Duration;
|
use std::time::Duration;
|
||||||
|
|
||||||
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
|
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
|
||||||
@ -40,5 +40,5 @@ impl Projectile {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Projectile {
|
impl Component for Projectile {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
@ -4,7 +4,7 @@ use crate::{
|
|||||||
sync::Uid,
|
sync::Uid,
|
||||||
};
|
};
|
||||||
use specs::{Component, FlaggedStorage};
|
use specs::{Component, FlaggedStorage};
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
use std::{error::Error, fmt};
|
use std::{error::Error, fmt};
|
||||||
|
|
||||||
#[derive(Clone, Copy, Debug, Hash, PartialEq, Eq, Serialize, Deserialize)]
|
#[derive(Clone, Copy, Debug, Hash, PartialEq, Eq, Serialize, Deserialize)]
|
||||||
@ -204,7 +204,7 @@ impl Stats {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Stats {
|
impl Component for Stats {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Copy, Clone, Debug, Serialize, Deserialize)]
|
#[derive(Copy, Clone, Debug, Serialize, Deserialize)]
|
||||||
@ -213,5 +213,5 @@ pub struct Dying {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Dying {
|
impl Component for Dying {
|
||||||
type Storage = IDVStorage<Self>;
|
type Storage = IdvStorage<Self>;
|
||||||
}
|
}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
use specs::{Component, FlaggedStorage};
|
use specs::{Component, FlaggedStorage};
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
use vek::*;
|
use vek::*;
|
||||||
|
|
||||||
#[derive(Copy, Clone, Debug, PartialEq, Serialize, Deserialize)]
|
#[derive(Copy, Clone, Debug, PartialEq, Serialize, Deserialize)]
|
||||||
@ -22,7 +22,7 @@ impl Default for LightEmitter {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for LightEmitter {
|
impl Component for LightEmitter {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Copy, Clone, Debug, PartialEq, Serialize, Deserialize)]
|
#[derive(Copy, Clone, Debug, PartialEq, Serialize, Deserialize)]
|
||||||
@ -43,5 +43,5 @@ impl Default for LightAnimation {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for LightAnimation {
|
impl Component for LightAnimation {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
@ -155,12 +155,9 @@ pub fn handle_climb(data: &JoinData, update: &mut StateUpdate) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Checks that player can Swap Weapons and updates `Loadout` if so
|
/// Checks that player can Swap Weapons and updates `Loadout` if so
|
||||||
pub fn attempt_swap_loadout(_data: &JoinData, update: &mut StateUpdate) {
|
pub fn attempt_swap_loadout(data: &JoinData, update: &mut StateUpdate) {
|
||||||
if update.loadout.second_item.is_some() {
|
if data.loadout.second_item.is_some() {
|
||||||
std::mem::swap(
|
update.swap_loadout = true;
|
||||||
&mut update.loadout.active_item,
|
|
||||||
&mut update.loadout.second_item,
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -9,7 +9,12 @@ use crate::{
|
|||||||
sync::{Uid, UidAllocator},
|
sync::{Uid, UidAllocator},
|
||||||
};
|
};
|
||||||
|
|
||||||
use specs::{Entities, Entity, Join, LazyUpdate, Read, ReadStorage, System, WriteStorage};
|
use specs::{
|
||||||
|
hibitset,
|
||||||
|
storage::{PairedStorage, SequentialRestriction},
|
||||||
|
Entities, Entity, FlaggedStorage, Join, LazyUpdate, Read, ReadStorage, System, WriteStorage,
|
||||||
|
};
|
||||||
|
use specs_idvs::IdvStorage;
|
||||||
|
|
||||||
// use std::collections::VecDeque;
|
// use std::collections::VecDeque;
|
||||||
|
|
||||||
@ -37,7 +42,7 @@ pub trait CharacterBehavior {
|
|||||||
// fn init(data: &JoinData) -> CharacterState;
|
// fn init(data: &JoinData) -> CharacterState;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Read-Only Data sent from Character Behavior System to bahvior fn's
|
/// Read-Only Data sent from Character Behavior System to behavior fn's
|
||||||
pub struct JoinData<'a> {
|
pub struct JoinData<'a> {
|
||||||
pub entity: Entity,
|
pub entity: Entity,
|
||||||
pub uid: &'a Uid,
|
pub uid: &'a Uid,
|
||||||
@ -57,15 +62,23 @@ pub struct JoinData<'a> {
|
|||||||
pub updater: &'a LazyUpdate,
|
pub updater: &'a LazyUpdate,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
type RestrictedMut<'a, C> = PairedStorage<
|
||||||
|
'a,
|
||||||
|
'a,
|
||||||
|
C,
|
||||||
|
&'a mut FlaggedStorage<C, IdvStorage<C>>,
|
||||||
|
&'a hibitset::BitSet,
|
||||||
|
SequentialRestriction,
|
||||||
|
>;
|
||||||
pub type JoinTuple<'a> = (
|
pub type JoinTuple<'a> = (
|
||||||
Entity,
|
Entity,
|
||||||
&'a Uid,
|
&'a Uid,
|
||||||
&'a mut CharacterState,
|
RestrictedMut<'a, CharacterState>,
|
||||||
&'a mut Pos,
|
&'a mut Pos,
|
||||||
&'a mut Vel,
|
&'a mut Vel,
|
||||||
&'a mut Ori,
|
&'a mut Ori,
|
||||||
&'a mut Energy,
|
RestrictedMut<'a, Energy>,
|
||||||
&'a mut Loadout,
|
RestrictedMut<'a, Loadout>,
|
||||||
&'a mut Controller,
|
&'a mut Controller,
|
||||||
&'a Stats,
|
&'a Stats,
|
||||||
&'a Body,
|
&'a Body,
|
||||||
@ -74,12 +87,21 @@ pub type JoinTuple<'a> = (
|
|||||||
);
|
);
|
||||||
|
|
||||||
fn incorporate_update(tuple: &mut JoinTuple, state_update: StateUpdate) {
|
fn incorporate_update(tuple: &mut JoinTuple, state_update: StateUpdate) {
|
||||||
*tuple.2 = state_update.character;
|
// TODO: if checking equality is expensive use optional field in StateUpdate
|
||||||
|
if tuple.2.get_unchecked() != &state_update.character {
|
||||||
|
*tuple.2.get_mut_unchecked() = state_update.character
|
||||||
|
};
|
||||||
*tuple.3 = state_update.pos;
|
*tuple.3 = state_update.pos;
|
||||||
*tuple.4 = state_update.vel;
|
*tuple.4 = state_update.vel;
|
||||||
*tuple.5 = state_update.ori;
|
*tuple.5 = state_update.ori;
|
||||||
*tuple.6 = state_update.energy;
|
// Note: might be changed every tick by timer anyway
|
||||||
*tuple.7 = state_update.loadout;
|
if tuple.6.get_unchecked() != &state_update.energy {
|
||||||
|
*tuple.6.get_mut_unchecked() = state_update.energy
|
||||||
|
};
|
||||||
|
if state_update.swap_loadout {
|
||||||
|
let loadout = tuple.7.get_mut_unchecked();
|
||||||
|
std::mem::swap(&mut loadout.active_item, &mut loadout.second_item);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> JoinData<'a> {
|
impl<'a> JoinData<'a> {
|
||||||
@ -87,12 +109,12 @@ impl<'a> JoinData<'a> {
|
|||||||
Self {
|
Self {
|
||||||
entity: j.0,
|
entity: j.0,
|
||||||
uid: j.1,
|
uid: j.1,
|
||||||
character: j.2,
|
character: j.2.get_unchecked(),
|
||||||
pos: j.3,
|
pos: j.3,
|
||||||
vel: j.4,
|
vel: j.4,
|
||||||
ori: j.5,
|
ori: j.5,
|
||||||
energy: j.6,
|
energy: j.6.get_unchecked(),
|
||||||
loadout: j.7,
|
loadout: j.7.get_unchecked(),
|
||||||
controller: j.8,
|
controller: j.8,
|
||||||
inputs: &j.8.inputs,
|
inputs: &j.8.inputs,
|
||||||
stats: j.9,
|
stats: j.9,
|
||||||
@ -162,24 +184,23 @@ impl<'a> System<'a> for Sys {
|
|||||||
let mut server_emitter = server_bus.emitter();
|
let mut server_emitter = server_bus.emitter();
|
||||||
let mut local_emitter = local_bus.emitter();
|
let mut local_emitter = local_bus.emitter();
|
||||||
|
|
||||||
let mut join_iter = (
|
for mut tuple in (
|
||||||
&entities,
|
&entities,
|
||||||
&uids,
|
&uids,
|
||||||
&mut character_states,
|
&mut character_states.restrict_mut(),
|
||||||
&mut positions,
|
&mut positions,
|
||||||
&mut velocities,
|
&mut velocities,
|
||||||
&mut orientations,
|
&mut orientations,
|
||||||
&mut energies,
|
&mut energies.restrict_mut(),
|
||||||
&mut loadouts,
|
&mut loadouts.restrict_mut(),
|
||||||
&mut controllers,
|
&mut controllers,
|
||||||
&stats,
|
&stats,
|
||||||
&bodies,
|
&bodies,
|
||||||
&physics_states,
|
&physics_states,
|
||||||
attacking_storage.maybe(),
|
attacking_storage.maybe(),
|
||||||
)
|
)
|
||||||
.join();
|
.join()
|
||||||
|
{
|
||||||
while let Some(mut tuple) = join_iter.next() {
|
|
||||||
// Being dead overrides all other states
|
// Being dead overrides all other states
|
||||||
if tuple.9.is_dead {
|
if tuple.9.is_dead {
|
||||||
// Do nothing
|
// Do nothing
|
||||||
@ -188,7 +209,10 @@ impl<'a> System<'a> for Sys {
|
|||||||
// If mounted, character state is controlled by mount
|
// If mounted, character state is controlled by mount
|
||||||
// TODO: Make mounting a state
|
// TODO: Make mounting a state
|
||||||
if let Some(Mounting(_)) = mountings.get(tuple.0) {
|
if let Some(Mounting(_)) = mountings.get(tuple.0) {
|
||||||
*tuple.2 = CharacterState::Sit {};
|
let sit_state = CharacterState::Sit {};
|
||||||
|
if tuple.2.get_unchecked() != &sit_state {
|
||||||
|
*tuple.2.get_mut_unchecked() = sit_state;
|
||||||
|
}
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -13,10 +13,10 @@ common = { package = "veloren-common", path = "../common" }
|
|||||||
world = { package = "veloren-world", path = "../world" }
|
world = { package = "veloren-world", path = "../world" }
|
||||||
network = { package = "veloren_network", path = "../network", default-features = false }
|
network = { package = "veloren_network", path = "../network", default-features = false }
|
||||||
|
|
||||||
specs-idvs = { git = "https://gitlab.com/veloren/specs-idvs.git" }
|
specs-idvs = { git = "https://gitlab.com/veloren/specs-idvs.git", branch = "specs-16" }
|
||||||
|
|
||||||
tracing = "0.1"
|
tracing = "0.1"
|
||||||
specs = { version = "0.15.1", features = ["shred-derive"] }
|
specs = { version = "0.16.1", features = ["shred-derive"] }
|
||||||
vek = "0.11.0"
|
vek = "0.11.0"
|
||||||
uvth = "3.1.1"
|
uvth = "3.1.1"
|
||||||
futures-util = "0.3"
|
futures-util = "0.3"
|
||||||
|
@ -2,7 +2,7 @@ use common::msg::{ClientState, RequestStateError, ServerMsg};
|
|||||||
use hashbrown::HashSet;
|
use hashbrown::HashSet;
|
||||||
use network::Stream;
|
use network::Stream;
|
||||||
use specs::{Component, FlaggedStorage};
|
use specs::{Component, FlaggedStorage};
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
use vek::*;
|
use vek::*;
|
||||||
|
|
||||||
pub struct Client {
|
pub struct Client {
|
||||||
@ -13,7 +13,7 @@ pub struct Client {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for Client {
|
impl Component for Client {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Client {
|
impl Client {
|
||||||
@ -59,5 +59,5 @@ pub struct RegionSubscription {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl Component for RegionSubscription {
|
impl Component for RegionSubscription {
|
||||||
type Storage = FlaggedStorage<Self, IDVStorage<Self>>;
|
type Storage = FlaggedStorage<Self, IdvStorage<Self>>;
|
||||||
}
|
}
|
||||||
|
@ -33,8 +33,8 @@ conrod_winit = { git = "https://gitlab.com/veloren/conrod.git", branch = "pre-wi
|
|||||||
euc = { git = "https://github.com/zesterer/euc.git" }
|
euc = { git = "https://github.com/zesterer/euc.git" }
|
||||||
|
|
||||||
# ECS
|
# ECS
|
||||||
specs = "0.15.1"
|
specs = "0.16.1"
|
||||||
specs-idvs = { git = "https://gitlab.com/veloren/specs-idvs.git" }
|
specs-idvs = { git = "https://gitlab.com/veloren/specs-idvs.git", branch = "specs-16" }
|
||||||
|
|
||||||
# Mathematics
|
# Mathematics
|
||||||
vek = { version = "0.11.0", features = ["serde"] }
|
vek = { version = "0.11.0", features = ["serde"] }
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
use common::util::Dir;
|
use common::util::Dir;
|
||||||
use specs::Component;
|
use specs::Component;
|
||||||
use specs_idvs::IDVStorage;
|
use specs_idvs::IdvStorage;
|
||||||
use vek::*;
|
use vek::*;
|
||||||
|
|
||||||
// Floats over entity that has had a health change, rising up over time until it
|
// Floats over entity that has had a health change, rising up over time until it
|
||||||
@ -25,7 +25,7 @@ pub struct HpFloaterList {
|
|||||||
pub time_since_last_dmg_by_me: Option<f32>,
|
pub time_since_last_dmg_by_me: Option<f32>,
|
||||||
}
|
}
|
||||||
impl Component for HpFloaterList {
|
impl Component for HpFloaterList {
|
||||||
type Storage = IDVStorage<Self>;
|
type Storage = IdvStorage<Self>;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Used for smooth interpolation of visual elements that are tied to entity
|
// Used for smooth interpolation of visual elements that are tied to entity
|
||||||
@ -36,5 +36,5 @@ pub struct Interpolated {
|
|||||||
pub ori: Dir,
|
pub ori: Dir,
|
||||||
}
|
}
|
||||||
impl Component for Interpolated {
|
impl Component for Interpolated {
|
||||||
type Storage = IDVStorage<Self>;
|
type Storage = IdvStorage<Self>;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user