class Touchable	extends Actor;

var private Pawn MyPawn;

var() bool bTouchable;
var() bool bUsable;

function Pawn GetMyPawn()
{
	return MyPawn;
}

function SetMyPawn(Pawn NewPawn)
{
	if ( MyPawn == NewPawn )
		return;
	
	if ( MyPawn != none ) {
		bHardAttach = false;
		SetBase(none);
	}
	
	MyPawn = NewPawn;
	if ( MyPawn != none ) {
		bHardAttach = true;
		SetLocation( MyPawn.Location );
		SetBase(MyPawn);	
		SetCollisionSize(MyPawn.CollisionRadius * 1.5, MyPawn.CollisionHeight) ;
	}
}

function Touch( Actor Other )
{
	if ( bTouchable && MyPawn != none && MyPawn != Other )
		MyPawn.Touch(Other);
}

function UsedBy( Pawn user )
{
	if ( bUsable && MyPawn != none && MyPawn != user )
		MyPawn.UsedBy(user);
}

defaultproperties
{
     bHidden=True
     RemoteRole=ROLE_None
     CollisionRadius=30.000000
     CollisionHeight=40.000000
     bCollideActors=True
}
