Jump to content

UI animations


Recommended Posts

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?

  • Like 1
Link to comment
Share on other sites

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?

  • Like 1
Link to comment
Share on other sites

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.

 

Link to comment
Share on other sites

@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 by nani
  • Like 2
  • Thanks 2
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...