Ad
Log in to vote
0

I have 2 Parts and they're doing nothing when I click on them when they're coded correctly?

Asked by 2 months ago

I have 2 parts in my game that are supposed to change 2 things.

One is the Blue Part and two is The RedPart.

The Blue part controls the first thing which would be allowing eveyone to (including people who don't have the VIP and/or Water Fighting Area Access Pass.

The Red part controls the second thing which would be the cave that takes you to a ban hammer giver.

The Problem is that nothing's happening when you click any of them.

RedPart

local function onMouseClick(player)
    game.Workspace.Stone1:Destroy
    game.Workspace.Stone2.CanCollide = true
    game.Workspace.Stone2.Transparency = 0
    game.Soundscape.Landslide:Play()
end

clickDetector.MouseClick:connect(onMouseClick)

Blue Part

local function onMouseClick(player)
    game.Workspace.wfaAccess:Destroy()
    game.Workspace.TrueVIPDoor:Destroy()
end

clickDetector.MouseClick:connect(onMouseClick)

Output and Script Analysis are saying nothing about the blue part but Script Analysis is saying that a string is needed in a spot that's a location which the only space is in CanCollide = true Space ^ ^ Space

0
FE is disabled robertwoodsy5115 12 — 2mo
0
In the first script, Destroy should be Destroy() as its a method. Thetacah 284 — 2mo
0
Make sure there is a variable named clickDetector batmen101 0 — 2mo

Hi.

Looks like you're using an ad blocker.

That's fine...

No, it really is.

Just, I mean, we put a lot of work into this site, you know?

It would be really really appreciated if you would turn off your ad blocker for our website...

We tried really hard to make our ads as unobtrusive as possible.

If you really hate ads, would you consider a $2 donation via Patreon?

Here's the link.

We love you. We hope you love us too.

.

..

...

Now back to your regularly scheduled Scripting Helpers....

...

..

.

Answer this question



Ad