summaryrefslogtreecommitdiff
path: root/src/fromtoparameter.rs
diff options
context:
space:
mode:
authortroido <troido@protonmail.com>2020-09-24 22:18:30 +0200
committertroido <troido@protonmail.com>2020-09-24 22:18:30 +0200
commit9eb3a9da97e53cee14e585e027badb3783b8e25e (patch)
tree4840bc49cbde975289b3e3b663967a368b444f8b /src/fromtoparameter.rs
parent13b53f3e89bcd6d33a534403162d1b09502bec70 (diff)
turned sprite, playerid and roomid into tuple structs
Diffstat (limited to 'src/fromtoparameter.rs')
-rw-r--r--src/fromtoparameter.rs8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/fromtoparameter.rs b/src/fromtoparameter.rs
index 75912ae..8d169d0 100644
--- a/src/fromtoparameter.rs
+++ b/src/fromtoparameter.rs
@@ -7,7 +7,8 @@ use crate::{
Pos,
PlayerId,
Sprite,
- ItemId
+ ItemId,
+ RoomId
};
pub trait FromToParameter: Sized {
@@ -78,9 +79,10 @@ tofrom!(String: String);
tofrom!(Pos: Pos);
tofrom!(Template: Template);
-tofrom!(PlayerId{name: String});
-tofrom!(Sprite{name: String});
+tofrom!(PlayerId(String));
+tofrom!(Sprite(String));
tofrom!(ItemId(String));
+tofrom!(RoomId(String));
impl<T> FromToParameter for Vec<T>
where