this is the code i would like help TL is the model where i put the tailights for this car in TL1 is the one im currently trying to change (i will change rest later) Trail1 is when brakes are not currently being applied (or when your not pressing s) Trail2 is when brakes are being applied (or when you are pressing s)
01 | -- lines 25 and 43 dont work but the rest of this does |
02 | -- keep in mind im trying to make an extension to this code so it wont make sence |
03 | -- i think its material change written incorrectly |
04 |
05 | local FE = workspace.FilteringEnabled |
06 | local car = script.Parent.Parent.Parent.Car.Value |
07 | local handler = car:WaitForChild( "Lights_FE" ) |
08 | --- |
09 |
10 | script.Parent.Parent.Parent.Values.Brake.Changed:connect( function () |
11 | if script.Parent.Parent.Parent.Values.Brake.Value ~ = 1 and script.Parent.Parent.Parent.IsOn.Value then |
12 | if FE then |
13 | handler:FireServer( "Trail1" ) --trails off |
14 | else |
15 | car.Body.Trails.a 0. Enabled = false |
Ive found the problem actually, by reading the script i found that the material change only happens when filtering disabled is on, FE breaks this so i think i can fix the scripts now, no answer needed.