Reset view
This commit is contained in:
parent
2a302f7b1d
commit
07732bd2ae
3 changed files with 26 additions and 6 deletions
|
|
@ -189,3 +189,11 @@ animation_draw :: proc(animation: Animation, global_transform: mat3) {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
animation_get_center :: proc(animation: Animation) -> v2 {
|
||||
switch animation.type {
|
||||
case .Rectangle:
|
||||
return linalg.lerp(animation.shapes.rectangle.tl, animation.shapes.rectangle.br, v2(0.5))
|
||||
}
|
||||
unreachable()
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue