# How to call fmod studio markers in my script?

**URL:** <https://qa.fmod.com/t/how-to-call-fmod-studio-markers-in-my-script/17152>\
**Category:** FMOD Engine\
**Tags:** cpp\
**Created:** [May 4, 2021, 6:47am UTC](https://qa.fmod.com/t/how-to-call-fmod-studio-markers-in-my-script/17152 "2021-05-04T06:47:29Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Louca](https://avatars.discourse-cdn.com/v4/letter/l/2acd7d/32.png) [@Louca](https://qa.fmod.com/u/Louca)\
**Post date:** [May 4, 2021, 6:47am UTC](https://qa.fmod.com/t/how-to-call-fmod-studio-markers-in-my-script/17152/1 "2021-05-04T06:47:29Z")

</div>

Hello,  
I’d like to do a basic rhythm game and my goal would be to put two markers between the note to have a margin for error.  
The problem is that I can’t get the markers in fmod studio.

I tried FMOD.STUDIO\_EVENT\_CALLBACK\_TIMELINE\_MARKER, but it gives me the type(2048 or 0x00000800).  
How to get the markers in fmod and use them?  
Thanks for your future answer

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/fmod/original/2X/2/2915a76c7b6fc83f033b04880cf6fb157794fae1.png)

Louca

---

<div class="post-metadata">

**Author:** ![joseph](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/joseph/32/264_2.png) [@joseph](https://qa.fmod.com/u/joseph)\
**Post date:** [May 5, 2021, 1:58am UTC](https://qa.fmod.com/t/how-to-call-fmod-studio-markers-in-my-script/17152/2 "2021-05-05T01:58:38Z")

</div>

[`FMOD_STUDIO_EVENT_CALLBACK_TIMELINE_MARKER`](https://www.fmod.com/resources/documentation-api?version=2.2&page=studio-api-eventinstance.html#fmod_studio_event_callback_timeline_marker) is called whenever the playback position passed a named timeline marker. You can check [`FMOD_STUDIO_TIMELINE_MARKER_PROPERTIES`](https://www.fmod.com/resources/documentation-api?version=2.2&page=studio-api-eventinstance.html#fmod_studio_timeline_marker_properties) to find your markers’ names and positions. With this information and the position of the timeline playback position, you should have all the information you need.

---

<div class="post-metadata">

**Author:** ![Louca](https://avatars.discourse-cdn.com/v4/letter/l/2acd7d/32.png) [@Louca](https://qa.fmod.com/u/Louca)\
**Post date:** [May 5, 2021, 9:18am UTC](https://qa.fmod.com/t/how-to-call-fmod-studio-markers-in-my-script/17152/3 "2021-05-05T09:18:21Z")

</div>

Mmmmmhh, strange.  
I print FMOD\_STUDIO\_EVENT\_CALLBACK\_TIMELINE\_MARKER and as soon as I compile, it prints me 2048 to infinity.  
Is there a reason?

---

<div class="post-metadata">

**Author:** ![joseph](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/joseph/32/264_2.png) [@joseph](https://qa.fmod.com/u/joseph)\
**Post date:** [May 6, 2021, 5:20am UTC](https://qa.fmod.com/t/how-to-call-fmod-studio-markers-in-my-script/17152/4 "2021-05-06T05:20:31Z")

</div>

> [@Louca](#):
>
> I print FMOD\_STUDIO\_EVENT\_CALLBACK\_TIMELINE\_MARKER and as soon as I compile, it prints me 2048 to infinity.

I’m not sure I understand. Why are you printing FMOD\_STUDIO\_EVENT\_CALLBACK\_TIMELINE\_MARKER?

When you check [`FMOD_STUDIO_TIMELINE_MARKER_PROPERTIES`](https://www.fmod.com/resources/documentation-api?version=2.2&page=studio-api-eventinstance.html#fmod_studio_timeline_marker_properties), do you get the name and position of the marker?

---

<div class="post-metadata">

**Author:** ![Louca](https://avatars.discourse-cdn.com/v4/letter/l/2acd7d/32.png) [@Louca](https://qa.fmod.com/u/Louca)\
**Post date:** [May 6, 2021, 12:09pm UTC](https://qa.fmod.com/t/how-to-call-fmod-studio-markers-in-my-script/17152/5 "2021-05-06T12:09:53Z")

</div>

I’m sorry if I’m talking nonsense.  
I’ve been learning to use it since Friday, so I’m new.

When I check with FMOD\_STUDIO\_TIMELINE\_MARKER\_PROPERTIES(with a print), it stays nil when you pass the marker.  
I guess I have to check otherwise, but how?

---

<div class="post-metadata">

**Author:** ![joseph](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/joseph/32/264_2.png) [@joseph](https://qa.fmod.com/u/joseph)\
**Post date:** [May 13, 2021, 6:14am UTC](https://qa.fmod.com/t/how-to-call-fmod-studio-markers-in-my-script/17152/6 "2021-05-13T06:14:48Z")

</div>

Are you able to post the code you’re using to get the timeline marker properties?
