Raised This Month: $51 Target: $400
 12% 

"mp3 play" Limited in usage?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
TheWhitesmith
Senior Member
Join Date: Oct 2017
Location: Morocco :c
Old 11-01-2017 , 13:50   "mp3 play" Limited in usage?
Reply With Quote #1

is the mp3 command limited in usage? I mean is there a client-side limit for this? (x usage per session). I am running a server and I use "mp3 play" 4 or 5times everyround, at some time, the command stops working (for everybody).
TheWhitesmith is offline
PRoSToTeM@
Veteran Member
Join Date: Jan 2010
Location: Russia, Ivanovo
Old 11-01-2017 , 19:29   Re: "mp3 play" Limited in usage?
Reply With Quote #2

There is a limit for 200 (minus 29 standard files) loaded .mp3 files per game execution.
__________________
PRoSToTeM@ is offline
Send a message via ICQ to PRoSToTeM@ Send a message via Skype™ to PRoSToTeM@
KiLLeR.
Senior Member
Join Date: Jul 2014
Location: Bulgaria
Old 11-01-2017 , 20:14   Re: "mp3 play" Limited in usage?
Reply With Quote #3

So if I understand you correctly, .mp3 files can be executed maximum 171 times per map?! Or you want to say maximum 171 different .mp3 files can be loaded (and executed/played as many times as you want) per map?!

Last edited by KiLLeR.; 11-01-2017 at 20:14.
KiLLeR. is offline
PRoSToTeM@
Veteran Member
Join Date: Jan 2010
Location: Russia, Ivanovo
Old 11-02-2017 , 05:37   Re: "mp3 play" Limited in usage?
Reply With Quote #4

Quote:
Originally Posted by KiLLeR. View Post
Or you want to say maximum 171 different .mp3 files can be loaded (and executed/played as many times as you want) per map?!
This. But not per map. Per single game execution (from game launch to exit from the game).
__________________
PRoSToTeM@ is offline
Send a message via ICQ to PRoSToTeM@ Send a message via Skype™ to PRoSToTeM@
aron9forever
Veteran Member
Join Date: Feb 2013
Location: Rromania
Old 11-02-2017 , 08:15   Re: "mp3 play" Limited in usage?
Reply With Quote #5

Quote:
Originally Posted by PRoSToTeM@ View Post
There is a limit for 200 (minus 29 standard files) loaded .mp3 files per game execution.
when is an mp3 "loaded", when precaching or when it is first played?

please answer these:

for all, assume client just started up and no mp3 played yet

plugin has 5 mp3 files that are precached, only one of them will play when connecting, selected randomly
the client doesn't have the files and downloads them
a) client loads 5 files because of precache
b) client loads 1 file after precaching, loading sound

plugin has 5 mp3 files that are precached, only one of them will play when connecting, selected randomly
the client already has the files before connecting
a) client loads 5 files because of precache
b) client loads 1 file, loading sound

plugin has 5 mp3 files that are not precached, only one of them will play when connecting, selected randomly
the client already has the files before connecting
a) client loads 5 files because ???(I guess not)
b) client loads 1 file when one of them, loading sound

Don't mind the example, I'm not asking for loading sound, just needed a quick way to make sure I understand how it works for other occasions
__________________
Meanwhile, in 2050:
Quote:
Originally Posted by aron9forever
useless small optimizations
Quote:
Originally Posted by Black Rose View Post
On a map that is 512x512x128 units you end up with 3,355,443,200,000 different "positions". To store each one of those positions individually in the variable "user_or" you need 12 terabytes of memory.

Last edited by aron9forever; 11-02-2017 at 08:15.
aron9forever is offline
TheWhitesmith
Senior Member
Join Date: Oct 2017
Location: Morocco :c
Old 11-02-2017 , 12:55   Re: "mp3 play" Limited in usage?
Reply With Quote #6

Personally I dont think the client should have the sound files precached to play them, you can check this just by running the "mp3 play" or "spk" commands when disconnected from a server. Also the client cant precache every single sound file so by executing these command you can be sure it's not precached (Maybe sounds are precached when it comes to MAP Files, but not else)
Correct me if I'm wrong please.
TheWhitesmith is offline
TheWhitesmith
Senior Member
Join Date: Oct 2017
Location: Morocco :c
Old 11-02-2017 , 13:02   Re: "mp3 play" Limited in usage?
Reply With Quote #7

So there is an mp3 limit per game execution, is it the same for wav commands?
TheWhitesmith is offline
PRoSToTeM@
Veteran Member
Join Date: Jan 2010
Location: Russia, Ivanovo
Old 11-02-2017 , 13:11   Re: "mp3 play" Limited in usage?
Reply With Quote #8

Quote:
Originally Posted by aron9forever View Post
when is an mp3 "loaded", when precaching or when it is first played?
When it is first played.
Quote:
Originally Posted by aron9forever View Post
please answer these:
bbb
__________________
PRoSToTeM@ is offline
Send a message via ICQ to PRoSToTeM@ Send a message via Skype™ to PRoSToTeM@
aron9forever
Veteran Member
Join Date: Feb 2013
Location: Rromania
Old 11-02-2017 , 13:39   Re: "mp3 play" Limited in usage?
Reply With Quote #9

Quote:
Originally Posted by PRoSToTeM@ View Post
When it is first played.

bbb
thank you

Quote:
Originally Posted by TheWhitesmith View Post
Personally I dont think the client should have the sound files precached to play them, you can check this just by running the "mp3 play" or "spk" commands when disconnected from a server. Also the client cant precache every single sound file so by executing these command you can be sure it's not precached (Maybe sounds are precached when it comes to MAP Files, but not else)
Correct me if I'm wrong please.
the only stuff you can get away with not precaching is both wav and mp3 but only if you play them with spk/speak or mp3 play

this is not a good idea for 99.9% of the cases though because the clients will also not download anything and will just display an error in console when trying. This only works if you can be SURE that the client has the file (for example, creating a custom game client for a mod)

it's also a nice idea if you want to have a server with many sounds but you have too many resources, you can make some of the non-critical sounds optional and advise players who want the full experience to download a pack with all the sounds

if you try to play a wav sound that is not precached with sound_emit then the server will crash
__________________
Meanwhile, in 2050:
Quote:
Originally Posted by aron9forever
useless small optimizations
Quote:
Originally Posted by Black Rose View Post
On a map that is 512x512x128 units you end up with 3,355,443,200,000 different "positions". To store each one of those positions individually in the variable "user_or" you need 12 terabytes of memory.
aron9forever is offline
PRoSToTeM@
Veteran Member
Join Date: Jan 2010
Location: Russia, Ivanovo
Old 11-02-2017 , 13:50   Re: "mp3 play" Limited in usage?
Reply With Quote #10

Quote:
Originally Posted by aron9forever View Post
if you try to play a wav sound that is not precached with sound_emit then the server will crash
It won't crash, but will print in the console that sound is not precached.
__________________
PRoSToTeM@ is offline
Send a message via ICQ to PRoSToTeM@ Send a message via Skype™ to PRoSToTeM@
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 03:30.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode