package
0.3.3
Repository: https://github.com/kmcsr/go-liter.git
Documentation: pkg.go.dev

# Packages

No description provided by the author

# README

Script

We use goja as our javascript engine.
Goja support full ES5, but it DOES NOT support full ES6 yet.
Please read their Features and Known incompatibilities to see what you can use and what you cannot

Setup

Lazy setup

npm init glp@latest "<plugin-name>"

Note: Typescript will be automaticly configured.

Manually setup

You may want to configure your project manually, then you have to do the commands below

  1. Install go-liter-plugin:

    npm install go-liter-plugin
    
  2. Add the following element to your tsconfig.json

    {
       "compilerOptions": {
          "typeRoots": [
             "node_modules/@types",
             "node_modules/go-liter-plugin"
          ]
       }
    }
    

Typescript

Check files under ./types/lib/ for more information

Events

There is a list of events on each object below

$

Event NameDescriptionConsequences after called cancel()
unloadThe unload event for the pluginN/A
handshakeClient sent the handshake packetAbort client to connect to the target server, but allows the scripts to handle packet event on the connection.
serveThe server connection is successAbort to use native directly copy, but allows the scripts to handle packet event on the connection.

Conn

Event NameDescriptionConsequences after called cancel()
packetReceived a minecraft packetPrevent this packet to be forward
errorAn error occurred on the connectionN/A
closeConnection closedN/A
before_closeThe other connection of the pair closedThis connection will not be closed.