ValveSoftware / halflife

Half-Life 1 engine based games
Other
3.74k stars 630 forks source link

_setvideomode was never implemented into the game as still To-do #2298

Open metita opened 5 years ago

metita commented 5 years ago

According to https://developer.valvesoftware.com/wiki/Command_Line_Options and Goldsource Games -> Useful console variables -> +_setvideomode - To do

_setvideomode is not working on GoldSrc games or wasn't implemented on the game.

SamVanheer commented 5 years ago

_setvideomode is implemented and sets registry settings. This command is supposed to be followed by a _restart command to allow the game to reinitialize with the correct settings.

It is not possible to apply the settings without a restart because the older UI code is designed to work with the resolution used on startup.

metita commented 5 years ago

Is not working apparently, do you need to set it as 0 or 1? or any additional parameter?

kisak-valve commented 5 years ago

Looks like there are several to-do marked sections in that wiki article for parts that could use better documentation, and does not indicate that the function is unimplemented.

This is something to be resolved on the Wiki's side, not this issue tracker.

SamVanheer commented 5 years ago

_setvideomode takes between 2 and 3 arguments. At minimum the width and height of the window must be passed as integers, the bits per pixel can be passed as a third argument and defaults to 16 if not specified.

You shouldn't use this command directly, use the Video options or the -width and -height command line parameters. If you need a custom resolution use -forceres. If possible the game will use your custom resolution, otherwise it will use the first display mode returned by SDL.

metita commented 5 years ago

@kisak-valve feel free to close this if needed, add the correct label or move it to the correct site if you think this is not needed here.