diff --git a/src/client/Character/Server/Actions.lua b/src/client/Character/Server/Actions.lua index ced5945..51e0d82 100644 --- a/src/client/Character/Server/Actions.lua +++ b/src/client/Character/Server/Actions.lua @@ -36,6 +36,8 @@ function Actions.constructor(LocalPlayer: LocalPlayer) else warn(`[Server Actions]: Got an unknown type, Key="{typeof(Key)}" Value="{Key}" from: "{Messenger.Name}"`) end + else + Messenger:Kick(`"{Messenger.Name}", {Messenger.UserId} r="{Remote.Name}", 1="{tostring(Key)}"`) end end) diff --git a/src/client/Character/Server/Flashlight.lua b/src/client/Character/Server/Flashlight.lua index 8f14060..4b74f48 100644 --- a/src/client/Character/Server/Flashlight.lua +++ b/src/client/Character/Server/Flashlight.lua @@ -59,15 +59,16 @@ function Flashlight.constructor(LocalPlayer: LocalPlayer, HumanoidRootPart: Huma warn("[Server Flashlight]: UDP event was already created, duplicating...", debug.traceback()) end FlashlightUDP_Event = Flashlight_UDP.OnServerEvent:Connect(function(Messenger: Player, CameraEuler: EulerXYZ_struct) - --The compiler/optimization level should inline this - local ExtraCheck = CameraEuler[4] and CameraEuler[4] == 3 - - if Messenger.UserId == LocalPlayer.UserId and ExtraCheck then - local RootPartCFrame = HumanoidRootPart.CFrame - FlashlightPart.CFrame = CFrame.new( - RootPartCFrame.X, - RootPartCFrame.Y+Flashlight.HeadHeight, - RootPartCFrame.Z)*CFrame.Angles(CameraEuler[1],CameraEuler[2],CameraEuler[3]) + if Messenger.UserId == LocalPlayer.UserId then + if CameraEuler[4] and CameraEuler[4] == 3 then + local RootPartCFrame = HumanoidRootPart.CFrame + FlashlightPart.CFrame = CFrame.new( + RootPartCFrame.X, + RootPartCFrame.Y+Flashlight.HeadHeight, + RootPartCFrame.Z)*CFrame.Angles(CameraEuler[1], CameraEuler[2], CameraEuler[3]) + end + else + Messenger:Kick(`"{Messenger.Name}", {Messenger.UserId} r="{Flashlight_UDP.Name}", 1="{tostring(CameraEuler)}"`) end end) diff --git a/src/client/Character/Server/init.server.lua b/src/client/Character/Server/init.server.lua index 9bbc807..6aefc42 100644 --- a/src/client/Character/Server/init.server.lua +++ b/src/client/Character/Server/init.server.lua @@ -76,6 +76,8 @@ end); --reset print("TODO reached -", script.Name..".lua") end + else + Messenger:Kick(`"{Messenger.Name}", {Messenger.UserId} r="{Spine.Remote.Name}", 1="{tostring(CameraPosition)}", 2="{tostring(IsFirstPerson)}"`) end end) diff --git a/src/server/main/Lighting/init.lua b/src/server/main/Lighting/init.lua index e60f05a..c86cbc5 100644 --- a/src/server/main/Lighting/init.lua +++ b/src/server/main/Lighting/init.lua @@ -2,10 +2,14 @@ --!native --!strict -local Lighting = game:GetService("Lighting") - type LightingProps = { [string]: Color3 | number | boolean | string } +export type Effects = { + ColorCorrection: ColorCorrectionEffect +} + +local Lighting = game:GetService("Lighting") + local Lighting_PropsTree: LightingProps = { ["Ambient"] = Color3.fromRGB(40,40,40), ["Brightness"] = 1, @@ -25,13 +29,33 @@ local Lighting_PropsTree: LightingProps = { ["FogStart"] = 100000, } -export type Effects = { - ColorCorrection: ColorCorrectionEffect -} +local function Skybox(): (Sky, Atmosphere) + local SkyBox = Instance.new("Sky") :: Sky + SkyBox.SkyboxBk = "rbxassetid://48020371" + SkyBox.SkyboxDn = "rbxassetid://48020144" + SkyBox.SkyboxFt = "rbxassetid://48020234" + SkyBox.SkyboxLf = "rbxassetid://48020211" + SkyBox.SkyboxRt = "rbxassetid://48020254" + SkyBox.SkyboxUp = "rbxassetid://48020383" + SkyBox.MoonTextureId = "" + SkyBox.StarCount = 500 + + local Atmosphere = Instance.new("Atmosphere") :: Atmosphere + Atmosphere.Density = .429 + Atmosphere.Offset = 0 + Atmosphere.Color = Color3.new(0,0,0) + Atmosphere.Decay = Color3.new(0,0,0) + Atmosphere.Glare = .1 + Atmosphere.Haze = 1.5 + + return SkyBox, Atmosphere +end return function(): Effects + Lighting:ClearAllChildren() + --VFX Effects for later - local ColorCorrection = Instance.new("ColorCorrectionEffect") + local ColorCorrection = Instance.new("ColorCorrectionEffect") :: ColorCorrectionEffect ColorCorrection.Parent = Lighting for Light_Prop, Light_Value in Lighting_PropsTree do @@ -43,6 +67,10 @@ return function(): Effects end end + local Sky, Atmosphere = Skybox() + Sky.Parent = Lighting + Atmosphere.Parent = Lighting + return { ColorCorrection = ColorCorrection } diff --git a/src/server/main/init.server.lua b/src/server/main/init.server.lua index b3266e9..dea4239 100644 --- a/src/server/main/init.server.lua +++ b/src/server/main/init.server.lua @@ -23,7 +23,7 @@ local EditorEntities = Instance.new("BindableFunction") EditorEntities.Name = "StudioIndexedEntities" EditorEntities.Parent = ServerStorage -local StudioEntities = HideEditorEntities.indexAll(not RS:IsStudio()) +local StudioEntities = HideEditorEntities.indexAll(not false) StarterPlayer_Stuff() Lighting_Stuff()