From d9dc86b8dce433947c81ba87ad0bad83d4bc96f6 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 24 Aug 2014 22:06:47 +0300 Subject: Move chat command /erase into actions. --- src/commands.cpp | 44 -------------------------------------------- 1 file changed, 44 deletions(-) (limited to 'src/commands.cpp') diff --git a/src/commands.cpp b/src/commands.cpp index 031bcd0a9..953f2679d 100644 --- a/src/commands.cpp +++ b/src/commands.cpp @@ -384,50 +384,6 @@ impHandler0(present) return false; } -impHandler(erase) -{ - if (event.args.empty()) - { - if (event.tab) - { - // TRANSLATORS: erase command - event.tab->chatLog(_("Please specify a name."), ChatMsgType::BY_SERVER); - } - return true; - } - - if (player_relations.getRelation(event.args) == PlayerRelation::ERASED) - { - if (event.tab) - { - // TRANSLATORS: erase command - event.tab->chatLog(_("Player already erased!"), ChatMsgType::BY_SERVER); - } - return true; - } - else - { - player_relations.setRelation(event.args, PlayerRelation::ERASED); - } - - if (event.tab) - { - if (player_relations.getRelation(event.args) == PlayerRelation::ERASED) - { - // TRANSLATORS: erase command - event.tab->chatLog(_("Player successfully erased!"), - ChatMsgType::BY_SERVER); - } - else - { - // TRANSLATORS: erase command - event.tab->chatLog(_("Player could not be erased!"), - ChatMsgType::BY_SERVER); - } - } - return true; -} - impHandler0(quit) { // quit(); -- cgit v1.2.3-70-g09d2