youbigown
(youbigown)
November 7, 2022, 2:13pm
#14
The text itself was never bright to begin with. The problem is that my textstroke is causing this weird effect as you can see in the video I posted.
The stroke is covering the entire txt, instead of only the edges.
The stroke is instantly turning 100% non transparent.
The tween service is cool though, even though it doesn’t solve it.
DasKairo
(Cairo)
November 7, 2022, 2:17pm
#15
This is what the Script should do:
it shouldn’t cause a “Flashbang” effect
youbigown
(youbigown)
November 7, 2022, 2:19pm
#16
It gives the same effect that my original script gives.
And yes I know it shouldn’t cause a flashbang effect - that is why I am posting on DevForum.
DasKairo
(Cairo)
November 7, 2022, 2:22pm
#17
But why are you arguing then???
youbigown
(youbigown)
November 7, 2022, 2:25pm
#18
I’m not arguing. I am simply explaining that the problem is displayed on the original video that I posted. The stroke is behaving weirdly.
DasKairo
(Cairo)
November 7, 2022, 2:26pm
#19
Can you show your whole script then? there may be something interfering with it
youbigown
(youbigown)
November 7, 2022, 2:28pm
#20
-- variables
local camCheck = false
local cc = workspace.CurrentCamera
local plr = game.Players.LocalPlayer.Character
local mc = workspace.menuCam
local playB = game.Players.LocalPlayer.PlayerGui.Menu.playB
local settingsB = game.Players.LocalPlayer.PlayerGui.Menu.settingsB
cc.CameraType = Enum.CameraType.Scriptable
cc.CFrame = mc.CFrame
-- functions
local function playClick()
local startVol = game.SoundService.menuMusic.Volume
local darken = script.Parent.Parent.Parent.darkener.darken
game.Players.LocalPlayer.PlayerGui.Menu.Enabled = false
local userInputService = game:GetService("UserInputService")
local guideTxt = game.Players.LocalPlayer.PlayerGui.guide1.text
userInputService.MouseIconEnabled = false
while darken.Transparency >= 0 do
wait(0.01)
darken.Transparency -= 0.02
game.SoundService.menuMusic.Volume -= (startVol/100)*2
end
--gameplay settings
plr.Humanoid:RemoveAccessories()
game.Lighting.Atmosphere.Density = 0.9
game.Lighting.Brightness = 0.5
plr:MoveTo(workspace.startBlock.Position)
camCheck = true
wait(0.1)
game.Players.LocalPlayer.CameraMode = Enum.CameraMode.LockFirstPerson
wait(0.5)
game.SoundService.wind.Playing = true
--enable scripts
game.Players.LocalPlayer.PlayerScripts.ambience1.Disabled = false
game.Players.LocalPlayer.PlayerScripts.ambience2.Disabled = false
game.Players.LocalPlayer.PlayerScripts.ambience3.Disabled = false
game.Players.LocalPlayer.PlayerScripts.ambience4.Disabled = false
game.Players.LocalPlayer.PlayerScripts.flashlight.Disabled = false
game.Players.LocalPlayer.PlayerScripts.walkSounds.Disabled = false
game.Players.LocalPlayer.PlayerScripts.sprint.Disabled = false
while darken.Transparency <= 1 do
wait(0.01)
darken.Transparency += 0.02
end
local TS = game:GetService("TweenService")
TS:Create(guideTxt, TweenInfo.new(2), {TextTransparency = 0, TextStrokeTransparency = 0}):Play()
task.wait(5)
TS:Create(guideTxt, TweenInfo.new(2), {TextTransparency = 1, TextStrokeTransparency = 1}):Play()
end
-- while guideTxt.TextTransparency > 0 do
-- wait(0.01)
-- guideTxt.TextTransparency -= 0.02
-- guideTxt.TextStrokeTransparency -= 0.02
-- end
-- wait(5)
-- while guideTxt.TextTransparency < 1 do
-- wait(0.01)
-- guideTxt.TextTransparency += 0.02
-- guideTxt.TextStrokeTransparency += 0.02
playB.MouseButton1Click:Connect(playClick)
DasKairo
(Cairo)
November 7, 2022, 2:35pm
#21
Not sure if this helped
-- variables
TS = game:GetService("TweenService")
userInputService = game:GetService("UserInputService")
CamCheck = false
cc = workspace.CurrentCamera
plr = game.Players.LocalPlayer.Character
mc = workspace.menuCam
playB = game.Players.LocalPlayer.PlayerGui.Menu.playB
settingsB = game.Players.LocalPlayer.PlayerGui.Menu.settingsB
cc.CameraType = Enum.CameraType.Scriptable
cc.CFrame = mc.CFrame
startVol = game.SoundService.menuMusic.Volume
darken = script.Parent.Parent.Parent.darkener.darken
guideTxt = game.Players.LocalPlayer.PlayerGui.guide1.text
-- functions
local function playClick()
game.Players.LocalPlayer.PlayerGui.Menu.Enabled = false
userInputService.MouseIconEnabled = false
while darken.Transparency >= 0 do
wait(0.01)
darken.Transparency -= 0.02
game.SoundService.menuMusic.Volume -= (startVol/100)*2
end
--gameplay settings
plr.Humanoid:RemoveAccessories()
game.Lighting.Atmosphere.Density = 0.9
game.Lighting.Brightness = 0.5
plr:MoveTo(workspace.startBlock.Position)
camCheck = true
wait(0.1)
game.Players.LocalPlayer.CameraMode = Enum.CameraMode.LockFirstPerson
wait(0.5)
game.SoundService.wind.Playing = true
--enable scripts
game.Players.LocalPlayer.PlayerScripts.ambience1.Disabled = false
game.Players.LocalPlayer.PlayerScripts.ambience2.Disabled = false
game.Players.LocalPlayer.PlayerScripts.ambience3.Disabled = false
game.Players.LocalPlayer.PlayerScripts.ambience4.Disabled = false
game.Players.LocalPlayer.PlayerScripts.flashlight.Disabled = false
game.Players.LocalPlayer.PlayerScripts.walkSounds.Disabled = false
game.Players.LocalPlayer.PlayerScripts.sprint.Disabled = false
if darken.Transparency <= 1 do
TS:Create(darken, TweenInfo.new(2), {TextTransparency = 1}):Play()
end
task.wait(2)
TS:Create(guideTxt, TweenInfo.new(2), {TextTransparency = 0, TextStrokeTransparency = 0}):Play()
task.wait(5)
TS:Create(guideTxt, TweenInfo.new(2), {TextTransparency = 1, TextStrokeTransparency = 1}):Play()
end
--[[
while guideTxt.TextTransparency > 0 do
wait(0.01)
guideTxt.TextTransparency -= 0.02
guideTxt.TextStrokeTransparency -= 0.02
end
wait(5)
while guideTxt.TextTransparency < 1 do
wait(0.01)
guideTxt.TextTransparency += 0.02
guideTxt.TextStrokeTransparency += 0.02
]]
playB.MouseButton1Click:Connect(playClick)
youbigown
(youbigown)
November 7, 2022, 2:39pm
#22
That would only seem to make the loading inconsistent. The --[[ tip is nice though.
This seems more like a GUI issue than a scripting issue at this point. I removed the scripting tag.
EgizianoEG
(Egiziano)
November 7, 2022, 2:39pm
#23
you may need to delay the text transparency tween for about 0.3 secs
Or speed the text stroke tween little a bit
youbigown
(youbigown)
November 7, 2022, 2:41pm
#24
What should I change here to delay it for 0,3s?
local TS = game:GetService("TweenService")
TS:Create(guideTxt, TweenInfo.new(2), {TextTransparency = 0, TextStrokeTransparency = 0}):Play()
task.wait(5)
TS:Create(guideTxt, TweenInfo.new(2), {TextTransparency = 1, TextStrokeTransparency = 1}):Play()
end
EgizianoEG
(Egiziano)
November 7, 2022, 2:42pm
#25
Im currently testing the method out. the tween has a delay argument at the end of the tween info
youbigown
(youbigown)
November 7, 2022, 2:43pm
#26
Wouldn’t that delay both the txt and stroke
EgizianoEG
(Egiziano)
November 7, 2022, 2:45pm
#27
nope, the tween doesn’t yield the thread/scope that it is in
EgizianoEG
(Egiziano)
November 7, 2022, 2:47pm
#28
you can try one of those methods:
speeding up the text stroke transparency to nearly sync with the text transparency:
TS:Create(guideTxt, TweenInfo.new(2.15), {TextStrokeTransparency = 0}):Play()
TS:Create(guideTxt, TweenInfo.new(2), {TextTransparency = 0}):Play()
task.wait(4)
TS:Create(guideTxt, TweenInfo.new(2.15), {TextStrokeTransparency = 1}):Play()
TS:Create(guideTxt, TweenInfo.new(2), {TextTransparency = 1}):Play()
Delaying the text transparency little a bit:
TS:Create(guideTxt, TweenInfo.new(2), {TextStrokeTransparency = 0}):Play()
TS:Create(guideTxt, TweenInfo.new(2, Enum.EasingStyle.Quad, Enum.EasingDirection.Out, 0, false, 0.28), {TextTransparency = 0}):Play()
task.wait(4)
TS:Create(guideTxt, TweenInfo.new(2), {TextStrokeTransparency = 1}):Play()
TS:Create(guideTxt, TweenInfo.new(2, Enum.EasingStyle.Quad, Enum.EasingDirection.Out, 0, false, 0.28), {TextTransparency = 1}):Play()
youbigown
(youbigown)
November 7, 2022, 2:50pm
#29
Unfortunately they both have the same effect as the original code. I also tried changing fonts, but it didn’t help either
EgizianoEG
(Egiziano)
November 7, 2022, 2:51pm
#30
try to play with delay seconds or play with the speed of the stroke
edit: I guess there is a problem…
youbigown
(youbigown)
November 7, 2022, 2:56pm
#31
I played around, and it doesn’t change anything meaningfull from what I can see
EgizianoEG
(Egiziano)
November 7, 2022, 3:01pm
#32
I think I didn’t understand your issue right
youbigown
(youbigown)
November 7, 2022, 3:07pm
#33
Here you can see the problem in studio. Once I change txt transparency to 0,9 it becomes very bright. In other words the txt stroke is literally taking over the text and acts like its transparency = 0 and is therefor fully white.
t