Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local Fluent = loadstring(game:HttpGet("https://github.com/dawid-scripts/Fluent/releases/latest/download/main.lua"))()
- local SaveManager = loadstring(game:HttpGet("https://raw.githubusercontent.com/dawid-scripts/Fluent/master/Addons/SaveManager.lua"))()
- local InterfaceManager = loadstring(game:HttpGet("https://raw.githubusercontent.com/dawid-scripts/Fluent/master/Addons/InterfaceManager.lua"))()
- local Window = Fluent:CreateWindow({
- Title = "1qlua графика",
- SubTitle = "графика от 1qlua V1.1",
- TabWidth = 160,
- Size = UDim2.fromOffset(600, 500),
- Acrylic = true,
- Theme = "Dark",
- MinimizeKey = Enum.KeyCode.LeftControl
- })
- local Tabs = {
- Graphics = Window:AddTab({ Title = "графика", Icon = "monitor" }),
- Settings = Window:AddTab({ Title = "Settings", Icon = "settings" })
- }
- local Options = Fluent.Options
- local GraphicsEnhancer = {
- CurrentSettings = {
- Enabled = true,
- Quality = "High",
- Bloom = {
- Enabled = true,
- Intensity = 0.85,
- Size = 28,
- Threshold = 0.75
- },
- ColorCorrection = {
- Enabled = true,
- Brightness = 0.12,
- Contrast = 0.25,
- Saturation = 0.15,
- TintColor = Color3.fromRGB(255, 224, 224)
- },
- DepthOfField = {
- Enabled = false,
- FarIntensity = 0.35,
- FocusDistance = 12,
- InFocusRadius = 18,
- NearIntensity = 0.55
- },
- SunRays = {
- Enabled = true,
- Intensity = 0.25,
- Spread = 0.9
- },
- Atmosphere = {
- Enabled = true,
- Density = 0.3,
- Offset = 0.25,
- Color = Color3.fromRGB(200, 220, 255),
- Decay = Color3.fromRGB(255, 180, 150),
- Haze = 0.1
- },
- Lighting = {
- GlobalShadows = true,
- Brightness = 2.1,
- OutdoorAmbient = Color3.fromRGB(135, 135, 135),
- ClockTime = 7.4,
- Latitude = 45.5,
- Exposure = 0.28,
- ShadowSoftness = 0.2,
- FogEnabled = true,
- FogStart = 100,
- FogEnd = 500
- }
- }
- }
- function GraphicsEnhancer.applySettings()
- if not GraphicsEnhancer.CurrentSettings.Enabled then return end
- local lighting = game:GetService("Lighting")
- -- Clear existing effects safely
- for _, effect in ipairs(lighting:GetChildren()) do
- if effect:IsA("PostEffect") or effect:IsA("Atmosphere") then
- effect:Destroy()
- end
- end
- -- Apply quality presets
- local quality = GraphicsEnhancer.CurrentSettings.Quality
- if quality == "Low" then
- GraphicsEnhancer.CurrentSettings.Bloom.Enabled = false
- GraphicsEnhancer.CurrentSettings.DepthOfField.Enabled = false
- GraphicsEnhancer.CurrentSettings.SunRays.Enabled = false
- elseif quality == "Medium" then
- GraphicsEnhancer.CurrentSettings.Bloom.Intensity = 0.7
- GraphicsEnhancer.CurrentSettings.Bloom.Size = 24
- elseif quality == "Ultra" then
- GraphicsEnhancer.CurrentSettings.Bloom.Intensity = 0.95
- GraphicsEnhancer.CurrentSettings.Bloom.Size = 32
- GraphicsEnhancer.CurrentSettings.DepthOfField.Enabled = true
- end
- -- Create effects with proper parenting
- if GraphicsEnhancer.CurrentSettings.Bloom.Enabled then
- local bloom = Instance.new("BloomEffect", lighting)
- bloom.Intensity = GraphicsEnhancer.CurrentSettings.Bloom.Intensity
- bloom.Size = GraphicsEnhancer.CurrentSettings.Bloom.Size
- bloom.Threshold = GraphicsEnhancer.CurrentSettings.Bloom.Threshold
- end
- if GraphicsEnhancer.CurrentSettings.ColorCorrection.Enabled then
- local colorCorrection = Instance.new("ColorCorrectionEffect", lighting)
- colorCorrection.Brightness = GraphicsEnhancer.CurrentSettings.ColorCorrection.Brightness
- colorCorrection.Contrast = GraphicsEnhancer.CurrentSettings.ColorCorrection.Contrast
- colorCorrection.Saturation = GraphicsEnhancer.CurrentSettings.ColorCorrection.Saturation
- colorCorrection.TintColor = GraphicsEnhancer.CurrentSettings.ColorCorrection.TintColor
- end
- if GraphicsEnhancer.CurrentSettings.DepthOfField.Enabled then
- local dof = Instance.new("DepthOfFieldEffect", lighting)
- dof.FarIntensity = GraphicsEnhancer.CurrentSettings.DepthOfField.FarIntensity
- dof.FocusDistance = GraphicsEnhancer.CurrentSettings.DepthOfField.FocusDistance
- dof.InFocusRadius = GraphicsEnhancer.CurrentSettings.DepthOfField.InFocusRadius
- dof.NearIntensity = GraphicsEnhancer.CurrentSettings.DepthOfField.NearIntensity
- end
- if GraphicsEnhancer.CurrentSettings.SunRays.Enabled then
- local sunRays = Instance.new("SunRaysEffect", lighting)
- sunRays.Intensity = GraphicsEnhancer.CurrentSettings.SunRays.Intensity
- sunRays.Spread = GraphicsEnhancer.CurrentSettings.SunRays.Spread
- end
- if GraphicsEnhancer.CurrentSettings.Atmosphere.Enabled then
- local atmosphere = Instance.new("Atmosphere", lighting)
- atmosphere.Density = GraphicsEnhancer.CurrentSettings.Atmosphere.Density
- atmosphere.Offset = GraphicsEnhancer.CurrentSettings.Atmosphere.Offset
- atmosphere.Color = GraphicsEnhancer.CurrentSettings.Atmosphere.Color
- atmosphere.Decay = GraphicsEnhancer.CurrentSettings.Atmosphere.Decay
- atmosphere.Haze = GraphicsEnhancer.CurrentSettings.Atmosphere.Haze
- end
- -- Apply lighting settings
- lighting.GlobalShadows = GraphicsEnhancer.CurrentSettings.Lighting.GlobalShadows
- lighting.Brightness = GraphicsEnhancer.CurrentSettings.Lighting.Brightness
- lighting.OutdoorAmbient = GraphicsEnhancer.CurrentSettings.Lighting.OutdoorAmbient
- lighting.ClockTime = GraphicsEnhancer.CurrentSettings.Lighting.ClockTime
- lighting.GeographicLatitude = GraphicsEnhancer.CurrentSettings.Lighting.Latitude
- lighting.ExposureCompensation = GraphicsEnhancer.CurrentSettings.Lighting.Exposure
- lighting.ShadowSoftness = GraphicsEnhancer.CurrentSettings.Lighting.ShadowSoftness
- -- Fog settings
- lighting.FogStart = GraphicsEnhancer.CurrentSettings.Lighting.FogEnabled and GraphicsEnhancer.CurrentSettings.Lighting.FogStart or 0
- lighting.FogEnd = GraphicsEnhancer.CurrentSettings.Lighting.FogEnabled and GraphicsEnhancer.CurrentSettings.Lighting.FogEnd or 0
- lighting.FogColor = GraphicsEnhancer.CurrentSettings.Atmosphere.Color
- end
- function GraphicsEnhancer.initUI()
- -- Main toggle
- Tabs.Graphics:AddToggle("GraphicsEnabled", {
- Title = "Включить графику",
- Default = GraphicsEnhancer.CurrentSettings.Enabled,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.Enabled = value
- GraphicsEnhancer.applySettings()
- end
- })
- -- Quality preset dropdown
- Tabs.Graphics:AddDropdown("QualityPreset", {
- Title = "Настройка качества",
- Values = {"Low", "Medium", "High", "Ultra"},
- Default = GraphicsEnhancer.CurrentSettings.Quality,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.Quality = value
- GraphicsEnhancer.applySettings()
- end
- })
- -- Bloom section
- Tabs.Graphics:AddSection("Настройки свечения")
- Tabs.Graphics:AddToggle("BloomEnabled", {
- Title = "Включить свечение",
- Default = GraphicsEnhancer.CurrentSettings.Bloom.Enabled,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.Bloom.Enabled = value
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddSlider("BloomIntensity", {
- Title = "Интенсивность свечения",
- Description = "Сила эффекта свечения",
- Default = GraphicsEnhancer.CurrentSettings.Bloom.Intensity * 100,
- Min = 0,
- Max = 100,
- Rounding = 1,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.Bloom.Intensity = value / 100
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddSlider("BloomSize", {
- Title = "Размер свечения",
- Description = "Размер эффекта свечения",
- Default = GraphicsEnhancer.CurrentSettings.Bloom.Size,
- Min = 1,
- Max = 50,
- Rounding = 1,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.Bloom.Size = value
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddSlider("BloomThreshold", {
- Title = "Порог свечения",
- Description = "Уровень яркости для появления свечения",
- Default = GraphicsEnhancer.CurrentSettings.Bloom.Threshold * 100,
- Min = 0,
- Max = 100,
- Rounding = 1,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.Bloom.Threshold = value / 100
- GraphicsEnhancer.applySettings()
- end
- })
- -- Color correction section
- Tabs.Graphics:AddSection("Настройки цвета")
- Tabs.Graphics:AddToggle("ColorCorrectionEnabled", {
- Title = "Включить коррекцию цвета",
- Default = GraphicsEnhancer.CurrentSettings.ColorCorrection.Enabled,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.ColorCorrection.Enabled = value
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddSlider("Brightness", {
- Title = "Яркость",
- Default = (GraphicsEnhancer.CurrentSettings.ColorCorrection.Brightness + 1) * 50,
- Min = 0,
- Max = 100,
- Rounding = 1,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.ColorCorrection.Brightness = (value / 50) - 1
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddSlider("Contrast", {
- Title = "Контраст",
- Default = (GraphicsEnhancer.CurrentSettings.ColorCorrection.Contrast + 1) * 50,
- Min = 0,
- Max = 100,
- Rounding = 1,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.ColorCorrection.Contrast = (value / 50) - 1
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddSlider("Saturation", {
- Title = "Насыщенность",
- Default = (GraphicsEnhancer.CurrentSettings.ColorCorrection.Saturation + 1) * 50,
- Min = 0,
- Max = 100,
- Rounding = 1,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.ColorCorrection.Saturation = (value / 50) - 1
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddColorpicker("TintColor", {
- Title = "Цветовой оттенок",
- Default = GraphicsEnhancer.CurrentSettings.ColorCorrection.TintColor,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.ColorCorrection.TintColor = value
- GraphicsEnhancer.applySettings()
- end
- })
- -- Depth of Field section
- Tabs.Graphics:AddSection("Глубина резкости")
- Tabs.Graphics:AddToggle("DOFEnabled", {
- Title = "Включить глубину резкости",
- Default = GraphicsEnhancer.CurrentSettings.DepthOfField.Enabled,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.DepthOfField.Enabled = value
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddSlider("DOFFocusDistance", {
- Title = "Дистанция фокуса",
- Default = GraphicsEnhancer.CurrentSettings.DepthOfField.FocusDistance,
- Min = 1,
- Max = 100,
- Rounding = 1,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.DepthOfField.FocusDistance = value
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddSlider("DOFNearIntensity", {
- Title = "Интенсивность ближнего размытия",
- Default = GraphicsEnhancer.CurrentSettings.DepthOfField.NearIntensity * 100,
- Min = 0,
- Max = 100,
- Rounding = 1,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.DepthOfField.NearIntensity = value / 100
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddSlider("DOFFarIntensity", {
- Title = "Интенсивность дальнего размытия",
- Default = GraphicsEnhancer.CurrentSettings.DepthOfField.FarIntensity * 100,
- Min = 0,
- Max = 100,
- Rounding = 1,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.DepthOfField.FarIntensity = value / 100
- GraphicsEnhancer.applySettings()
- end
- })
- -- Sun Rays section
- Tabs.Graphics:AddSection("Солнечные лучи")
- Tabs.Graphics:AddToggle("SunRaysEnabled", {
- Title = "Включить солнечные лучи",
- Default = GraphicsEnhancer.CurrentSettings.SunRays.Enabled,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.SunRays.Enabled = value
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddSlider("SunRaysIntensity", {
- Title = "Интенсивность солнечных лучей",
- Default = GraphicsEnhancer.CurrentSettings.SunRays.Intensity * 100,
- Min = 0,
- Max = 100,
- Rounding = 1,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.SunRays.Intensity = value / 100
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddSlider("SunRaysSpread", {
- Title = "Распространение лучей",
- Default = GraphicsEnhancer.CurrentSettings.SunRays.Spread * 100,
- Min = 1,
- Max = 200,
- Rounding = 1,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.SunRays.Spread = value / 100
- GraphicsEnhancer.applySettings()
- end
- })
- -- Atmosphere section
- Tabs.Graphics:AddSection("Атмосфера")
- Tabs.Graphics:AddToggle("AtmosphereEnabled", {
- Title = "Включить атмосферу",
- Default = GraphicsEnhancer.CurrentSettings.Atmosphere.Enabled,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.Atmosphere.Enabled = value
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddSlider("AtmosphereDensity", {
- Title = "Плотность атмосферы",
- Default = GraphicsEnhancer.CurrentSettings.Atmosphere.Density * 100,
- Min = 0,
- Max = 100,
- Rounding = 1,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.Atmosphere.Density = value / 100
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddColorpicker("AtmosphereColor", {
- Title = "Цвет атмосферы",
- Default = GraphicsEnhancer.CurrentSettings.Atmosphere.Color,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.Atmosphere.Color = value
- GraphicsEnhancer.applySettings()
- end
- })
- -- Lighting section
- Tabs.Graphics:AddSection("Освещение")
- Tabs.Graphics:AddSlider("TimeOfDay", {
- Title = "Время суток",
- Description = "0 = полночь, 12 = полдень, 24 = полночь",
- Default = GraphicsEnhancer.CurrentSettings.Lighting.ClockTime,
- Min = 0,
- Max = 24,
- Rounding = 1,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.Lighting.ClockTime = value
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddSlider("Brightness", {
- Title = "Яркость мира",
- Default = GraphicsEnhancer.CurrentSettings.Lighting.Brightness * 10,
- Min = 0,
- Max = 30,
- Rounding = 1,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.Lighting.Brightness = value / 10
- GraphicsEnhancer.applySettings()
- end
- })
- Tabs.Graphics:AddToggle("FogEnabled", {
- Title = "Включить туман",
- Default = GraphicsEnhancer.CurrentSettings.Lighting.FogEnabled,
- Callback = function(value)
- GraphicsEnhancer.CurrentSettings.Lighting.FogEnabled = value
- GraphicsEnhancer.applySettings()
- end
- })
- -- Reset button
- Tabs.Graphics:AddButton({
- Title = "Сбросить настройки",
- Description = "Сбросить все графические настройки к значениям по умолчанию",
- Callback = function()
- GraphicsEnhancer.CurrentSettings = {
- Enabled = true,
- Quality = "High",
- Bloom = {
- Enabled = true,
- Intensity = 0.85,
- Size = 28,
- Threshold = 0.75
- },
- -- [rest of default settings...]
- }
- GraphicsEnhancer.applySettings()
- Window:Dialog({
- Title = "Сброс завершен",
- Content = "Все настройки были сброшены к значениям по умолчанию.",
- Buttons = {
- {
- Title = "OK",
- Callback = function() end
- }
- }
- })
- end
- })
- end
- -- Initialize save system
- SaveManager:SetLibrary(Fluent)
- InterfaceManager:SetLibrary(Fluent)
- SaveManager:IgnoreThemeSettings()
- InterfaceManager:SetFolder("GraphicsEnhancer")
- SaveManager:SetFolder("GraphicsEnhancer/configs")
- InterfaceManager:BuildInterfaceSection(Tabs.Settings)
- SaveManager:BuildConfigSection(Tabs.Settings)
- -- First-time setup
- GraphicsEnhancer.applySettings()
- GraphicsEnhancer.initUI()
- Window:SelectTab(1)
- Fluent:Notify({
- Title = "Улучшение графики от 1qlua",
- Content = "Панель управления графикой успешно загружена!",
- Duration = 5
- })
- -- Load saved config
- SaveManager:LoadAutoloadConfig()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement