ikemen-engine / Ikemen-GO

An open-source fighting game engine that supports MUGEN resources.
https://ikemen-engine.github.io
Other
751 stars 127 forks source link

feat: expose current time to shaders #1974

Closed wily-coyote closed 3 months ago

wily-coyote commented 3 months ago

Some non-Ikemen shaders use time-based calculations.

This PR adds a shader input named "CurrentTime" that can be used in this fashion. Internally this uses glfw.GetTime(), so the input is an uniform float based on seconds.