Skip to content

HLTV Changes for a smoother demo watching experience#1845

Merged
AdamTadeusz merged 14 commits intoNeotokyoRebuild:masterfrom
AdamTadeusz:343_fixDrawingCrosshairInHLTVAndDroneControlsInHLTV
Mar 19, 2026
Merged

HLTV Changes for a smoother demo watching experience#1845
AdamTadeusz merged 14 commits intoNeotokyoRebuild:masterfrom
AdamTadeusz:343_fixDrawingCrosshairInHLTVAndDroneControlsInHLTV

Conversation

@AdamTadeusz
Copy link
Contributor

@AdamTadeusz AdamTadeusz commented Mar 15, 2026

Description

Changes

  • Don't draw target crosshair when roaming in hltv, always draw own crosshair when roaming and cl_observercrosshair is set
  • Added drone movement to hltv
  • Added an option to switch to a spectate target when switching to in eye or chase cam view, and..
  • an option to change to either in eye or chase came view when changing the spectate target and not in one of the two
  • Fixed most of the new spectator commands
  • Fixed ghost beacons showing when roaming
  • Fixed in-eye view offset
  • Fixed camera fov getting stuck at a low value after spectating a dead player and going into free roam camera mode
  • SourceTV is now not considered a spectator by neobotmanager (if there are any bots on the server and sourcetv but no players, neobotmanager will start kicking bots if neo_bot_join_after_player is set)
  • Fixed the neo_fov and other missing convar value error

Things that I'm aware of that still need to be fixed (not in this PR)

  • player animations being choppy or downright broken when doing a lot of skipping
  • sometimes when one player shoots other players will light up like they're shooting even if they're not
  • round end victory music does not play in hltv
  • hltvcamera can spectate observers, not only spectators (good?) but also dead players (probably bad)

Toolchain

  • Windows MSVC VS2022

Linked Issues

@AdamTadeusz AdamTadeusz changed the title Don't draw target crosshair when roaming in hltv, always draw own crosshair if cl_observercrosshair is set, add drone movement to hltv Don't draw target crosshair when roaming in hltv, always draw own crosshair when roaming and cl_observercrosshair is set, add drone movement to hltv Mar 15, 2026
@AdamTadeusz AdamTadeusz changed the title Don't draw target crosshair when roaming in hltv, always draw own crosshair when roaming and cl_observercrosshair is set, add drone movement to hltv HLTV Changes for a smoother demo watching experience Mar 15, 2026
@AdamTadeusz AdamTadeusz requested a review from a team March 16, 2026 15:01
@sunzenshen sunzenshen requested a review from a team March 17, 2026 04:18
@AdamTadeusz AdamTadeusz added Tournament Priority Issues to be prioritized for the upcoming NT;RE tournament labels Mar 17, 2026
@AdamTadeusz
Copy link
Contributor Author

I noticed there were some other issues with the pr as well, namely:

  • When switching spectate mode to free cam, if my current spectate target (who I am now no longer following) died with cl_neo_hltvcamera_auto_observe_killer_if_observing_victim enabled, I would get moved to spectate the killer anyway. Fixed by adding extra checks for the current m_nCameraMode
  • I added a nullptr dereference to hud_crosshair
  • I never called SetLastKiller, instead unintentionally called SetLastAttacker in two places
  • There were some problems with the weapon viewmodel being very dark sometimes. I guess the workaround for viewmodels going dark when facing a wall breaks when watching a stv replay. I added a check to not do this workaround when watching a stv replay. I also noticed that the weapon world models, while looking better when dropped with a similar workaround, didn't look so good when held by players, so decided to only do that workaround for worldmodels if they aren't attached to anything.

Rainyan
Rainyan previously approved these changes Mar 17, 2026
Copy link
Contributor

@DESTROYGIRL DESTROYGIRL left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This introduces a bug where your crosshair remains visible after death in spectate. I have a demo of it happening if you would like

@AdamTadeusz
Copy link
Contributor Author

This introduces a bug where your crosshair remains visible after death in spectate. I have a demo of it happening if you would like

is this with cl_observercrosshair 1 ?

@DESTROYGIRL
Copy link
Contributor

This introduces a bug that makes my iq lower

@AdamTadeusz AdamTadeusz requested a review from DESTROYGIRL March 18, 2026 20:42
DESTROYGIRL
DESTROYGIRL previously approved these changes Mar 18, 2026
Copy link
Contributor

@DESTROYGIRL DESTROYGIRL left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a nit

Co-authored-by: DESTROYGIRL <toddlodyte44@outlook.com>
@DESTROYGIRL DESTROYGIRL requested a review from a team March 18, 2026 21:20
@AdamTadeusz AdamTadeusz merged commit 6d57318 into NeotokyoRebuild:master Mar 19, 2026
7 checks passed
@AdamTadeusz AdamTadeusz deleted the 343_fixDrawingCrosshairInHLTVAndDroneControlsInHLTV branch March 19, 2026 08:13
AdamTadeusz added a commit to AdamTadeusz/neo that referenced this pull request Mar 19, 2026
…#1845)

* init

* cl_observercrosshair is only for roaming observer crosshair

* makes most of the new spectate commands work in hltv

* fix beacons too

* view offsets, userid to entindex properly

* neobotmanager ignore sourcetv, fix rest spectate commands

* crosshair assert when spectating dead players

* float, call spectateChecks function

* gpGlobals->maxClients

* nits plus quick fixes plus viewmodel is really dark in stvdemos which i only now noticed

* don't move lighting origin of weapons attached to players

* should probably define this string somewhere else at this point

* revert changes to hud_crosshair trying to be smart about cl_observercrosshair

* Update src/game/shared/neo/neo_gamerules.cpp

Co-authored-by: DESTROYGIRL <toddlodyte44@outlook.com>

---------

Co-authored-by: DESTROYGIRL <toddlodyte44@outlook.com>
AdamTadeusz added a commit that referenced this pull request Mar 19, 2026
* Fix demoui smoother buttons being unreactive (#1842)

* Fix demoui smoother buttons being unreactive

* Fix wrong budget group

* Refactor

Improve code readability

* Server side second auto record command (#1855)

* working

* fix

* delay game_end to end of round

* not every comp game should necessarily be recorded

* rainfix

* Fix spec_next/prev not skipping dead players (#1856)

Fix a case where in server demos, spec_next/spec_prev does not correctly skip dead players.

* DebugDrawLine grenade trails for spectators and practicing (#1852)

* working using debugdralines

* clamp and float and stuff

* Fix env_sun being hidden when under the centre of view (#1839)

* Changing cl_neo_squad_hud_avatar_size updates star texture sizes immediately, also cl_neo_hud_centre convars (#1829)

* init

* also solve the woldpos marker centre sizes not updating automatically

* le epic linux fail

* maybe inline breaking it

* center -> centre, GetFloat, f

* HLTV Changes for a smoother demo watching experience (#1845)

* init

* cl_observercrosshair is only for roaming observer crosshair

* makes most of the new spectate commands work in hltv

* fix beacons too

* view offsets, userid to entindex properly

* neobotmanager ignore sourcetv, fix rest spectate commands

* crosshair assert when spectating dead players

* float, call spectateChecks function

* gpGlobals->maxClients

* nits plus quick fixes plus viewmodel is really dark in stvdemos which i only now noticed

* don't move lighting origin of weapons attached to players

* should probably define this string somewhere else at this point

* revert changes to hud_crosshair trying to be smart about cl_observercrosshair

* Update src/game/shared/neo/neo_gamerules.cpp

Co-authored-by: DESTROYGIRL <toddlodyte44@outlook.com>

---------

Co-authored-by: DESTROYGIRL <toddlodyte44@outlook.com>

---------

Co-authored-by: Rainyan <Rainyan@users.noreply.github.com>
Co-authored-by: DESTROYGIRL <toddlodyte44@outlook.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Tournament Priority Issues to be prioritized for the upcoming NT;RE tournament

Projects

None yet

4 participants