Jump to content

dynamically setting monster animation frequency


iuqnay

Recommended Posts

i want to sync the monster animations to the music's bpm. is there a way to dynamically set animation frequency for monster idle/walk?

Share this post


Link to post

I've never tried but I'd imagine it should be possible to try and sync the given monster frames to the music using ANIMDEFS.

Besides trying to get the monster animation frame tics to the beat of the music, I think the hard part would be having the music or the monster animation start and restart at the same time, every time. eg when the level is restarted or when the monster dies, the music would need to start over as well as the animation. Unless your plan is for a cut scene or similar where the monster never dies and you only plan on a certain amount of frames to skip, speed up, or slow down.

Edited by Mr.Rocket

Share this post


Link to post
5 minutes ago, Mr.Rocket said:

I've never tried but I'd imagine it should be possible to try and sync the given monster frames to the music using ANIMDEFS.

Besides trying to get the monster animation frame tics to the beat of the music, I think the hard part would be having the music or the monster animation start and restart at the same time.

 

can you have an observable event fire every time the menu screen is resumed into gameplay? i think that is currently the hardest issue, since without the complication of menu screen playing music,  you could simply make midi length a multiple of every monsters unified total animation time

Share this post


Link to post
14 minutes ago, Mr.Rocket said:

when the monster dies, the music would need to start over as well as the animation.

 

sorry i wasnt clear, monster deaths wouldnt be in sync but their walk/idle anims would be, and the music is not dependent on any relationship. given the complexity of the edge cases, i think the best implementation would be to fire an observable event every downbeat, and setting a downstream listener that invalidates monster idle/walk animation cycles to frame 0, and setting their animation rates to a simple ratio of the midi bpm at the beginning of the map

Edited by iuqnay

Share this post


Link to post
Quote

can you have an observable event fire every time the menu screen is resumed into gameplay? i think that is currently the hardest issue, since without the complication of menu screen playing music,  you could simply make midi length a multiple of every monsters unified total animation time

 

You know, I think so. A lot of things can be achieved through scripts, and key bindings that may call a script.

But I admit I'm not the ACS script guru, I'm sure someone else will come along soon and have a better answer.

 

Quote

sorry i wasnt clear, monster deaths wouldnt be in sync but their walk/idle anims would be, and the music is not dependent on any relationship. given the complexity of the edge cases, i think the best implementation would be to fire an observable event every downbeat, and setting a downstream listener that invalidates monster idle/walk animation cycles to frame 0, and setting their animation rates to a simple ratio of the midi bpm at the beginning of the map

 

You maybe on to something there. I'd end up going back and forth with the animdefs.txt and level start with basic monster walk animation  many, many times before being satisfied with the timing, heh. 

Probably the easiest way to go about it is creating some music that could be in sync with the given animation of the monsters from the start.

At least from my stand point, I play drums. But that way, if the beat is already in sync with the current walking animation, then it would already allow you some areas for frame time manipulation, and perhaps have an imp do the shuffle for example between snare and bass drum kick etc. 

Edited by Mr.Rocket

Share this post


Link to post
15 hours ago, Mr.Rocket said:

 

You know, I think so. A lot of things can be achieved through scripts, and key bindings that may call a script.

But I admit I'm not the ACS script guru, I'm sure someone else will come along soon and have a better answer.

 

thanks, do you know where i can find documentation on acs and script hooks?

 

i took a look at https://doomwiki.org/wiki/ACS and it seems like the original Hexen scope falls outside of this use case, as it only supports OPEN, RESPAWN, DEATH, or ENTER. does anyone know where i can find documentation on some of the expanded acs descendants for zdoom or eternity?

Edited by iuqnay

Share this post


Link to post

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.   Restore formatting

  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.

×
×
  • Create New...