Save JSON data as in-game variables?

So, I have been trying to access the Toops.json file through a script command to get the in battle targeted enemy's screen x and screen y and save each as a variable. The problem is that I have looked everywhere for how to do this but with no luck.

I have some understanding on what to do but no idea how to execute it. I need to get the Troop Id, the Enemy Index and the screen x and screen y variables of the target, but how do I get them?

To explain what I want to do with this is that I want to move the user to the same height location of the targets sprite during a battle. Then perform an animation that involves a projectile or beam hitting the target fired or launched by the user. I can manage some of this from Yanflys action sequences but not the location of the user to the target. If I can get the screen position x and screen position y of the target, I can use the Point Move to move the user to a specific location relative to target. No, the standard "front base" and the alike will not work since they are too close. What I stated at the beginning is the only way (that I can see) to make this work for the actor as the user and enemy as the target.

Does anyone know how to do this or how to do it in a better way?

This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

Original thread: https://forums.rpgmakerweb.com/threads/save-json-data-as-in-game-variables.82497/