This commit is contained in:
@@ -153,6 +153,11 @@ impl MoveData {
|
||||
|
||||
/// Arbitrary flags that can be applied to the move.
|
||||
pub fn has_flag(&self, key: &StringKey) -> bool {
|
||||
self.flags.contains(key)
|
||||
self.flags.contains::<StringKey>(key)
|
||||
}
|
||||
|
||||
/// Arbitrary flags that can be applied to the move.
|
||||
pub fn has_flag_by_hash(&self, key_hash: u32) -> bool {
|
||||
self.flags.contains::<u32>(&key_hash)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ use crate::StringKey;
|
||||
/// A parameter for an effect. This is basically a simple way to dynamically store multiple different
|
||||
/// primitives on data.
|
||||
#[derive(PartialEq, Debug)]
|
||||
#[cfg_attr(feature = "wasm", derive(unique_type_id_derive::UniqueTypeId))]
|
||||
pub enum EffectParameter {
|
||||
/// A boolean value.
|
||||
Bool(bool),
|
||||
@@ -11,7 +12,7 @@ pub enum EffectParameter {
|
||||
/// A float value. Stored as a 32 bit float.
|
||||
Float(f32),
|
||||
/// A string value.
|
||||
String(String),
|
||||
String(StringKey),
|
||||
}
|
||||
|
||||
/// A secondary effect is an effect on a move that happens after it hits.
|
||||
|
||||
Reference in New Issue
Block a user