I did this with the limitations we have, I also made it so a player can use a spell(event) and trap another play in pvp. It's a bit complex and took me a day to get it working but basically I put the same event all over the entire map, make a global variable then set the spawn condition for the events to be value 1 for the global variable(make sure you got at least 1 event on the map always keeping the global variable at 0 as you will be using a Spell(event) to switch it. Then just have that event warp the player to a different map which will happen right after they move once you use the trap spell(event) which is just a spell event switching the variable to 1(ON). I made a black map with invis blocks stopping them from moving( a trap room) but make that map full of events as well so when they move or even stand still it will transport them back after a certain amount of time while also at the same time switching the global variable back to 0(OFF) just to be safe and make sure you use labels and selfswitches to reset the event back to the start for the next time you use the trap spell. So for pvp if you want 1 class to be able to trap all the other classes just add a spawn condition to the trap events on top of needing global variable @ 1 specifying a certain stat needed then just make sure the only class without that stat is the one you want to have the trap spell.
Sorry if this is confusing, I will let you figure it out and will answer questions if you need but can''t post all the events right now since they contain a bit extra then I mentioned and I will be unveiling my game in the future. I am also sure there is better more efficient way to do this but this is what I came up with at 5am tired as hell.