diff options
| author | troido <troido@protonmail.com> | 2020-04-03 23:25:20 +0200 |
|---|---|---|
| committer | troido <troido@protonmail.com> | 2020-04-03 23:25:20 +0200 |
| commit | 0b17829846adf9482b460e4cc616382ede1df6dd (patch) | |
| tree | 2f02dd93b1cd4cd7615341644ddeb94ed0dfc422 /src/purgatory.rs | |
| parent | db473bbab28847bed5f26fb443ef8a1db2d932a3 (diff) | |
private rooms work!
Diffstat (limited to 'src/purgatory.rs')
| -rw-r--r-- | src/purgatory.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/purgatory.rs b/src/purgatory.rs index b4d8666..04024db 100644 --- a/src/purgatory.rs +++ b/src/purgatory.rs @@ -26,7 +26,7 @@ pub fn purgatory_id() -> RoomId { RoomId{name: String::from("+")} } -pub fn create_purgatory<'a, 'b>(encyclopedia: Encyclopedia) -> Room<'a, 'b> { +pub fn create_purgatory<'a, 'b>(encyclopedia: &Encyclopedia) -> Room<'a, 'b> { let dispatcher = DispatcherBuilder::new() .with(Volate, "volate", &[]) .with(RegisterNew::default(), "registernew", &[]) @@ -38,7 +38,7 @@ pub fn create_purgatory<'a, 'b>(encyclopedia: Encyclopedia) -> Room<'a, 'b> { .with(Create, "create", &["view"]) .with(Remove, "remove", &["view", "move"]) .build(); - let mut room = Room::new(purgatory_id(), encyclopedia, dispatcher); + let mut room = Room::new(purgatory_id(), encyclopedia.clone(), dispatcher); room.load_from_template(&RoomTemplate::from_json(&json!({ "width": 15, "height": 20, |
