######################################################## ### Platforma1 ### #PROMPT: Napisz skrypt w Platforma1, który sprawi, że po wejściu gracza ten part zmieni kolor na żółty. #KOD: local part = script.Parent local debounce = false local originalColor = part.Color local originalMaterial = part.Material local function onTouch(otherPart) local character = otherPart.Parent if not character then return end local humanoid = character:FindFirstChildOfClass("Humanoid") if not humanoid or humanoid.Health <= 0 then return end if debounce then return end debounce = true -- Świecenie na żółto part.Material = Enum.Material.Neon part.Color = Color3.fromRGB(255, 235, 0) task.wait(1.5) -- Powrót do oryginalnego wyglądu part.Material = originalMaterial part.Color = originalColor debounce = false end part.Touched:Connect(onTouch) ######################################################## ### Log1 ### #PROMPT: Dodaj skrypt na Log1, który sprawi, że part zniknie po 2 sekundach od wejścia gracza i pojawi się ponownie po 1 sekundzie. #KOD: local part = script.Parent local debounce = false local function onTouch(otherPart) local character = otherPart.Parent local humanoid = character and character:FindFirstChildOfClass("Humanoid") if humanoid and not debounce then debounce = true task.wait(2) part.Transparency = 1 part.CanCollide = false task.wait(1) part.Transparency = 0 part.CanCollide = true debounce = false end end part.Touched:Connect(onTouch) ######################################################## ### Winda1 ### #PROMPT: Dodaj skrypt na part Winda1, który będzie cały czas powoli poruszał bloczkiem w górę i w dół. #KOD: local part = script.Parent local startY = part.Position.Y local range = 15 -- ile studów w górę i w dół local speed = 1 -- prędkość ruchu while task.wait() do local offset = math.sin(tick() * speed) * range part.CFrame = CFrame.new(part.Position.X, startY + offset, part.Position.Z) end ######################################################## ### Skocznia ### #PROMPT: Dodaj skrypt na Skocznia, który po dotknięciu tego klocka zacznie unosić gracza przez 5 sekund. #KOD: local part = script.Parent local LIFT_SPEED = 50 -- prędkość unoszenia w górę (studs/s) local LIFT_DURATION = 5 -- czas trwania unoszenia (sekundy) local debounce = {} part.Touched:Connect(function(otherPart) local character = otherPart.Parent if not character then return end local humanoid = character:FindFirstChildOfClass("Humanoid") if not humanoid or humanoid.Health <= 0 then return end local hrp = character:FindFirstChild("HumanoidRootPart") if not hrp then return end -- Debounce per character, aby zapobiec wielokrotnemu uruchomieniu if debounce[character] then return end debounce[character] = true -- Unosi gracza przez LIFT_DURATION sekund local startTime = os.clock() while os.clock() - startTime < LIFT_DURATION do if not character.Parent or humanoid.Health <= 0 then break end hrp.AssemblyLinearVelocity = Vector3.new(hrp.AssemblyLinearVelocity.X, LIFT_SPEED, hrp.AssemblyLinearVelocity.Z) task.wait(0.1) end debounce[character] = nil end) ########################################################