Counter-Strike 2 Update Adds Custom HUDs and Scripted Camera Control
The patch also expands bomb, movement, player-state, and debugging tools for custom map creators.

Valve has published a new Counter-Strike 2 update centered on map scripting, giving creators more tools for custom interfaces, scripted camera control, bomb interactions, and player movement.
The biggest addition is the custom_hud_layout entity, which lets scripted maps provide their own UI. Panel, Label, Image, and Button types are supported, along with CSS styling. The layouts also retain their state during tools mode reloads, although events and client-side scripting are not supported.
Map creators can also use cs_player_camera to control a player’s view without moving their pawn. The camera can be configured to let players look around from the scripted position. New scripting functions cover bomb planting and defusing, C4 timing, defuse targets, buy-menu status, movement types, camera access, and dedicated-server checks.
Several changes should make custom-map testing less painful. Initial script errors, unhandled promise rejections, and the column number for errors caught during the CompileModule step are now logged to the console. Valve also corrected event parameter types and deprecated the planter and defuser parameters from their respective bomb events.
Valve detailed the full set of changes in its Steam announcement.
Counter-Strike 2 Patch Notes
This update is almost entirely aimed at map scripting. It adds custom UI and camera systems, expands access to bomb and player state, and gives creators clearer error output when scripts fail to load or compile.
[ MAP SCRIPTING ]
- Added custom_hud_layout entity:
- custom_hud_layouts are the entry point for scripted maps to provide custom UI.
- Panel, Label, Image, and Button panel types are supported.
- Styling with css is supported.
- Events and client side scripting are not supported.
- Maintains state during tools mode reloads.
- Added cs_player_camera entity:
- Gives control of a player’s view without moving their pawn.
- Can be configured to let the player look around from the scripted position.
- Added Instance.Delay
- Added Instance.OnBombPlantStart
- Added Instance.OnBombPlantAbort
- Added Instance.OnBombDefuseStart
- Added Instance.OnBombDefuseAbort
- Added Instance.OnCustomHudClicked
- Added Instance.IsDedicatedServer
- Added Entity.Move
- Added Entity.GetMoveType
- Added Entity.SetMoveType
- Added CSPlayerPawn.GetC4
- Added CSPlayerPawn.GetDefuseTarget
- Added CSPlayerPawn.IsBuyMenuOpen
- Added CSPlayerPawn.GetCamera
- Added C4.GetPlantStartTime
- Added C4.GetPlantFinishTime
- Added C4.AbortPlant
- Added CustomHudLayout.SetHasClass
- Added CustomHudLayout.SetHasClassForPlayer
- Added CustomHudLayout.SetDialogVariableString
- Added CustomHudLayout.SetDialogVariableStringForPlayer
- Added CustomHudLayout.SetInputCaptureEnabled
- Added CustomHudLayout.IsInputCaptureEnabled
- Added CSPlayerCamera.IsEnabled
- Added CSPlayerCamera.SetEnabled
- Added CSPlayerCamera.SetIsControllingAngles
- Added enum CSMoveType
- Corrected types for some events where parameters were maybe undefined.
- Errors encountered during initial script run are now logged to the console.
- Unhandled promise rejections are now logged to the console.
- Added the column number to errors caught during the CompileModule step of script loading.
- Deprecated planter from Instance.OnBombPlant event
- Deprecated defuser from Instance.OnBombDefuse event
What do you think of these new map-scripting tools? Share your thoughts in the comments, and follow us on X, Bluesky, YouTube, Instagram, Steam, and Telegram.
Counter-Strike 2
Developed by Valve






