Make PlayAudioStreamForPlayer start at x time?
#1

Hi guys,
I'm working in a little script that plays mp3 files from my host on my samp server, and I would like to know, if there's any way to make the music start at time 1:00 for example, and not at 0:00.
I'm using PlayAudioStreamForPlayer, I hope someone can help me with this.

Thanks
Reply
#2

Have you got a time system in your script mate?
Reply
#3

Yes I do have a time system, how can that help me mate?
Reply
#4

Well; do you have "UpdateTime" or a timer for updating the clock?

Also; variables?

It's so then I can get it to check the time it's calling.
Reply
#5

I have a variable with the time that the music should start already defined, I just need to make it start at that time.
Reply
#6

I mean, have you got a time system in your script already that shows in a textdraw/gametext?

EG: 00:00, 00:01... continuing.

Like; have you got
pawn Код:
new hour, minute, second;
or something?
Reply
#7

Yes, I do have that as well, how can that helps me?
Reply
#8

Can you post all code what includes them variables here in [pawn] tags so I can take a look and see if it can be implemented through that.

Thanks.
Reply
#9

I'm just using that to give paycheck at minute=0 and second=0, onplayerupdate, I'm sure if you can give me a tip I'll be able to implement it
Reply
#10

Well; use this in that area

pawn Код:
if(hour == 12 && minute == 30)
{
    //the code
}
This will set it to play at 12:30 in game time.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)