remove demo
This commit is contained in:
@@ -804,26 +804,6 @@ pub fn bot_instance() -> Instance {
|
||||
return instance;
|
||||
}
|
||||
|
||||
pub fn demo() -> Result<Vec<Player>, Error> {
|
||||
let bot = bot_player();
|
||||
|
||||
// generate bot imgs for the client to see
|
||||
for c in bot.constructs.iter() {
|
||||
img::shapes_write(c.img)?;
|
||||
};
|
||||
|
||||
let bot2 = bot_player();
|
||||
|
||||
// generate bot imgs for the client to see
|
||||
for c in bot2.constructs.iter() {
|
||||
img::shapes_write(c.img)?;
|
||||
};
|
||||
|
||||
|
||||
Ok(vec![bot, bot2])
|
||||
}
|
||||
|
||||
|
||||
pub fn vbox_refill(tx: &mut Transaction, account: &Account, instance_id: Uuid) -> Result<Instance, Error> {
|
||||
let instance = instance_get(tx, instance_id)?
|
||||
.vbox_refill(account.id)?;
|
||||
|
||||
@@ -23,7 +23,6 @@ use ws::{Builder, CloseCode, Message, Handler, Request, Response, Settings, Send
|
||||
use ws::deflate::DeflateHandler;
|
||||
|
||||
use pg::{
|
||||
demo,
|
||||
game_concede,
|
||||
game_offer_draw,
|
||||
game_ready,
|
||||
@@ -48,7 +47,6 @@ use events::{Event};
|
||||
|
||||
use mnml_core::construct::{Construct};
|
||||
use mnml_core::game::{Game};
|
||||
use mnml_core::player::Player;
|
||||
|
||||
use mnml_core::vbox::{ItemType};
|
||||
use mnml_core::item::Item;
|
||||
@@ -73,8 +71,6 @@ pub enum RpcMessage {
|
||||
AccountInstances(Vec<Instance>),
|
||||
AccountShop(mtx::Shop),
|
||||
|
||||
Demo(Vec<Player>),
|
||||
|
||||
ConstructSpawn(Construct),
|
||||
GameState(Game),
|
||||
ItemInfo(ItemInfoCtr),
|
||||
@@ -391,8 +387,6 @@ impl Handler for Connection {
|
||||
|
||||
// tx should do nothing
|
||||
tx.commit().unwrap();
|
||||
} else {
|
||||
self.send(RpcMessage::Demo(demo().unwrap())).unwrap();
|
||||
}
|
||||
|
||||
Ok(())
|
||||
|
||||
Reference in New Issue
Block a user