//-----------------------------------------------------------------------------
//
//  $Logfile:: /game/areaportal.h                                             $
// $Revision:: 2                                                              $
//   $Author:: Burgermac                                                      $
//     $Date:: 12/27/00 6:52 PM                                               $
//
// Copyright (C) 1998 by Ritual Entertainment, Inc.
// All rights reserved.
//
// This source is may not be distributed and/or modified without
// expressly written permission by Ritual Entertainment, Inc.
//
// DESCRIPTION:
//

#ifndef __AREAPORTAL_H__
#define __AREAPORTAL_H__

#include "g_local.h"
#include "entity.h"

extern Event EV_AreaPortal_Open;
extern Event EV_AreaPortal_Close;

void SetAreaPortals( const char* name, qboolean open );

class AreaPortal : public Entity
{
private:
	int portalstate;
	int portalnum;

public:
	CLASS_PROTOTYPE( AreaPortal );

	AreaPortal();
	void        SetPortalState( qboolean state );
	qboolean PortalOpen( void );
	void        Open( Event* ev );
	void        Close( Event* ev );
	virtual void Archive( Archiver& arc );
	virtual void Unarchive( Archiver& arc );
};

#endif
