Dunno if it's quite what you want, but there's an extremely easy way to do transformations, without any script at all.
You make the transform skill link to a common event. Don't change any other settings except maybe the icon or name or whatever.
In the common event, you can use the event options "Change Hero Name", "Change Hero Class", "Change Skills", "Change Base Statistics", "Change Equipped Items", and "Change Hero Graphic", all located on the third page in the first column. You can change all of these to the transformation's stats. If you want the transformation spell's to be based upon the hero's level as well, just include a conditional branch off of the hero's spells - Make it so if the hero knows a level 10 spell, the transformation will know its own level 10 spell when you transform into it.
Then, on every map, you insert a parallel process event with a conditional branch if the Hero name is (the transformation's name), it changes his name back, his class back, his graphic back, removes the transformation's spells, and adds his own spells (do the spells the same way that you did them when transforming, with conditional branches depending on what level spells and such), etc.
Hope that wasn't too confusing >_<