Vantha Posted September 26 Report Share Posted September 26 To what extent are UI animations possible with the Pyrogenesis engine? I know by modifying the size attribute on each tick it is possible to achieve basic movement, stretching, and scaling animations. But what about more complex effects? For example, is there support for something like spritesheets? 1 Quote Link to comment Share on other sites More sharing options...
Vantha Posted September 27 Author Report Share Posted September 27 I suppose storing the individual frames of the animation in a series of png files would work? And simply assigning the next one on each tick? How hard would that go on performance? Quote Link to comment Share on other sites More sharing options...
Vantha Posted September 28 Author Report Share Posted September 28 Hmm, I was thinking about it in regards to the encyclopedia - where maximum performance efficiency might not even be of high priority. 21 hours ago, Vantha said: I suppose storing the individual frames of the animation in a series of png files would work? And simply assigning the next one on each tick? Would this be worth giving a shot? Or is storing this many high-res images for just one single animation simply a no-go? I'm surely not the first one wondering about this, right? 1 Quote Link to comment Share on other sites More sharing options...
Stan` Posted September 30 Report Share Posted September 30 On 28/09/2024 at 12:11 AM, Vantha said: I suppose storing the individual frames of the animation in a series of png files would work? And simply assigning the next one on each tick? How hard would that go on performance? Depends on the size of the images. Quote Link to comment Share on other sites More sharing options...
Vantha Posted September 30 Author Report Share Posted September 30 5 hours ago, Stan` said: Depends on the size of the images. Quite large probably. Multiple hundreds of pixels in width and height. Quote Link to comment Share on other sites More sharing options...
nani Posted September 30 Report Share Posted September 30 (edited) @Vantha That is exactly what I wondered years ago. So I created an animation "framework" that works on-top of the UI code. If you know some javascript I'm sure you can extend what I did to support your use case of animated sprites. Here is the link to the code. https://github.com/nanihadesuka/autociv/blob/master/gui/common/animateGUIManager.js You are free to modify however you want. A good thing about the link, the class list the full extend of what you can possible change UI wise from the JS side. In my time, I did some deep research in the c++ UI engine code. (maybe some things have changed in 4 years) Edited September 30 by nani 2 2 Quote Link to comment Share on other sites More sharing options...
Vantha Posted September 30 Author Report Share Posted September 30 @nani Cool. Looks very well structured and thought-through. And pretty versatile. I'll see what I can do with it. I would love to see the entire framework getting added to the main game. Thanks for telling me about it. 1 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.