[EXTENSION] Late Downloads
Late Downloads
What is this? This is a SourceMod extension that allows file transfers to players that are already in the game. How to build this? Just as any other AMBuild project:
How to use this? Simply copy the extension binary to the extensions folder and the include file into the scripting/include folder. Now just create a new plugin and include latedl.inc. Sample script PHP Code:
The extension exposes following cvars:
The first two cvars limit the maximal time that the download can take. The maximal duration (in seconds) is computed using following formula: maximalDelay / 1000 + (fileSizeInBytes * 8 ) / (minimalBandwidth * 1000) If the player fails to download the file in time, he's kicked. The last cvar kicks any player that rejects incoming files. Additional information
Sources and binaries Latest sources are availabe at github: https://github.com/jonatan1024/latedl Binaries for windows and linux should be availabe at the github releases page: https://github.com/jonatan1024/latedl/releases |
Re: [EXTENSION] Late Downloads
this plugin will work for download zip or rar archive?
|
Re: [EXTENSION] Late Downloads
Nope. Source don't supports zip archives.
|
Re: [EXTENSION] Late Downloads
This is pretty neat, wasn't aware it was possible!
I built it against TF2 with a few small changes: Code:
179c179 Seems like this would be very useful for downloading non-essential files. Edit: Actually, it seems it adds the files to the download list for new clients connecting, which means anyone connecting after a late download is added will still have to sit through the downloading of files. Wonder if there's a way around that? |
Re: [EXTENSION] Late Downloads
Quote:
|
Re: [EXTENSION] Late Downloads
Quote:
|
Re: [EXTENSION] Late Downloads
Quote:
Quote:
I might add a boolean parameter for cases when you don't need file consistency amongst the players and one more native for file removal from the download table. I'm curious - what exactly is your use case? How the fact that some players doesn't have the needed files doesn't break their experience? |
Re: [EXTENSION] Late Downloads
Quote:
For example as a donor perk on a server I play on, each player has a texture that floats above their head at the end of the round. These sorts of files would be fine to load as needed in the background since they aren't essential for players to have. |
Re: [EXTENSION] Late Downloads
Quote:
I'm not sure what the players that won't download the texture will see, my guess is pink-black checkerboard and console full of errors. :D Some network entity filtering should solve this quite easily tho. |
Re: [EXTENSION] Late Downloads
Change for latest version to build against TF2:
Code:
257,259c257 Or like this, but I dunno if there's a cleaner way to do this without inheriting: Code:
template< class T, class A = CUtlMemory<T> > |
All times are GMT -4. The time now is 16:57. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.