diff --git a/examples/audio/raw_stream/main.go b/examples/audio/raw_stream/main.go index 2f61886..a0a952b 100644 --- a/examples/audio/raw_stream/main.go +++ b/examples/audio/raw_stream/main.go @@ -47,7 +47,7 @@ func main() { numSamples = samplesLeft } - rl.UpdateAudioStream(stream, data[totalSamples-samplesLeft:], numSamples) + rl.UpdateAudioStream(stream, data[totalSamples-samplesLeft:]) samplesLeft -= numSamples diff --git a/examples/easings/easings/main.go b/examples/easings/easings/main.go index d4ae033..e56ae41 100644 --- a/examples/easings/easings/main.go +++ b/examples/easings/easings/main.go @@ -1,9 +1,11 @@ package main import ( + "strings" + "github.com/gen2brain/raylib-go/easings" "github.com/gen2brain/raylib-go/raygui" - "github.com/gen2brain/raylib-go/raylib" + rl "github.com/gen2brain/raylib-go/raylib" ) func main() { @@ -21,8 +23,8 @@ func main() { ballPosition := rl.NewVector2(startPositionX, float32(screenHeight)/2) - comboActive := 0 - comboLastActive := 0 + comboActive := int32(0) + comboLastActive := int32(0) easingTypes := []string{"SineIn", "SineOut", "SineInOut", "BounceIn", "BounceOut", "BounceInOut", "BackIn", "BackOut", "BackInOut"} ease := easingTypes[comboActive] @@ -75,7 +77,7 @@ func main() { rl.ClearBackground(rl.RayWhite) raygui.Label(rl.NewRectangle(20, 20, 200, 20), "Easing Type:") - comboActive = raygui.ComboBox(rl.NewRectangle(20, 40, 200, 20), easingTypes, comboActive) + comboActive = raygui.ComboBox(rl.NewRectangle(20, 40, 200, 20), strings.Join(easingTypes, ";"), comboActive) raygui.Label(rl.NewRectangle(20, 80, 200, 20), "Press R to reset") diff --git a/examples/others/utils/utils.go b/examples/others/utils/utils.go index 1dd5581..6829333 100644 --- a/examples/others/utils/utils.go +++ b/examples/others/utils/utils.go @@ -1,14 +1,15 @@ package main import ( - "github.com/gen2brain/raylib-go/raylib" "log" + + rl "github.com/gen2brain/raylib-go/raylib" ) func main() { rl.SetTraceLogCallback(func(logType int, str string) { level := "" - switch logType { + switch rl.TraceLogLevel(logType) { case rl.LogDebug: level = "Debug" case rl.LogError: @@ -22,7 +23,7 @@ func main() { case rl.LogFatal: level = "Fatal" } - if logType != rl.LogFatal { + if rl.TraceLogLevel(logType) != rl.LogFatal { log.Printf("%s - %s", level, str) } else { log.Fatalf("%s - %s", level, str)