class ForceCarAlarm extends ActionBool
{

	public function SetProperties( isAlarmTriggered : Bool )
	{
		actionName = 'ForceCarAlarm';
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, isAlarmTriggered, 'LocKey#294', 'LocKey#294' );
	}

	public static function IsDefaultConditionMet( device : VehicleComponentPS, const context : ref< GetActionsContext > ) : Bool
	{
		if( IsAvailable( device ) && IsClearanceValid( context.clearance ) )
		{
			return true;
		}
		return false;
	}

	public constexpr static function IsAvailable( device : VehicleComponentPS ) : Bool
	{
		return true;
	}

	public static function IsClearanceValid( clearance : Clearance ) : Bool
	{
		if( Clearance.IsInRange( clearance, DefaultActionsParametersHolder.GetInteractiveClearance() ) )
		{
			return true;
		}
		return false;
	}

	public override function GetTweakDBChoiceRecord() : String
	{
		if( TDBID.IsValid( m_objectActionID ) )
		{
			return super.GetTweakDBChoiceRecord();
		}
		else
		{
			return "StartAlarm";
		}
	}

}

class ForceDisableCarAlarm extends ActionBool
{

	public function SetProperties( isAlarmTriggered : Bool )
	{
		actionName = 'ForceDisableCarAlarm';
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, isAlarmTriggered, 'LocKey#295', 'LocKey#295' );
	}

	public override function GetTweakDBChoiceRecord() : String
	{
		return "DeactivateAlarm";
	}

}

class ToggleVehicle extends ActionBool
{

	public function SetProperties( toggleOn : Bool )
	{
		actionName = 'ToggleVehicle';
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, toggleOn, 'LocKey#296', 'LocKey#297' );
	}

	public override function GetTweakDBChoiceRecord() : String
	{
		var toggleOn : Bool;
		var toggleOnName : CName;
		var toggleOffName : CName;
		DeviceActionPropertyFunctions.GetProperty_Bool( prop, toggleOn, toggleOffName, toggleOnName );
		return NameToString( ( ( toggleOn ) ? ( toggleOnName ) : ( toggleOffName ) ) );
	}

}

class VehicleOpenTrunk extends ActionBool
{

	public function SetProperties()
	{
		actionName = 'OpenTrunk';
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, 'LocKey#302', 'LocKey#302' );
	}

}

class VehicleCloseTrunk extends ActionBool
{

	public function SetProperties()
	{
		actionName = 'CloseTrunk';
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, 'LocKey#303', 'LocKey#303' );
	}

}

class VehicleDumpBody extends ActionBool
{

	public function SetProperties()
	{
		actionName = 'VehicleDumpBody';
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, 'LocKey#304', 'LocKey#304' );
	}

}

class VehicleTakeBody extends ActionBool
{

	public function SetProperties()
	{
		actionName = 'VehicleTakeBody';
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, 'LocKey#305', 'LocKey#305' );
	}

}

class VehiclePlayerTrunk extends ActionBool
{

	public function SetProperties()
	{
		actionName = 'PlayerTrunk';
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, 'LocKey#17845', 'LocKey#17845' );
	}

}

class VehicleOpenHood extends ActionBool
{

	public function SetProperties()
	{
		actionName = 'OpenHood';
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, 'LocKey#302', 'LocKey#302' );
	}

}

class VehicleCloseHood extends ActionBool
{

	public function SetProperties()
	{
		actionName = 'CloseHood';
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, 'LocKey#303', 'LocKey#303' );
	}

}

class VehicleDoorInteraction extends ActionBool
{
	var slotID : CName;
	var isInteractionSource : Bool;

	public function SetProperties( const slotString : ref< String >, optional source : Bool, optional locked : Bool )
	{
		slotID = StringToName( slotString );
		if( locked )
		{
			actionName = StringToName( "vehicle_door_locked" );
		}
		else
		{
			actionName = '';
		}
		isInteractionSource = source;
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, actionName, actionName );
	}

}

class VehicleDoorInteractionStateChange extends ActionBool
{
	var door : EVehicleDoor;
	var newState : VehicleDoorInteractionState;
	var source : String;

	public function SetProperties( doorToChange : EVehicleDoor, desiredState : VehicleDoorInteractionState, const reason : ref< String > )
	{
		actionName = '';
		door = doorToChange;
		newState = desiredState;
		source = reason;
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, actionName, actionName );
	}

}

class VehicleDoorOpen extends ActionBool
{
	var slotID : CName;
	var shouldAutoClose : Bool;
	var autoCloseTime : Float;
	var forceScene : Bool;

	public function SetProperties( const slotString : ref< String >, optional autoClose : Bool, optional autoCloseDelay : Float )
	{
		actionName = '';
		slotID = StringToName( slotString );
		shouldAutoClose = autoClose;
		autoCloseTime = autoCloseDelay;
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, actionName, actionName );
	}

}

class VehicleDoorClose extends ActionBool
{
	var slotID : CName;
	var isInteractionSource : Bool;
	var forceScene : Bool;

	public function SetProperties( const slotString : ref< String > )
	{
		actionName = '';
		slotID = StringToName( slotString );
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, actionName, actionName );
	}

}

class VehicleDoorDetached extends ActionBool
{
	var slotID : CName;
	var isInteractionSource : Bool;

	public function SetProperties( const slotString : ref< String >, optional source : Bool )
	{
		actionName = '';
		slotID = StringToName( slotString );
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, actionName, actionName );
	}

}

class VehicleQuestDoorLocked extends ActionBool
{

	public function SetProperties()
	{
		actionName = 'vehicle_door_quest_locked';
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, 'LocKey#23298', 'LocKey#23298' );
	}

}

class VehicleWindowOpen extends ActionBool
{
	var slotID : CName;
	var speed : CName;

	public function SetProperties( const slotString : ref< String > )
	{
		actionName = '';
		slotID = StringToName( slotString );
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, actionName, actionName );
	}

}

class VehicleWindowClose extends ActionBool
{
	var slotID : CName;
	var speed : CName;
	var isInteractionSource : Bool;

	public function SetProperties( const slotString : ref< String > )
	{
		actionName = '';
		slotID = StringToName( slotString );
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, actionName, actionName );
	}

}

class VehicleForceOccupantOut extends ActionBool
{
	var slotID : CName;

	public function SetProperties( const slotString : ref< String > )
	{
		actionName = StringToName( "VehicleForceOccupantOut_" + slotString );
		slotID = StringToName( slotString );
		prop = DeviceActionPropertyFunctions.SetUpProperty_Bool( actionName, true, actionName, actionName );
	}

}

struct VehicleActionsContext
{
	var requestorID : EntityID;
	var requestType : gamedeviceRequestType;
	var interactionLayerTag : CName;
	var processInitiatorObject : weak< GameObject >;
	var eventType : gameinteractionsEInteractionEventType;
}

