//-----------------------------------------------------------------------------
//
//  $Logfile:: /game/ctf_turret.h                                             $
// $Revision:: 2                                                              $
//   $Author:: Burgermac                                                      $
//     $Date:: 12/27/00 7:09 PM                                               $
//
// Copyright (C) 1997 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:
// Fires a spear.  Used by Seabonites.
//

#ifndef __CTF_TURRET_H__
#define __CTF_TURRET_H__

#include "g_local.h"
#include "vehicle.h"
#include "heligun.h"
#include "bullet.h"
#include "sentient.h"


class CTFTurret : public DrivableVehicle
{
public:
	CLASS_PROTOTYPE( CTFTurret );

	CTFTurret();
	virtual void        DriverUse( Event* ev );
	virtual float       SetDriverPitch( float pitch );
};


class CTFTurretGun : public HeliGun
{
public:
	CLASS_PROTOTYPE( CTFTurretGun );

	CTFTurretGun();
	virtual void        Shoot( Event* ev );
	qboolean          IsDroppable( void );

};

class CTFDrivableTurret : public DrivableVehicle
{
private:
	Vector baseangles;
	float maxpitch;
	float maxyaw;
	float entertime;
	float exittime;
	int lastbutton;
	float shotdamage;
	Sentient*          gunholder;
	BulletWeapon*      gun;

public:
	CLASS_PROTOTYPE( CTFDrivableTurret );

	CTFDrivableTurret();
	virtual qboolean    Drive( usercmd_t* ucmd );
	virtual void        Postthink( void );
	virtual void      Fire( void );
	virtual float       SetDriverPitch( float pitch );
	virtual void        DriverUse( Event* ev );
};

#endif /* ctfturret.h */
