AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   General (https://forums.alliedmods.net/forumdisplay.php?f=58)
-   -   Pushing dynamic materials towards client while game is in progress (https://forums.alliedmods.net/showthread.php?t=336169)

stece 02-01-2022 05:01

Pushing dynamic materials towards client while game is in progress
 
Hey all,

I need some help and input.

We are creating minigames and want to show a leaderboard in the games. The scores are stored in an online web platform, so we are building it like this:

Every time a mini-game was played, we use a server command from a sourcemod plugin to push the results to the platform via a REST call. After which we pull the latest leaderboard data and then display it on the map.
(We basically read and change the display text of Vgui_world_text_panel entities.)

So we got part 1 up and running. Now part two would be to add the profile pictures of those players. And this is where I'm stuck.

Assuming we have a separate process where the web platform pushes the profile pics as VTF's to the csgo server via FTP.

In my head, we could then use https://developer.valvesoftware.com/...modify_control to switch the material of a small block on which we place the profile picture.
But how would this work with a server? Since the player doesn't have the VTF file yet on his/her computer. Can we do something with Sourcemod to push/cache the file towards the player while the game is in progress?

(Putting the materials of the profile pics in the BSP is not an option, as it would mean to predict all the profile pics while packaging the BSP. We also want to have new players instead of hardcoded players. :) )

greetz,
Stece

FroGeX 02-02-2022 14:24

Re: Pushing dynamic materials towards client while game is in progress
 
Here https://forums.alliedmods.net/showthread.php?t=305153

but you must force client to change their convar sv_allowupload to 1

stece 02-02-2022 15:23

Re: Pushing dynamic materials towards client while game is in progress
 
Quote:

Originally Posted by FroGeX (Post 2770323)
Here https://forums.alliedmods.net/showthread.php?t=305153

but you must force client to change their convar sv_allowupload to 1


Thanks for sharing that plugin!

Can you force a client to enable that convar using for example a point_client_command entity?

It would be sv_allowdownload right, not upload?


All times are GMT -4. The time now is 13:17.

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