#pragma once

#include "../../../GAME_COMMON.h"
#include "../../../input/input.h"
#include "../../ecs_entity.h"

#include "../component_physics.h"
#include "component_action_return.h"

typedef struct ComponentActionLock
{
	ECSComponent component;
	u32 sender;
	vec3 velocity;
	bool isLock;
	bool isLocked;
} ComponentActionLock;

void component_action_lock_init(ComponentActionLock* self, u32 sender);
void component_action_lock_tick(ComponentActionLock* self, ECS* ecs);
void component_action_lock_lock(ComponentActionLock* self, ECS* ecs);
void component_action_lock_unlock(ComponentActionLock* self, ECS* ecs);

static const ECSComponentInfo COMPONENT_ACTION_LOCK_INFO = 
{
	.system = 
	{
		.functions = 
		{ 
			NULL,
			NULL,
			(ECSFunction)component_action_lock_tick,
			NULL
		}
	},
	.type = ECS_COMPONENT_ACTION_LOCK,
	.size = sizeof(ComponentActionLock)
};


