This commit is contained in:
@@ -9,6 +9,7 @@ use crate::StringKey;
|
||||
#[derive(Copy, Clone, PartialEq, Eq, Debug)]
|
||||
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
|
||||
#[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
|
||||
#[repr(u8)]
|
||||
pub enum MoveCategory {
|
||||
/// A physical move uses the physical attack stats and physical defense stats to calculate damage.
|
||||
Physical = 0,
|
||||
@@ -21,6 +22,7 @@ pub enum MoveCategory {
|
||||
/// The move target defines what kind of targets the move can touch.
|
||||
#[derive(Copy, Clone, PartialEq, Eq, Debug, Default)]
|
||||
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
|
||||
#[repr(u8)]
|
||||
pub enum MoveTarget {
|
||||
/// Adjacent allows a move to target any Pokemon that is either directly to the left or right of
|
||||
/// the user, opposed to the user, or left or right of the slot that is opposing the user.
|
||||
|
||||
@@ -1,20 +1,6 @@
|
||||
use crate::static_data::EffectParameter;
|
||||
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),
|
||||
/// An integer value. Stored as a 64 bit int to deal with potentially large numbers.
|
||||
Int(i64),
|
||||
/// A float value. Stored as a 32 bit float.
|
||||
Float(f32),
|
||||
/// A string value.
|
||||
String(StringKey),
|
||||
}
|
||||
|
||||
/// A secondary effect is an effect on a move that happens after it hits.
|
||||
#[derive(PartialEq, Debug)]
|
||||
pub struct SecondaryEffect {
|
||||
|
||||
Reference in New Issue
Block a user