In my RPG, you program your team with a constraint-based visual language. This video shows programming one character to buff another with mind split (makes spells hit multiple targets), casting focus (makes spells stronger), and the buffed character casting fire when there are at least 2 enemies with over 20% health. In most RPGs, battles are harder when you're fighting more enemies at a time. They start off challenging, but get way too easy after killing a few enemies. My idea for solving this is staggering enemies in a fight, so more emerge from the sand as you kill them, keeping difficulty pretty consistent throughout.