Is there anyway to run a function at a certain date and time? For example, the game would run a certain function in 5 days and then would not run the function again after that point in time.
Use tick() or os.time() to set up a function to be working in N days, here is a tutorial from AlvinBlox -
The linked tutorial will help you figure out how to make real-time events, with some configuration, you can set up a function to occur in N days/hours ,etc.