-
Notifications
You must be signed in to change notification settings - Fork 2
Home
moxcomic edited this page Dec 3, 2023
·
13 revisions
- Support Golang
- Support Javascript
package name must be main
example auto.go
:
package main
import (
"github.com/moxcomic/lq"
)
func onLogin() { }
func onRoomGameStart() { }
func onMatchGameStart() { }
func onNewRound() { }
func onRoundEnd() { }
func onPlayerLeaving(seat int) { }
func onExecute(result *lq.NotifyAIResult, risk []float64, rating, matches, fivePer, tenPer float64)
func onGameEnd() { }
func onServerDisconnect() { }
example auto.js
:
// The js doesn't need to be imported, it can be used directly
// For example: const hand = gamestate.Inst().HandTile()
const main = {
onLogin: () => { },
onRoomGameStart: () => { },
onMatchGameStart: () => { },
onNewRound: () => { },
onRoundEnd: () => { },
onPlayerLeaving: (seat) => { },
onExecute: (result, risk, r, m, f, t) => { },
onGameEnd: () => { },
onServerDisconnect: () => { }
};