Rebranding.
This commit is contained in:
parent
d0aeb9d9e4
commit
27b803e4e5
30 changed files with 193 additions and 196 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -1,2 +1,3 @@
|
||||||
exe
|
exe
|
||||||
*.vim
|
*.vim
|
||||||
|
*.exe
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
// Implements the camera component
|
// Implements the camera component
|
||||||
// for the main window.
|
// for the main window.
|
|
@ -1,7 +1,7 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/surdeus/gox/src/gx"
|
"github.com/reklesio/gg/src/gx"
|
||||||
"fmt"
|
"fmt"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -13,10 +13,7 @@ func main() {
|
||||||
gx.Vertex{30, 40},
|
gx.Vertex{30, 40},
|
||||||
gx.Vertex{40, 30},
|
gx.Vertex{40, 30},
|
||||||
}
|
}
|
||||||
|
|
||||||
fmt.Println("barycenter:", p.Barycenter())
|
fmt.Println("barycenter:", p.Barycenter())
|
||||||
fmt.Println("edges:", p.Edges())
|
fmt.Println("edges:", p.Edges())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
317
cmd/test/main.go
317
cmd/test/main.go
|
@ -1,7 +1,7 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/surdeus/gox/gx"
|
"github.com/reklesio/gg"
|
||||||
"github.com/hajimehoshi/ebiten/v2/examples/resources/images"
|
"github.com/hajimehoshi/ebiten/v2/examples/resources/images"
|
||||||
"github.com/hajimehoshi/ebiten/v2"
|
"github.com/hajimehoshi/ebiten/v2"
|
||||||
"bytes"
|
"bytes"
|
||||||
|
@ -12,7 +12,7 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
HighestL gx.Layer = -iota
|
HighestL gg.Layer = -iota
|
||||||
DebugL
|
DebugL
|
||||||
TriangleL
|
TriangleL
|
||||||
PlayerL
|
PlayerL
|
||||||
|
@ -21,76 +21,76 @@ const (
|
||||||
)
|
)
|
||||||
|
|
||||||
type Player struct {
|
type Player struct {
|
||||||
*gx.Sprite
|
*gg.Sprite
|
||||||
MoveSpeed gx.Float
|
MoveSpeed gg.Float
|
||||||
ScaleSpeed gx.Float
|
ScaleSpeed gg.Float
|
||||||
gx.Layer
|
gg.Layer
|
||||||
}
|
}
|
||||||
|
|
||||||
type Debug struct{
|
type Debug struct {
|
||||||
gx.Layer
|
gg.Layer
|
||||||
}
|
}
|
||||||
|
|
||||||
type Rect struct {
|
type Rect struct {
|
||||||
*gx.DrawableRectangle
|
*gg.DrawableRectangle
|
||||||
gx.Layer
|
gg.Layer
|
||||||
}
|
}
|
||||||
|
|
||||||
type Tri struct {
|
type Tri struct {
|
||||||
*gx.DrawablePolygon
|
*gg.DrawablePolygon
|
||||||
gx.Layer
|
gg.Layer
|
||||||
}
|
}
|
||||||
|
|
||||||
func NewTri() *Tri {
|
func NewTri() *Tri {
|
||||||
ret := &Tri{}
|
ret := &Tri{}
|
||||||
ret.DrawablePolygon = &gx.DrawablePolygon{}
|
ret.DrawablePolygon = &gg.DrawablePolygon{}
|
||||||
ret.Transform.S = gx.V(1, 1)
|
ret.Transform.S = gg.V(1, 1)
|
||||||
|
|
||||||
ret.Triangles = gx.Triangles{
|
ret.Triangles = gg.Triangles{
|
||||||
gx.Triangle{
|
gg.Triangle{
|
||||||
gx.V(0, 0),
|
gg.V(0, 0),
|
||||||
gx.V(100, 100),
|
gg.V(100, 100),
|
||||||
gx.V(0, -50),
|
gg.V(0, -50),
|
||||||
},
|
},
|
||||||
gx.Triangle{
|
gg.Triangle{
|
||||||
gx.V(0, 0),
|
gg.V(0, 0),
|
||||||
gx.V(-100, -100),
|
gg.V(-100, -100),
|
||||||
gx.V(0, 50),
|
gg.V(0, 50),
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
ret.Color = gx.Color{gx.MaxColorV, gx.MaxColorV, 0, gx.MaxColorV}
|
ret.Color = gg.Color{gg.MaxColorV, gg.MaxColorV, 0, gg.MaxColorV}
|
||||||
ret.Visible = true
|
ret.Visible = true
|
||||||
ret.Layer = TriangleL
|
ret.Layer = TriangleL
|
||||||
|
|
||||||
return ret
|
return ret
|
||||||
}
|
}
|
||||||
|
|
||||||
func NewRect() *Rect {
|
func NewRect() *Rect {
|
||||||
ret := &Rect{&gx.DrawableRectangle{
|
ret := &Rect{&gg.DrawableRectangle{
|
||||||
Rectangle: gx.Rectangle{
|
Rectangle: gg.Rectangle{
|
||||||
Transform: gx.Transform{
|
Transform: gg.Transform{
|
||||||
S: gx.Vector{
|
S: gg.Vector{
|
||||||
X: 200,
|
X: 200,
|
||||||
Y: 400,
|
Y: 400,
|
||||||
},
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
Color: gx.Color{
|
},
|
||||||
gx.MaxColorV,
|
Color: gg.Color{
|
||||||
0,
|
gg.MaxColorV,
|
||||||
0,
|
0,
|
||||||
gx.MaxColorV,
|
0,
|
||||||
|
gg.MaxColorV,
|
||||||
|
},
|
||||||
|
Visible: true,
|
||||||
|
/*Shader: gg.SolidWhiteColorShader,
|
||||||
|
Options: gg.ShaderOptions{
|
||||||
|
Images: [4]*gg.Image{
|
||||||
|
playerImg,
|
||||||
|
nil,
|
||||||
|
nil,
|
||||||
|
nil,
|
||||||
},
|
},
|
||||||
Visible: true,
|
},*/
|
||||||
/*Shader: gx.SolidWhiteColorShader,
|
|
||||||
Options: gx.ShaderOptions{
|
|
||||||
Images: [4]*gx.Image{
|
|
||||||
playerImg,
|
|
||||||
nil,
|
|
||||||
nil,
|
|
||||||
nil,
|
|
||||||
},
|
|
||||||
},*/
|
|
||||||
},
|
},
|
||||||
RectL,
|
RectL,
|
||||||
}
|
}
|
||||||
|
@ -98,190 +98,191 @@ func NewRect() *Rect {
|
||||||
return ret
|
return ret
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *Rect) Update(e *gx.Engine) error {
|
func (r *Rect) Update(e *gg.Engine) error {
|
||||||
//r.R += 0.3 * e.DT()
|
//r.R += 0.3 * e.DT()
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
var (
|
var (
|
||||||
playerImg *gx.Image
|
playerImg *gg.Image
|
||||||
player *Player
|
player *Player
|
||||||
rectMove gx.Rectangle
|
rectMove gg.Rectangle
|
||||||
rect *Rect
|
rect *Rect
|
||||||
tri *Tri
|
tri *Tri
|
||||||
)
|
)
|
||||||
|
|
||||||
func NewPlayer() *Player {
|
func NewPlayer() *Player {
|
||||||
ret := &Player{
|
ret := &Player{
|
||||||
Sprite: &gx.Sprite{
|
Sprite: &gg.Sprite{
|
||||||
Transform: gx.Transform {
|
Transform: gg.Transform{
|
||||||
S: gx.Vector{5, 5},
|
S: gg.Vector{5, 5},
|
||||||
RA: gx.Vector{.5, .5},
|
RA: gg.Vector{.5, .5},
|
||||||
},
|
},
|
||||||
Visible: true,
|
Visible: true,
|
||||||
ShaderOptions: gx.ShaderOptions {
|
ShaderOptions: gg.ShaderOptions{
|
||||||
Shader: gx.SolidWhiteColorShader,
|
Shader: gg.SolidWhiteColorShader,
|
||||||
Uniforms: make(map[string] any),
|
Uniforms: make(map[string]any),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
MoveSpeed: 90.,
|
MoveSpeed: 90.,
|
||||||
ScaleSpeed: .2,
|
ScaleSpeed: .2,
|
||||||
}
|
}
|
||||||
|
|
||||||
ret.Images[0] = playerImg
|
ret.Images[0] = playerImg
|
||||||
ret.Layer = PlayerL
|
ret.Layer = PlayerL
|
||||||
|
|
||||||
return ret
|
return ret
|
||||||
}
|
}
|
||||||
|
|
||||||
func (p *Player) Draw(e *gx.Engine, i *gx.Image) {
|
func (p *Player) Draw(e *gg.Engine, i *gg.Image) {
|
||||||
p.Sprite.Draw(e, i)
|
p.Sprite.Draw(e, i)
|
||||||
t := p.Transform
|
t := p.Transform
|
||||||
t.S.X *= 4.
|
t.S.X *= 4.
|
||||||
t.S.Y *= 4.
|
t.S.Y *= 4.
|
||||||
rectMove = gx.Rectangle{
|
rectMove = gg.Rectangle{
|
||||||
Transform: t,
|
Transform: t,
|
||||||
}
|
}
|
||||||
r := &gx.DrawableRectangle{
|
r := &gg.DrawableRectangle{
|
||||||
Rectangle: rectMove,
|
Rectangle: rectMove,
|
||||||
Color: gx.Color{0, 0, gx.MaxColorV, gx.MaxColorV},
|
Color: gg.Color{0, 0, gg.MaxColorV, gg.MaxColorV},
|
||||||
}
|
}
|
||||||
r.Draw(e, i)
|
r.Draw(e, i)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (p *Player) Start(e *gx.Engine, v ...any) {
|
func (p *Player) Start(e *gg.Engine, v ...any) {
|
||||||
fmt.Println("starting")
|
fmt.Println("starting")
|
||||||
c := e.Camera()
|
c := e.Camera()
|
||||||
c.RA = gx.V(360, 240)
|
c.RA = gg.V(360, 240)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (p *Player) Update(e *gx.Engine) error {
|
func (p *Player) Update(e *gg.Engine) error {
|
||||||
dt := e.DT()
|
dt := e.DT()
|
||||||
c := e.Camera()
|
c := e.Camera()
|
||||||
keys := e.Keys()
|
keys := e.Keys()
|
||||||
|
|
||||||
p.Uniforms["Random"] = any(rand.Float32())
|
p.Uniforms["Random"] = any(rand.Float32())
|
||||||
for _, v := range keys {switch v {
|
for _, v := range keys {
|
||||||
case ebiten.KeyArrowUp :
|
switch v {
|
||||||
c.P.Y += p.MoveSpeed * dt
|
case ebiten.KeyArrowUp:
|
||||||
case ebiten.KeyArrowLeft :
|
c.P.Y += p.MoveSpeed * dt
|
||||||
c.P.X -= p.MoveSpeed * dt
|
case ebiten.KeyArrowLeft:
|
||||||
case ebiten.KeyArrowDown :
|
c.P.X -= p.MoveSpeed * dt
|
||||||
c.P.Y -= p.MoveSpeed * dt
|
case ebiten.KeyArrowDown:
|
||||||
case ebiten.KeyArrowRight :
|
c.P.Y -= p.MoveSpeed * dt
|
||||||
c.P.X += p.MoveSpeed * dt
|
case ebiten.KeyArrowRight:
|
||||||
case ebiten.KeyW :
|
c.P.X += p.MoveSpeed * dt
|
||||||
p.P.Y += p.MoveSpeed * dt
|
case ebiten.KeyW:
|
||||||
case ebiten.KeyA :
|
p.P.Y += p.MoveSpeed * dt
|
||||||
p.P.X -= p.MoveSpeed * dt
|
case ebiten.KeyA:
|
||||||
case ebiten.KeyS :
|
p.P.X -= p.MoveSpeed * dt
|
||||||
p.P.Y -= p.MoveSpeed * dt
|
case ebiten.KeyS:
|
||||||
case ebiten.KeyD :
|
p.P.Y -= p.MoveSpeed * dt
|
||||||
p.P.X += p.MoveSpeed * dt
|
case ebiten.KeyD:
|
||||||
case ebiten.KeyR :
|
p.P.X += p.MoveSpeed * dt
|
||||||
c.R += gx.Pi * p.ScaleSpeed * dt
|
case ebiten.KeyR:
|
||||||
case ebiten.KeyT :
|
c.R += gg.Pi * p.ScaleSpeed * dt
|
||||||
c.R -= gx.Pi * p.ScaleSpeed * dt
|
case ebiten.KeyT:
|
||||||
case ebiten.KeyRightBracket :
|
c.R -= gg.Pi * p.ScaleSpeed * dt
|
||||||
if e.KeyIsPressed(ebiten.KeyShift) {
|
case ebiten.KeyRightBracket:
|
||||||
p.R -= gx.Pi * 0.3 * dt
|
if e.KeyIsPressed(ebiten.KeyShift) {
|
||||||
} else {
|
p.R -= gg.Pi * 0.3 * dt
|
||||||
p.R += gx.Pi * 0.3 * dt
|
} else {
|
||||||
|
p.R += gg.Pi * 0.3 * dt
|
||||||
|
}
|
||||||
|
case ebiten.KeyF:
|
||||||
|
if e.KeyIsPressed(ebiten.KeyShift) {
|
||||||
|
c.S.X -= gg.Pi * p.ScaleSpeed * dt
|
||||||
|
} else {
|
||||||
|
c.S.X += gg.Pi * p.ScaleSpeed * dt
|
||||||
|
}
|
||||||
|
case ebiten.KeyG:
|
||||||
|
if e.KeyIsPressed(ebiten.KeyShift) {
|
||||||
|
c.S.Y -= gg.Pi * p.ScaleSpeed * dt
|
||||||
|
} else {
|
||||||
|
c.S.Y += gg.Pi * p.ScaleSpeed * dt
|
||||||
|
}
|
||||||
|
case ebiten.KeyZ:
|
||||||
|
if e.KeyIsPressed(ebiten.KeyShift) {
|
||||||
|
c.RA.X -= gg.Pi * p.MoveSpeed * dt
|
||||||
|
} else {
|
||||||
|
c.RA.X += gg.Pi * p.MoveSpeed * dt
|
||||||
|
}
|
||||||
|
case ebiten.KeyX:
|
||||||
|
if e.KeyIsPressed(ebiten.KeyShift) {
|
||||||
|
c.RA.Y -= gg.Pi * p.MoveSpeed * dt
|
||||||
|
} else {
|
||||||
|
c.RA.Y += gg.Pi * p.MoveSpeed * dt
|
||||||
|
}
|
||||||
|
case ebiten.KeyV:
|
||||||
|
if e.KeyIsPressed(ebiten.KeyShift) {
|
||||||
|
tri.R -= gg.Pi * 0.3 * dt
|
||||||
|
} else {
|
||||||
|
tri.R += gg.Pi * 0.3 * dt
|
||||||
|
}
|
||||||
|
case ebiten.KeyLeftBracket:
|
||||||
|
if e.KeyIsPressed(ebiten.KeyShift) {
|
||||||
|
rect.R -= gg.Pi * 0.3 * dt
|
||||||
|
} else {
|
||||||
|
rect.R += gg.Pi * 0.3 * dt
|
||||||
|
}
|
||||||
|
case ebiten.Key0:
|
||||||
|
e.Del(p)
|
||||||
|
case ebiten.KeyB:
|
||||||
|
if p.Layer != PlayerL {
|
||||||
|
p.Layer = PlayerL
|
||||||
|
} else {
|
||||||
|
p.Layer = HighestL
|
||||||
|
}
|
||||||
}
|
}
|
||||||
case ebiten.KeyF :
|
}
|
||||||
if e.KeyIsPressed(ebiten.KeyShift) {
|
|
||||||
c.S.X -= gx.Pi * p.ScaleSpeed * dt
|
|
||||||
} else {
|
|
||||||
c.S.X += gx.Pi * p.ScaleSpeed * dt
|
|
||||||
}
|
|
||||||
case ebiten.KeyG :
|
|
||||||
if e.KeyIsPressed(ebiten.KeyShift) {
|
|
||||||
c.S.Y -= gx.Pi * p.ScaleSpeed * dt
|
|
||||||
} else {
|
|
||||||
c.S.Y += gx.Pi * p.ScaleSpeed * dt
|
|
||||||
}
|
|
||||||
case ebiten.KeyZ :
|
|
||||||
if e.KeyIsPressed(ebiten.KeyShift) {
|
|
||||||
c.RA.X -= gx.Pi * p.MoveSpeed * dt
|
|
||||||
} else {
|
|
||||||
c.RA.X += gx.Pi * p.MoveSpeed * dt
|
|
||||||
}
|
|
||||||
case ebiten.KeyX :
|
|
||||||
if e.KeyIsPressed(ebiten.KeyShift) {
|
|
||||||
c.RA.Y -= gx.Pi * p.MoveSpeed * dt
|
|
||||||
} else {
|
|
||||||
c.RA.Y += gx.Pi * p.MoveSpeed * dt
|
|
||||||
}
|
|
||||||
case ebiten.KeyV :
|
|
||||||
if e.KeyIsPressed(ebiten.KeyShift) {
|
|
||||||
tri.R -= gx.Pi * 0.3 * dt
|
|
||||||
} else {
|
|
||||||
tri.R += gx.Pi * 0.3 * dt
|
|
||||||
}
|
|
||||||
case ebiten.KeyLeftBracket :
|
|
||||||
if e.KeyIsPressed(ebiten.KeyShift) {
|
|
||||||
rect.R -= gx.Pi * 0.3 * dt
|
|
||||||
} else {
|
|
||||||
rect.R += gx.Pi * 0.3 * dt
|
|
||||||
}
|
|
||||||
case ebiten.Key0 :
|
|
||||||
e.Del(p)
|
|
||||||
case ebiten.KeyB :
|
|
||||||
if p.Layer != PlayerL {
|
|
||||||
p.Layer = PlayerL
|
|
||||||
} else {
|
|
||||||
p.Layer = HighestL
|
|
||||||
}
|
|
||||||
}}
|
|
||||||
|
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (d *Debug) Draw(
|
func (d *Debug) Draw(
|
||||||
e *gx.Engine,
|
e *gg.Engine,
|
||||||
i *gx.Image,
|
i *gg.Image,
|
||||||
) {
|
) {
|
||||||
keyStrs := []string{}
|
keyStrs := []string{}
|
||||||
for _, k := range e.Keys() {
|
for _, k := range e.Keys() {
|
||||||
keyStrs = append(keyStrs, k.String())
|
keyStrs = append(keyStrs, k.String())
|
||||||
}
|
}
|
||||||
|
|
||||||
if rectMove.Vertices().Contained(rect).Len() > 0 ||
|
if rectMove.Vertices().Contained(rect).Len() > 0 ||
|
||||||
rect.Vertices().Contained(rectMove).Len() > 0 {
|
rect.Vertices().Contained(rectMove).Len() > 0 {
|
||||||
keyStrs = append(keyStrs, "THIS IS SHIT")
|
keyStrs = append(keyStrs, "THIS IS SHIT")
|
||||||
}
|
}
|
||||||
|
|
||||||
e.DebugPrint(i,
|
e.DebugPrint(i,
|
||||||
strings.Join(keyStrs, ", "))
|
strings.Join(keyStrs, ", "))
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func (d *Debug) IsVisible() bool {return true}
|
func (d *Debug) IsVisible() bool { return true }
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
e := gx.NewEngine(&gx.WindowConfig{
|
e := gg.NewEngine(&gg.WindowConfig{
|
||||||
Title: "Test title",
|
Title: "Test title",
|
||||||
Width: 720,
|
Width: 720,
|
||||||
Height: 480,
|
Height: 480,
|
||||||
VSync: true,
|
VSync: true,
|
||||||
})
|
})
|
||||||
|
|
||||||
var err error
|
var err error
|
||||||
playerImg, err = gx.LoadImage(bytes.NewReader(images.Runner_png))
|
playerImg, err = gg.LoadImage(bytes.NewReader(images.Runner_png))
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Fatal(err)
|
log.Fatal(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
player = NewPlayer()
|
player = NewPlayer()
|
||||||
rect = NewRect()
|
rect = NewRect()
|
||||||
tri = NewTri()
|
tri = NewTri()
|
||||||
|
|
||||||
e.Add(&Debug{})
|
e.Add(&Debug{})
|
||||||
e.Add(player)
|
e.Add(player)
|
||||||
e.Add(rect)
|
e.Add(rect)
|
||||||
e.Add(tri)
|
e.Add(tri)
|
||||||
fmt.Println(rect.GetLayer(), player.GetLayer())
|
fmt.Println(rect.GetLayer(), player.GetLayer())
|
||||||
|
|
||||||
e.Run()
|
e.Run()
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
// Implementing the interface lets
|
// Implementing the interface lets
|
||||||
// the engine to work faster about
|
// the engine to work faster about
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/hajimehoshi/ebiten/v2/ebitenutil"
|
"github.com/hajimehoshi/ebiten/v2/ebitenutil"
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
// The structure represents elipses.
|
// The structure represents elipses.
|
||||||
type Elipse struct {
|
type Elipse struct {
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/hajimehoshi/ebiten/v2"
|
"github.com/hajimehoshi/ebiten/v2"
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"errors"
|
"errors"
|
|
@ -1,6 +0,0 @@
|
||||||
package gix
|
|
||||||
|
|
||||||
import (
|
|
||||||
)
|
|
||||||
|
|
||||||
|
|
2
go.mod
2
go.mod
|
@ -1,4 +1,4 @@
|
||||||
module github.com/surdeus/gox
|
module github.com/reklesio/gg
|
||||||
|
|
||||||
go 1.20
|
go 1.20
|
||||||
|
|
||||||
|
|
|
@ -1,3 +0,0 @@
|
||||||
package gx
|
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/hajimehoshi/ebiten/v2"
|
"github.com/hajimehoshi/ebiten/v2"
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/hajimehoshi/ebiten/v2"
|
"github.com/hajimehoshi/ebiten/v2"
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"math"
|
"math"
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"math"
|
"math"
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/hajimehoshi/ebiten/v2"
|
"github.com/hajimehoshi/ebiten/v2"
|
BIN
media/gopher.png
Normal file
BIN
media/gopher.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 172 KiB |
3
misc.go
Normal file
3
misc.go
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
package gg
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
// Implementing the interface type
|
// Implementing the interface type
|
||||||
// will call the function OnStart
|
// will call the function OnStart
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
)
|
)
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
// The type represents math ray.
|
// The type represents math ray.
|
||||||
type Ray struct {
|
type Ray struct {
|
|
@ -1,4 +1,8 @@
|
||||||
# gox
|
# gg
|
||||||
|
|
||||||
2D graphcs engine based on [ebiten](https://github.com/hajimehoshi/ebiten).
|
![Insert here a gopher, please](https://raw.githubusercontent.com/reklesio/gg/master/media/gopher.png)
|
||||||
|
|
||||||
|
Golang Graphics, Gopher Games or Good Game engine for 2D applications.
|
||||||
|
|
||||||
|
Basing on [ebiten](https://github.com/hajimehoshi/ebiten).
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/hajimehoshi/ebiten/v2"
|
"github.com/hajimehoshi/ebiten/v2"
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/hajimehoshi/ebiten/v2"
|
"github.com/hajimehoshi/ebiten/v2"
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/hajimehoshi/ebiten/v2"
|
"github.com/hajimehoshi/ebiten/v2"
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"time"
|
"time"
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
//"github.com/hajimehoshi/ebiten/v2"
|
//"github.com/hajimehoshi/ebiten/v2"
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"math"
|
"math"
|
|
@ -1,4 +1,4 @@
|
||||||
package gx
|
package gg
|
||||||
|
|
||||||
import (
|
import (
|
||||||
//"github.com/hajimehoshi/ebiten/v2"
|
//"github.com/hajimehoshi/ebiten/v2"
|
Loading…
Reference in a new issue