So... how I write a script?

I can see this is very different from Ace. There's no way of figuring where all the script editor stuff is at.

Granted, I have visual studio 2015 enterprise, but that's mainly for C#. Sure, Javascript is similar language to C#, but have different meanings. My main concern is what's introduced with the engine, so rather than modifying my own engine, I can simply add in extra.
You should start by going to the learning Javascript section and viewing posts there.. you may want to check out some plug-ins created by other users and reverse engineer them to see the interactions between software and plugin.

Plug-ins can be found and stored in your www/js/Plug-ins folder

Original thread: https://forums.rpgmakerweb.com/threads/so-how-i-write-a-script.47921/