text: /*
  				Copyright <SWGEmu>
  		See file COPYING for copying conditions.*/
  
  #ifndef JOINCOMMAND_H_
  #define JOINCOMMAND_H_
  
  #include "server/zone/managers/group/GroupManager.h"
  
  class JoinCommand : public QueueCommand {
  public:
  
  	JoinCommand(const String& name, ZoneProcessServer* server)
  		: QueueCommand(name, server) {
  
  	}
  
  	int doQueueCommand(CreatureObject* creature, const uint64& target, const UnicodeString& arguments) const {
  
  		if (!checkStateMask(creature))
  			return INVALIDSTATE;
  
  		if (!checkInvalidLocomotions(creature))
  			return INVALIDLOCOMOTION;
  
  		GroupManager* groupManager = GroupManager::instance();
  		groupManager->joinGroup(creature);
  		creature->playEffect("clienteffect/death_trooper_anti_virus.cef", "");
  		return SUCCESS;
  	}
  
  };
  
  #endif //JOINCOMMAND_H_
  