Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

What would YOU do to fix a script with no errors at all but you used the print method to debug?

This is my script;

local maxhealth = script.Parent:WaitForChild("MaxHealth")
local cardlevel = script.Parent.Parent.Parent.CardLevel:WaitForChild("CardLv")
local healthadded = false

cardlevel.Changed:connect(function(Value)
	if healthadded == false and cardlevel.Value == cardlevel.Value + 1 then
		maxhealth.Value = maxhealth.Value + (cardlevel.Value * 2)
		wait(0.5)
		healthadded = true
	else
		if healthadded == true then
			return
		end
	end
end)

There are no errors but if you need the output;

15:10:33.104 - Future Game Leak was auto-saved to C:/Users/BlackOrange3343/Documents/ROBLOX/AutoSaves/Place_AutoSave_40.rbxl
Ragdoll Physics Loaded
Hello world!
15:10:37.506 - Humanoid is not a valid member of Script
15:10:37.508 - Stack Begin
15:10:37.509 - Script 'Plugin_144773946.RealRagdoll.Ragdoll', Line 4
15:10:37.511 - Stack End
Loading Cutscene Editor...
Bouyer's Ragdoll Physics Loaded
Finished Loading.
Loading Tree Gen...
Finished Loading Tree Gen
15:10:38.865 - Unable to load plugin icon. (x2)
Realism Mod is running on v1.795!
Cutscene Editor Loaded
activated is now true
43
found nothing
43
activated is now true
32
Found something
Hello world!

3 comments

0

We explained exactly what was wrong on Discord. Also, name your question what you actually want to know. The title of this question is bad.

0

You should read the Output error...

1 answer

✓ Accepted answer

It says if cardlevel.Value == cardlevel.Value+1 The value can't equal itself plus one so the code won't run.

1 comment

1

We've told him this multiple times on Discord, he never listened.

This discussion is preserved as it was. New answers, comments, and votes are closed.