Review this, includes: - Unlocks for weapons - All weapons unlock - Max level weapons - Max resonance weapons - Fixed unlocks for roles, now max level, breakthrought and resonance come from bindata - Unlocks for all skin types(flight, wing, role, skin) - Weapon inventory implemented - Change role skin implemented - Change weapon skin implmented - Change flight skin implemented - Change wing skin implemented - Change weapon implemented(basic, no attributes, no switch) - Created SequenceGenerator to emulate sql sequences with reusable ids Known bugs: - In prod only one projection can be equipped simulataneously, we dont care :xdskull: - Change skin will plot with invalid Rotation so a change of character is required, investigate this Reviewed-on: WutheringSlaves/wicked-waifus-rs#9 Reviewed-by: RabbyDevs <rabbydevs@gmail.com>
17 lines
554 B
Rust
17 lines
554 B
Rust
use wicked_waifus_protocol::entity_component_pb::ComponentPb;
|
|
use wicked_waifus_protocol::{EntityComponentPb, WeaponSkinComponentPb};
|
|
use crate::logic::ecs::component::Component;
|
|
|
|
pub struct WeaponSkin {
|
|
pub skin_id: i32,
|
|
}
|
|
|
|
impl Component for WeaponSkin {
|
|
fn set_pb_data(&self, pb: &mut wicked_waifus_protocol::EntityPb) {
|
|
pb.component_pbs.push(EntityComponentPb {
|
|
component_pb: Some(ComponentPb::WeaponSkinComponentPb(WeaponSkinComponentPb {
|
|
weapon_skin_id: self.skin_id,
|
|
})),
|
|
})
|
|
}
|
|
}
|