Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Module ¶
type Module interface {
// Name returns the unique identifier of the module.
Name() string
// Init initializes the module with the server instance.
Init(ctx context.Context, srv *Server) error
}
Module represents a pluggable game feature module in Ultimate Game Engine.
type Server ¶
type Server struct {
Logger *zap.Logger
Config config.Config
DBPool *pgxpool.Pool
SQLDB *sql.DB
APIServer *api.Server
RuntimeManager *pkgruntime.GoRuntimeManager
RuntimeModule pkgruntime.RuntimeModule
ConsoleServer *console.Server
CronScheduler *pkgruntime.CronScheduler
LuaVM *lua.LState
JSVM *goja.Runtime
// contains filtered or unexported fields
}
Server is the programmatically embeddable engine instance for Ultimate Game Engine.
func NewServer ¶
NewServer initializes a new Ultimate Game Engine server instance from configuration.
func (*Server) RegisterInit ¶
func (s *Server) RegisterInit(fn pkgruntime.InitModuleFunc)
RegisterInit registers a native Go initialization function directly.
Click to show internal directories.
Click to hide internal directories.