Event movement timing

● ARCHIVED · READ-ONLY
Started by AaronTrip 5 posts View original ↗
  1. Hi! I'm trying to make a simple guitar hero like mini game right now. basically i have some events that spawn at the bottom of the screen and they move up towards a horizontal bar at the top. The player has the control to by pressing buttons to make the events dissapear when they hit that bar (similar to the guitar hero type runway). So my question is is there a good way to figure out the exact amount of time it takes an event to move from spot A to B at a specific speed? I am trying to sync the events hitting the bar with a song that hasn't been made yet, so if i can figure out how fast the event moves then the song will be made with a corresponding beats per minute. I know this is a somewhat "out there" question, but any info helps. Thanks!!
  2. Record it on a video, then open it in a video editor.
  3. Let's take a breakdown:
    • Game runs at 60 frame per second. Music plays in BPM.
    • For example 120 BPM means, 120 beats per minute. One minute is 60 seconds.
    • 120/60 = 2 beats per second. So every 30 frames = 1 beat.
    • However, that is if the music is 120 BPM. There're various BPM that many music used. Some user 140, some used 155, some even used 180. Do your math.
    • To add things. BPM is counted using 1/4 length note. Most of songs use 4/4 beat, which four beats is considered one bar. And music is not only use 1/4 note length, but also 1/8, 1/16, etc. Which makes 1/8 length note is equal as 15 frames per beat in 120 BPM.
    • Conclusion, using FPS wasn't a right choice. What you gonna use is to use delta time (time passed between frames), if the delta time is bigger than the gap between notes, you can trigger the notes using correct button. Which it leads into using either plugins command, or a full separated plugin to handle rhythm game.
    • The problem then arise, how to extend the timing window? Hitting an exact 1 frame between 60 frames within one second is extremely difficult. So you gonna need to extend the tolerance frames. Which idk how to do this yet.
    TLDR: It isn't as easy as it seems.
    Do you know music theory? Do you know programming knowledge?
  4. @AaronTrip
    event movement is controlled by two values: speed and frequency
    And most people who want to sync movement are forgetting what frequency does...

    speed determines how long it takes the event to move from one position in the grid to the next IF IT MOVES.
    frequency determines the probability if the event should move or if it should wait.

    frequency is a random effect (when to wait) that you can't determine by eventing alone.
    So the solution if timing and sync is critical is to set frequency to max (which means that the event moves every chance it gets) and then reduce the movement speed to slow the event down if that is too fast.
    If frequency is slower than max the wait-skips will break any synchronisation between different events.
  5. TheoAllen said:
    Let's take a breakdown:
    • Game runs at 60 frame per second. Music plays in BPM.
    • For example 120 BPM means, 120 beats per minute. One minute is 60 seconds.
    • 120/60 = 2 beats per second. So every 30 frames = 1 beat.
    • However, that is if the music is 120 BPM. There're various BPM that many music used. Some user 140, some used 155, some even used 180. Do your math.
    • To add things. BPM is counted using 1/4 length note. Most of songs use 4/4 beat, which four beats is considered one bar. And music is not only use 1/4 note length, but also 1/8, 1/16, etc. Which makes 1/8 length note is equal as 15 frames per beat in 120 BPM.
    • Conclusion, using FPS wasn't a right choice. What you gonna use is to use delta time (time passed between frames), if the delta time is bigger than the gap between notes, you can trigger the notes using correct button. Which it leads into using either plugins command, or a full separated plugin to handle rhythm game.
    • The problem then arise, how to extend the timing window? Hitting an exact 1 frame between 60 frames within one second is extremely difficult. So you gonna need to extend the tolerance frames. Which idk how to do this yet.
    TLDR: It isn't as easy as it seems.
    Do you know music theory? Do you know programming knowledge?

    I know a bit of both, less music theory. Currently the way the mechanic is setup is that it will trigger a success if you have the key held down, this was to reduce difficulty as I figured the game would be pretty hard if the tirgger had to be exact.