looking to find a way, to make all partials to appear in game, when the the graphic levels are turned down, they wont always be active. just when the its active
local glass = Ray.new(script.Parent.Position,Vector3.new(0,-100,0))
local emitter = Instance.new("ParticleEmitter")
emitter.Rate = 20
emitter.Lifetime = NumberRange.new(5,10)
emitter.Enabled = true
emitter.Texture = "rbxasset://textures/particles/sparkles_main.dds"
local colorKeypoints = {
ColorSequenceKeypoint.new( 0, Color3.fromRGB(255,69,0)),
ColorSequenceKeypoint.new(.5, Color3.fromRGB(255,69,0)),
ColorSequenceKeypoint.new( 1, Color3.fromRGB(255,69,0))
}
emitter.Color = ColorSequence.new(colorKeypoints)
local numberKeypoints = {
NumberSequenceKeypoint.new( 0, 1);
NumberSequenceKeypoint.new(.1, 0);
NumberSequenceKeypoint.new(.5, .25);
NumberSequenceKeypoint.new( 1, 1);
}
emitter.Transparency = NumberSequence.new(numberKeypoints)
emitter.LightEmission = 1
emitter.LightInfluence = 1
emitter.EmissionDirection = Enum.NormalId.Front
emitter.Speed = NumberRange.new(0, 0)
emitter.Drag = 0
emitter.VelocitySpread = NumberRange.new(0, 0)
emitter.VelocityInheritance = 0
emitter.Acceleration = Vector3.new(0, -100, 0)
emitter.LockedToPart = false
emitter.SpreadAngle = Vector2.new(0,0)
local numberKeypoints2 = {
NumberSequenceKeypoint.new(0, 15);
NumberSequenceKeypoint.new(1, 10);
}
emitter.Size = NumberSequence.new(numberKeypoints2)
emitter.ZOffset = -1
emitter.Rotation = NumberRange.new(0, 360)
emitter.RotSpeed = NumberRange.new(0)
local attachment = Instance.new("Attachment", script.Parent)
attachment.Position = Vector3.new(0, 5, 0)
emitter.Parent = attachment
while wait(1.1) do
local hit,position = workspace:FindPartOnRayWithIgnoreList(glass,{script.Parent})
if hit then
print(hit.Name)
local p = Instance.new("Part",workspace)
p.Anchored = true
p.CFrame = CFrame.new(position)
p.Size = Vector3.new(1,1,1)
p.Transparency = 1
p.Parent = script.Parent.parthold
function Convert(target)
change = Instance.new("Fire")
change.Parent = script.Parent.parthold.Part
end
changepart = script.Parent.parthold.Part
changepart.Touched:Connect(Convert)
local e = Instance.new("Explosion",script.Parent.parthold.Part)
e.ExplosionType = 0
e.Position = p.Position
e.Visible = false
game:GetService("Debris"):AddItem(p,1)
end
end
