ModeAction OnSet(User* source, Channel* channel, std::string& parameter) override { ChannelSettings settings; if (!ParseSettings(source, parameter, settings)) { source->WriteNumeric(Numerics::InvalidModeParameter(channel, this, parameter, "Invalid repeat syntax. Syntax is: [~|*]<lines>:<sec>[:<difference>][:<backlog>]")); return MODEACTION_DENY; } if ((settings.Backlog > 0) && (settings.Lines > settings.Backlog)) { source->WriteNumeric(Numerics::InvalidModeParameter(channel, this, parameter, "Invalid repeat syntax. You can't set lines higher than backlog.")); return MODEACTION_DENY; } LocalUser* localsource = IS_LOCAL(source); if ((localsource) && (!ValidateSettings(localsource, channel, parameter, settings))) return MODEACTION_DENY; ext.set(channel, settings); return MODEACTION_ALLOW; }
void UGameUserSettings::ApplyNonResolutionSettings() { ValidateSettings(); bool bIsDirty = IsDirty(); EWindowMode::Type NewWindowMode = GetFullscreenMode(); { IConsoleVariable* CVar = IConsoleManager::Get().FindConsoleVariable(TEXT("r.FullScreenMode")); CVar->Set(NewWindowMode); } // Update vsync cvar { auto CVar = IConsoleManager::Get().FindConsoleVariable(TEXT("r.VSync")); CVar->Set(IsVSyncEnabled()); } // in init those are loaded earlier, after that we apply consolevariables.ini if(GEngine->IsInitialized()) { Scalability::SetQualityLevels(ScalabilityQuality); } IConsoleManager::Get().CallAllConsoleVariableSinks(); }
void UGameUserSettings::ApplyResolutionSettings(bool bCheckForCommandLineOverrides) { #if UE_SERVER return; #endif ValidateSettings(); EWindowMode::Type NewFullscreenMode = GetFullscreenMode(); // Request a resolution change RequestResolutionChange(ResolutionSizeX, ResolutionSizeY, NewFullscreenMode, bCheckForCommandLineOverrides); IConsoleManager::Get().CallAllConsoleVariableSinks(); }
void UGameUserSettings::ApplyNonResolutionSettings() { ValidateSettings(); bool bIsDirty = IsDirty(); EWindowMode::Type NewWindowMode = GetFullscreenMode(); // Update vsync cvar { FString ConfigSection = TEXT("SystemSettings"); #if WITH_EDITOR if (GIsEditor) { ConfigSection = TEXT("SystemSettingsEditor"); } #endif int32 VSyncValue = 0; if (GConfig->GetInt(*ConfigSection, TEXT("r.Vsync"), VSyncValue, GEngineIni)) { // VSync was already set by system settings. We are capable of setting it here. } else { static auto CVar = IConsoleManager::Get().FindConsoleVariable(TEXT("r.VSync")); CVar->Set(IsVSyncEnabled(), ECVF_SetByGameSetting); } } if (!IsRunningDedicatedServer()) { // Update MaxFPS cvar static IConsoleVariable* MaxFPSCVar = IConsoleManager::Get().FindConsoleVariable(TEXT("t.MaxFPS")); if (ensure(MaxFPSCVar) && (FrameRateLimit >= 0.0f)) { MaxFPSCVar->Set(FrameRateLimit, ECVF_SetByGameSetting); } } // in init those are loaded earlier, after that we apply consolevariables.ini if(GEngine->IsInitialized()) { Scalability::SetQualityLevels(ScalabilityQuality); } IConsoleManager::Get().CallAllConsoleVariableSinks(); }
void UGameUserSettings::ApplyResolutionSettings(bool bCheckForCommandLineOverrides) { ValidateSettings(); EWindowMode::Type NewFullscreenMode = GetFullscreenMode(); { IConsoleVariable* CVar = IConsoleManager::Get().FindConsoleVariable(TEXT("r.FullScreenMode")); CVar->Set(NewFullscreenMode); } // Request a resolution change RequestResolutionChange(ResolutionSizeX, ResolutionSizeY, NewFullscreenMode, bCheckForCommandLineOverrides); IConsoleManager::Get().CallAllConsoleVariableSinks(); SaveSettings(); }
PLBroadcastDef::PLBroadcastDef( const char* setupFileName, char *destinationIP, Bool16 debug ) : mDestAddress(destinationIP) , mOrigDestAddress(NULL) , mBasePort(NULL) , mPlayMode(NULL) // removed at build 12 , mLimitPlay(NULL) , mLimitPlayQueueLength(0) , mPlayListFile(NULL) , mSDPFile(NULL) , mLogging(NULL) , mLogFile(NULL) , mSDPReferenceMovie( NULL ) , mCurrentFile( NULL ) , mUpcomingFile( NULL ) , mReplaceFile( NULL ) , mStopFile( NULL ) , mInsertFile( NULL ) , mShowCurrent( NULL ) , mShowUpcoming( NULL ) , mTheSession( NULL ) , mIgnoreFileIP(false) , mMaxUpcomingMovieListSize(NULL) , mDestSDPFile(NULL) , mStartTime(NULL) , mEndTime(NULL) , mIsDynamic(NULL) , mName( NULL) , mPassword( NULL) , mTTL(NULL) , mRTSPPort(NULL) , mPIDFile(NULL) , mClientBufferDelay(NULL) , mParamsAreValid(false) , mInvalidParamFlags(kInvalidNone) { if (!setupFileName && !destinationIP) { this->SetDefaults( NULL ); qtss_printf( "default settings\n" ); this->ShowSettings(); return; } fDebug = debug; if (destinationIP != NULL) //we were given an IP to use mIgnoreFileIP = true; Assert( setupFileName ); if (setupFileName ) { int err = -1; if ( !this->SetDefaults( setupFileName ) ) { err = ::ParseConfigFile( false, setupFileName, ConfigSetter, this ); } if ( !err ) { mParamsAreValid = true; } ValidateSettings(); } }