BSD: Add support (#140)

* BSD: Add support

* BSD: other fixes

There is still a bug when vgui haven't got text, maybe because of resources.

Also there is bug where when trying to start new game caption names shows wrong.

* BSD: Debugging

* BSD: modify preprocessor and fix windows

* BSD: Remove debugging and fix labels in gameui

* BSD: Remove disabling some DX9 commands

* BSD: Remove -g flag
This commit is contained in:
Er2
2022-11-24 22:04:29 +03:00
committed by GitHub
parent 807eaae850
commit 53bd92f7a8
49 changed files with 221 additions and 178 deletions
+3 -3
View File
@@ -1130,7 +1130,7 @@ void CBasePanel::UpdateBackgroundState()
vgui::GetAnimationController()->RunAnimationCommand( m_pGameLogo, "alpha", targetTitleAlpha, 0.0f, duration, AnimationController::INTERPOLATOR_LINEAR );
}
// Msg( "animating title (%d => %d at time %.2f)\n", m_pGameMenuButton->GetAlpha(), (int)targetTitleAlpha, engine->Time());
// Msg( "animating title (%d => %d at time %.2f)\n", m_pGameMenuButtons[0]->GetAlpha(), (int)targetTitleAlpha, engine->Time());
for ( i=0; i<m_pGameMenuButtons.Count(); ++i )
{
vgui::GetAnimationController()->RunAnimationCommand( m_pGameMenuButtons[i], "alpha", targetTitleAlpha, 0.0f, duration, AnimationController::INTERPOLATOR_LINEAR );
@@ -1650,7 +1650,7 @@ void CBasePanel::PerformLayout()
for ( int i=0; i<m_pGameMenuButtons.Count(); ++i )
{
// Get the size of the logo text
//int textWide, textTall;
// int textWide, textTall;
m_pGameMenuButtons[i]->SizeToContents();
//vgui::surface()->GetTextSize( m_pGameMenuButtons[i]->GetFont(), ModInfo().GetGameTitle(), textWide, textTall );
@@ -2220,7 +2220,7 @@ void CBasePanel::RunMenuCommand(const char *command)
RegCloseKey(hKey);
}
#elif defined( OSX ) || defined( LINUX )
#elif defined( OSX ) || defined( LINUX ) || defined(BSD)
FILE *fp = fopen( "/tmp/hl2_relaunch", "w+" );
if ( fp )
{
+1 -1
View File
@@ -161,7 +161,7 @@ bool CVGuiSystemModuleLoader::LoadPlatformModules(CreateInterfaceFn *factorylist
{
dllPath = it->GetString("dll_osx");
}
else if ( IsLinux() )
else if ( IsLinux() || IsBSD() )
{
dllPath = it->GetString("dll_linux");
}