Garry's Mod

Garry's Mod

ПОМЕР (Atomic Heart Death Screen)
Denne tråd er blevet låst
ZakeJoonson 13. juli 2021 kl. 0:58
Changing the text for a Server
Is there a way to force the text to be the same for everyone on a server?
< >
Viser 1-7 af 7 kommentarer
Nahno 28. juli 2021 kl. 3:42 
idk
Nahno 28. juli 2021 kl. 3:43 
probably console
Nahno 27. aug. 2021 kl. 4:11 
person who made this mod said u can do it via convar
WeirdCat 22. okt. 2021 kl. 4:13 
2
Sure. All you need to do is create a lua file in garrysmod/lua/autorun and add a hook that will execute the needed commands on client when they spawn for the first time.

Here's an example of how I made it, you can basically copypaste the code

if SERVER then hook.Add("PlayerInitialSpawn", "ForceDeathScreenSettings", function(ply) ply:ConCommand("cl_pomer_text you died") end) end

here are the other convars of the addon in case you want to use them also
"cl_pomer" = "1"
"cl_pomer_col_b" = "30"
"cl_pomer_col_bg_b" = "30"
"cl_pomer_col_bg_g" = "36"
"cl_pomer_col_bg_r" = "255"
"cl_pomer_col_g" = "36"
"cl_pomer_col_r" = "186"
"cl_pomer_sound" = "1"
"cl_pomer_stopsound" = "1"
"cl_pomer_text" = ""
"cl_pomer_time_mult" = "1"
"sv_pomer_time" = "0"
"sv_pomer_time_mult" = "1"
YuRaNnNzZZ  [udvikler] 8. mar. 2024 kl. 13:01 
Oprindeligt skrevet af WeirdCat:
Sure. All you need to do is create a lua file in garrysmod/lua/autorun and add a hook that will execute the needed commands on client when they spawn for the first time.

Here's an example of how I made it, you can basically copypaste the code

if SERVER then hook.Add("PlayerInitialSpawn", "ForceDeathScreenSettings", function(ply) ply:ConCommand("cl_pomer_text you died") end) end
overrding user's personal settings is a ♥♥♥♥♥♥ thing to do

if you do that, you are a terrible server owner who should be never allowed to own/operate a server
ZakeJoonson 8. mar. 2024 kl. 19:14 
:steamsalty: 3 years late to this conversation lmao
Sidst redigeret af ZakeJoonson; 8. mar. 2024 kl. 19:15
< >
Viser 1-7 af 7 kommentarer
Per side: 1530 50