How can I have a common event check to see if an attached skill is used during battle?

In my game, I have a Warp spell that has a different effect dependent upon whether its used inside or outside of battle. When used in battle, the battle ends and the player flees. When used outside of battle, specifically only when in a dungeon, it will teleport the Player to the entrance of the dungeon.

Here's what I have planned: The Warp spell has an attached common event. That common event will have a conditional branch, which checks to see whether the player is currently in battle or not. For clarification, that last part is what I'm struggling with.
Do you mean checking to see if the player is in battle?
That's a simple script condition branch.
SceneManager.scene_is?(Scene_Battle)

Original thread: https://forums.rpgmakerweb.com/threads/how-can-i-have-a-common-event-check-to-see-if-an-attached-skill-is-used-during-battle.168426/