Is it possible to draw the users crosshair?
Like, if i pick a scout, it disappears.
Is it possible to "force" the client to have a crosshair?
Cheers!
Draw Crosshair
Re: Draw Crosshair
i think the "crosshair-look" is clientside and forced by the weapon. you can only enable and disable it on the server , using HideHudFlag, but not switching it from one weapon to the other etc... and i guess that's what you were looking for...
( btw. messing with the inventory ( e.g. weapon ) settings got me banned by valve from using gameservers, so be careful - in case you were thinking of faking the weaponhandle to the client or w/e :P )
( btw. messing with the inventory ( e.g. weapon ) settings got me banned by valve from using gameservers, so be careful - in case you were thinking of faking the weaponhandle to the client or w/e :P )
Last edited by Speed0x on Tue May 29, 2018 2:31 pm, edited 2 times in total.
Re: Draw Crosshair
Hey,
I think theres currently no cvar which draws the crosshair for scouts or when you are disarmed.
But there are probably some try-around ways:
1. Create an Screenoverlay with a custom crosshair and send it to the player if he equiped that weapon
2. (FOR DISARMED ONLY) Give the player a weapon which shows crosshair and make it invinsible + block any interactions with it like shooting.
3. Send a Center TextMSG with a symbol like a cross or circle and position it into the middle of the screen.
I think theres currently no cvar which draws the crosshair for scouts or when you are disarmed.
But there are probably some try-around ways:
1. Create an Screenoverlay with a custom crosshair and send it to the player if he equiped that weapon
2. (FOR DISARMED ONLY) Give the player a weapon which shows crosshair and make it invinsible + block any interactions with it like shooting.
3. Send a Center TextMSG with a symbol like a cross or circle and position it into the middle of the screen.
Re: Draw Crosshair
yes you can use screenoverlay + .vmt but i think that is not auto-adjusting to screensize, so really ugly. would not recommend..
also, in case you are just doing this for fun, you can always just edit the existing clientside .vmt file for the scoutoverlay and change it to your likings :P, but that is changing clientside files and corrupts cache integrity with the game, so i would only do that for testings locally and change it back if you want to play online
also, in case you are just doing this for fun, you can always just edit the existing clientside .vmt file for the scoutoverlay and change it to your likings :P, but that is changing clientside files and corrupts cache integrity with the game, so i would only do that for testings locally and change it back if you want to play online
Re: Draw Crosshair
It's for a ServerSide mod.
Sadly the weapon_debug_spread_show 3 can't be forced by cmd usage because the client blocks it.
Sadly the weapon_debug_spread_show 3 can't be forced by cmd usage because the client blocks it.
Re: Draw Crosshair
Here's a simple and dirty way to get a crosshair on snipers (decompile's 3rd suggestion):
I can think of two ways around this. Using a custom particle with the screenoverlay option enabled or by creating an env_sprite and parenting it to the predicted_viewmodel. But I feel like the HudMsg way of doing it should be good enough.Speed0x wrote:yes you can use screenoverlay + .vmt but i think that is not auto-adjusting to screensize, so really ugly. would not recommend..
Return to “Plugin Development Support”
Who is online
Users browsing this forum: No registered users and 112 guests