Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Is it possible to "listen" to water terrain?

Asked by
OniiCh_n 410 Moderation Voter
10 years ago

Listening is used to wait for certain events to execute code, such as .Touched. I am wondering if you can use the same events for the water terrain built into ROBLOX. For example, it would drown the player by lowering their health incrementally over time if they were to swim in it. How would I call my function for this type of script?

2 answers

Log in to vote
4
Answered by 10 years ago

SmoothBlockModel did it in his Catching Fire game.

I would try using Touched and TouchEnded.

Maybe start a function when they Touched it, and end it when TouchEnded?

EDIT: Sorry, I just realized that the 'water' material is part of Terrain.

Try making a brick, with CanCollide false, and Transparent, but anchored, and try what I said above.

0
Clever thinking there, you deserve a rep. Kozero 120 — 10y
0
I never thought of that. Very clever. OniiCh_n 410 — 10y
Ad
Log in to vote
0
Answered by 10 years ago

You could use one of clone troopers scripts and edit it. I makes your character "drown" if they're in water.

Answer this question