Calendar with custom post type loop

I made a calendar based on this code: https://codingwithsara.com/how-to-code-calendar-in-php/#Sample_Code.

I want to display WordPress posts from custom post type (Events). Does anyone know how to connect the loop with this calendar and display events on days based on metabox "event_date_start"?

Have a good day!

How many English words
do you know?
Test your English vocabulary size, and measure
how many words do you know
Online Test
Powered by Examplum