Commit graph

5 commits

Author SHA1 Message Date
Bart Trzynadlowski 87de86f7d1 Crosshair: use actual adjusted viewport resolution (configuration resolution is not the same thing). Fixes crosshair alignment for resolutions with non-Model 3 aspect. 2023-03-18 10:00:28 -07:00
CapitaineSheridan abc2900770 m_crosshair is not needed and the config should be checked every frame because otherwise Alt-I command was broken (the number of crosshairs to render is mapped to a UI key) [Bart] 2023-03-13 20:18:51 -07:00
CapitaineSheridan a319bbee0c Better optimisations.
Moved all UI rendering from Main to CCrosshair.
Take care of syntax about crosshair style.
2023-03-13 20:18:51 -07:00
CapitaineSheridan b19fdb6a77 Change Media folder to Assets folder.
Naming variable convention.
Command line change -crosshair-style = vector|bmp.
Config ini variable change CrosshairStyle = vector|bmp.
CCrosshair::DrawCrosshair optimisation.
Modifying UpdateCrosshairs() to eliminate global variable.
2023-03-13 20:18:51 -07:00
CapitaineSheridan 1b066fe4b3 Crosshair refactor
-add a new separate class for crosshair
-crosshair coordinates are calculated by matrix instead of recreating every object at correct coordinates
-add ability to scale crosshair by dpi
-add ability to use bitmap crosshair (located in ./Media/). 32bits bmp format + alpha
-cmd line "-bitmapcrosshair" or "-vectorcrosshair" and/or BitmapCrosshair=0|1 in config file
-these changes are only for lost world game with Crosshairs=1|2|3

don't forget to copy the 2 crosshair images in Supermodel/Media folder
2023-03-13 20:18:51 -07:00