core

package
v0.0.0-...-50d5a6e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 3, 2023 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GLFWInit

func GLFWInit()

func InitTimer

func InitTimer()

Types

type ImguiSandbox

type ImguiSandbox struct {
	// contains filtered or unexported fields
}

func InitImguiSandbox

func InitImguiSandbox() *ImguiSandbox

func (*ImguiSandbox) RenderPanel

func (sandbox *ImguiSandbox) RenderPanel()

type MTimer

type MTimer struct {
	// contains filtered or unexported fields
}
var Timer *MTimer

func (*MTimer) DeltaTime

func (timer *MTimer) DeltaTime() float64

func (*MTimer) FPS

func (timer *MTimer) FPS() float64

func (*MTimer) FrameTime

func (timer *MTimer) FrameTime() float64

func (*MTimer) ProgramTime

func (timer *MTimer) ProgramTime() float64

func (*MTimer) SetTimeDilation

func (timer *MTimer) SetTimeDilation(dilation float64)

func (*MTimer) Update

func (timer *MTimer) Update()

Should only be called from the engine

func (*MTimer) UpdateFrameData

func (timer *MTimer) UpdateFrameData(start, end float64)

type MangoSystem

type MangoSystem interface {
	InitializeSystem()

	UpdateSystem()
}

type RenderMode

type RenderMode int
var RENDER_MODE_DEFAULT RenderMode = 0

DEFAULT ECS RENDERING (n/a for now)

var RENDER_MODE_IM RenderMode = 1

IMMEDIATE MODE RENDERING

type Scene

type Scene struct {
	// contains filtered or unexported fields
}

func NewScene

func NewScene() *Scene

func (*Scene) AddPrefab

func (scene *Scene) AddPrefab(prefab ecs.Prefab) *ecs.Entity

func (*Scene) CreateEntity

func (scene *Scene) CreateEntity(id string) *ecs.Entity

Creates a new entity and adds it to the scene

func (*Scene) ECS

func (scene *Scene) ECS() *ecs.ECS

Get the scene's Entity Component System

func (*Scene) Update

func (scene *Scene) Update()

type SceneEditor

type SceneEditor struct {
	Scene *Scene
	// contains filtered or unexported fields
}

func NewSceneEditor

func NewSceneEditor(scene *Scene, windowWidth, windowHeight int) *SceneEditor

func (*SceneEditor) RenderPanel

func (editor *SceneEditor) RenderPanel()

Render the editor panel

type ShaderEditor

type ShaderEditor struct {
	// contains filtered or unexported fields
}

func NewShaderEditor

func NewShaderEditor() *ShaderEditor

Constructor function

func (*ShaderEditor) RenderPanel

func (editor *ShaderEditor) RenderPanel()

type SystemManager

type SystemManager struct {
	// contains filtered or unexported fields
}

func NewSystemManager

func NewSystemManager() *SystemManager

func (*SystemManager) AddSystem

func (manager *SystemManager) AddSystem(system MangoSystem) bool

func (*SystemManager) ContainsSystem

func (manager *SystemManager) ContainsSystem(system MangoSystem) bool

func (*SystemManager) ContainsSystemOfType

func (manager *SystemManager) ContainsSystemOfType(t reflect.Type) bool

func (*SystemManager) GetSystem

func (manager *SystemManager) GetSystem(system MangoSystem) (MangoSystem, error)

func (*SystemManager) GetSystemOfType

func (manager *SystemManager) GetSystemOfType(t reflect.Type) (MangoSystem, error)

func (*SystemManager) Update

func (manager *SystemManager) Update()

type Window

type Window struct {
	*glfw.Window
	// contains filtered or unexported fields
}

func CreateWindow

func CreateWindow(width, height int, title string, vsync bool) *Window

func (*Window) GetTitle

func (w *Window) GetTitle() string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL