Event ID as a Variable

I'm trying to get a script command where I can store the x and y information of an event into a variable with EventID
as another variable.

$gameVariables.setValue(199, $gameMap.event(EventID).x)
$gameVariables.setValue(200, $gameMap.event(EventID).y)

What I need is something like this...only for it to work and have the right syntax...

$gameVariables.setValue(199, $gameMap.event($gameVariables.value(299)).x)
$gameVariables.setValue(200, $gameMap.event($gameVariables.value(299)).y)

Where the EventID is the value of variable# 299.
I can't see why this wouldn't work. How are you trying to use this? Images of your event would be helpful.
Perhaps you mean this?
Code:
$gameVariables.setValue(199, $gameMap.event(this._eventId).x)
$gameVariables.setValue(200, $gameMap.event(this._eventId).y)

Original thread: https://forums.rpgmakerweb.com/threads/event-id-as-a-variable.104531/