Mercurial > games > semicongine
changeset 1142:bf9dedd36bed
fix: a few things
author | sam <sam@basx.dev> |
---|---|
date | Sat, 08 Jun 2024 16:19:05 +0700 |
parents | d3e014c3551c |
children | d7891cf88359 af18922b416d |
files | semicongine/animation.nim semicongine/engine.nim |
diffstat | 2 files changed, 4 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/semicongine/animation.nim Sat Jun 08 15:19:58 2024 +0700 +++ b/semicongine/animation.nim Sat Jun 08 16:19:05 2024 +0700 @@ -139,7 +139,7 @@ proc NewAnimationState*[T](animation: Animation[T], initial = default(T)): AnimationState[T] = result = AnimationState[T](animation: animation, playing: false) - result.resetState(initial) + result.ResetState(initial) proc NewAnimationState*[T](value: T = default(T)): AnimationState[T] = NewAnimationState[T](NewAnimation[T]((state: AnimationState[T], dt: float32) => value, 0), initial = value) @@ -158,7 +158,7 @@ dec state.currentIteration # last iteration reached if state.currentIteration <= 0 and state.animation.iterations != 0: - state.stop() + state.Stop() # more iterations else: case state.animation.direction:
--- a/semicongine/engine.nim Sat Jun 08 15:19:58 2024 +0700 +++ b/semicongine/engine.nim Sat Jun 08 16:19:05 2024 +0700 @@ -149,7 +149,7 @@ checkVkResult engine.device.vk.vkDeviceWaitIdle() debug &"done loading scene '{scene.name}'" -proc UnLoadScene*(engine: var Engine, scene: Scene) = +proc UnloadScene*(engine: var Engine, scene: Scene) = debug &"unload scene '{scene.name}'" engine.renderer.get.Destroy(scene) @@ -184,7 +184,7 @@ func GetAspectRatio*(engine: Engine): float32 = engine.GetWindow().Size[0] / engine.GetWindow().Size[1] func ShowSystemCursor*(engine: Engine) = engine.window.ShowSystemCursor() func HideSystemCursor*(engine: Engine) = engine.window.HideSystemCursor() -func Fullscreen*(engine: Engine): bool = engine.Fullscreen +func Fullscreen*(engine: Engine): bool = engine.fullscreen proc `Fullscreen=`*(engine: var Engine, enable: bool) = if enable != engine.fullscreen: engine.fullscreen = enable