How to play animation from code

Is this like before that you had your nodes and you called them to do something ?

how do you get your nodes from code the references in order to play animations ?

As far as i know, you can play an AnimationMontage, just declare a UAnimMontage, inits it using ConstructorHelper and then use PlayAnimMontage. I dont know if its possible to play an AnimationSequence

And what about the , nodes of the anim tree , " or however it’s called the ( lol i don’t even remember it ) the anim tree of UE4 " ?

The Animation Blueprints use States and Transitions, yo change betwen states just change the conditions in C++ to change the state, for example, if you have two states Idle and Aim, and the transition is “IsAiming”, just change the boolean IsAiming in C++ and be sure that is changing too in the Animation Blueprint (in the Event Graph)