Let the player write character's behavior with lua

i’m making an rpg . my idea for the game is that the player doesn’t control the character in battles, they just write code to give instructions to the character, it’d be run on the turn of each character, is it possible? also, i’m making the game in blueprints and don’t know how to code, so if it needs coding, i will need it to be explained very detailed

You will definitly need to write script support in C++, there was lua plugin i think, but even so for what you want to make, you need to make more isolated from engine implementation.

You have a couple choices, the first is to learn how to program, and the second is to pay someone to program it for you. What you are talking about can be done, but I think anyone would consider it an advanced undertaking and you will not find tutorials for it.