• You've discovered RedGuides 📕 an EverQuest multi-boxing community 🛡️🧙🗡️. We want you to play several EQ characters at once, come join us and say hello! 👋
  • IS THIS SITE UGLY? Change the look. To dismiss this notice, click the X --->

Plugin - MQ2Node - Evaluate and run macros in JavaScript (1 Viewer)

knervous

Active member
Joined
Feb 6, 2016
RedCents
431¢
Hi everyone, first time poster here, been sitting on this idea for awhile... I've spent a lot of time writing scripts on the MQ2 language which I've grown to love and hate. JS is my go-to language to spin things up quickly and the NodeJS runtime has become very mature and feature rich over the past years. I wanted to be able to apply that to MQ2 and see if it was possible.

Over the weekend I finally put it to task and got some good proofs of concept for this thing actually working. The dll is 68mb with the node engine, loads fairly quickly still.



/noderun <evaluate any javascript supported by nodejs, including require to import modules>

Very early idea stage right now, could really turn this into a very complex binding system. I'm currently building against rof2 and using ezserver as a testing ground. This code could of course be ported and modified for breaking changes in the API...

Is there any public interest in this in terms of use or collab for development?
 
I have toyed with this idea for a few years now. Back when I was young and ambitious and making a WoW bot using http://getrobot.net/ I though to myself I could "rewrite" MQ2 using JS. I've always dreamed of being able to use promises in my macros! I made a little wrapper instead and just let it die. I am more of a script kiddie instead of a real programmer anyways. I hack together CRUDs using whatever framework flavor of the month that my boss decides he wants to do.
 
Awesome, yeah this is a work in progress that I would eventually like to publish. Eventually I'll be at a point where I'd consider it "shippable" and then continue to add features.

Right now I have working:
- Executing scripts right from the Macro directory via /node macro.js
- Stopping execution for scripts that run indefinitely (setInterval or a long setTimeout)

I was even imagining writing a parser for current .mac files and translating it to JS. @Wink- for sure JS is so powerful it's for entry level all the way up to enterprise, Promises are super powerful for timing and node has async/await for better syntax. Overall as a (compiled) scripting language it's incredibly versatile. When I write up some real utility functions that I'll end up shipping with this I'll post these here too. In my mind they'll look and feel more semantic.

Currently starting to map data from the C++ API, little preview of that:

 
Going to use this thread as a dumping ground for updates on this for whoever's interested if that's ok - mods let me know if not.

Finished mapping the _SPAWNINFO struct this morning which should apply to many places that use this, right now just hooked up to my own char:

 
Nice big update here... Have a repo currently a WIP for all the code for anyone to check out:

If anyone wants to actually try this build let me know I have a few bugs and QOL to iron out but a lot of features will be ready soon.


Also managed to get DEBUGGING macros in realtime working. This is huge at least for me to continue developing and not relying on logs for echoing values:

 
I don't enjoy resurrecting old posts but this is, literally, the only MQ2Node post and I wanted to find out some more details as it would require me switching from a pre-compile and building on my own and I'd hate to do that to find out it's broken in some way or has massive gaps in utlity/functionality. Would be nice to be able to just use this like MQ2Lua or MQ2Mono (C#) as JS is a language I already know very well. Is this, essentially, complete?
 
I don't enjoy resurrecting old posts but this is, literally, the only MQ2Node post and I wanted to find out some more details as it would require me switching from a pre-compile and building on my own and I'd hate to do that to find out it's broken in some way or has massive gaps in utlity/functionality. Would be nice to be able to just use this like MQ2Lua or MQ2Mono (C#) as JS is a language I already know very well. Is this, essentially, complete?
knerv is/was the only one i know of working on mq2node

but you can build your own from the mq github, or the very vanilla from the open vanilla github
 
Plugin - MQ2Node - Evaluate and run macros in JavaScript

Users who are viewing this thread

Back
Top