diff --git a/src/ids.rs b/src/ids.rs index aa788e8..81f33aa 100644 --- a/src/ids.rs +++ b/src/ids.rs @@ -18,14 +18,17 @@ pub enum Stats { pub enum Skills { AOE, DoubleDamage, + DoubleAttackSpeed } #[derive(PartialEq, Eq, Hash, Copy, Clone, Debug)] pub enum Items { TestItem, + Coffee } #[derive(PartialEq, Eq, Hash, Copy, Clone, Debug)] pub enum Effectors { DoubleDamage, + DoubleAttackSpeed } diff --git a/src/main.rs b/src/main.rs index d12dbc3..9407792 100644 --- a/src/main.rs +++ b/src/main.rs @@ -308,6 +308,19 @@ fn main() -> BError { Effectors::DoubleDamage, ], ), + SkillDefinition::new( + Skills::DoubleAttackSpeed, + String::from("Double Attack Speed"), + String::from("double_attack_speed"), + String::from("Double the attack speed."), + 0.0, + false, + vec![], + vec![(Items::Coffee, 1,UseMode::Consume)], + vec![ + Effectors::DoubleAttackSpeed, + ], + ), ]); world.insert(skill_definitions); @@ -317,6 +330,11 @@ fn main() -> BError { Some(0.0), vec![(Stats::Attack, EffectorType::MultiplicativeMultiplier(2.0))], ), + EffectorDefinition::new( + Effectors::DoubleAttackSpeed, + Some(5.0), + vec![(Stats::AttackSpeed, EffectorType::MultiplicativeMultiplier(2.0))], + ) ]); world.insert(effector_defs); @@ -330,6 +348,15 @@ fn main() -> BError { None, None, ), + ItemDefinition::new( + Items::Coffee, + (), + String::from("Coffee"), + String::from("coffee"), + String::from("A cup of coffee. Drinking this will double attack speed for 5 seconds."), + None, + None, + ), ]); world.insert(item_defs);