generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Detect if player is near terrain

Previous Thread :: Next Thread 
Vaporation is not online. Vaporation
Joined: 08 Jun 2011
Total Posts: 1397
18 Nov 2013 11:05 AM
Is that possible?
Report Abuse
sycips is not online. sycips
Joined: 21 Mar 2011
Total Posts: 1368
18 Nov 2013 11:10 AM
yes, you can detect if a player is near a terrain part, how to do it? idk, because I dont know much about terrain...
Report Abuse
Geodesic is not online. Geodesic
Joined: 02 Jun 2013
Total Posts: 998
18 Nov 2013 11:13 AM
i'd probably use the :GetCell() method
Report Abuse
DaMrNelson is not online. DaMrNelson
Joined: 27 Jul 2009
Total Posts: 4405
18 Nov 2013 11:16 AM
Use GetCell on all blocks around the Player within your radius... you could also use Raycasting. Another way MIGHT be Workspace:FindPartsInRegion3. I can't test if it works on terrain at the moment, but its worth a shot.

Wiki Profile: http://wiki.roblox.com/index.php/User:Nelson
Report Abuse
Scriptural is not online. Scriptural
Joined: 06 Sep 2013
Total Posts: 2979
18 Nov 2013 01:19 PM
"Finepartsinregien3"
Explain c:
Report Abuse
flatline115 is not online. flatline115
Joined: 29 Jul 2013
Total Posts: 7826
18 Nov 2013 01:44 PM
Explain c:
---
He means the method that allows you to find parts only made in the finest of diamonds my child.
Report Abuse
Scriptural is not online. Scriptural
Joined: 06 Sep 2013
Total Posts: 2979
18 Nov 2013 01:50 PM
@flatline
Y u no help
Report Abuse
flatline115 is not online. flatline115
Joined: 29 Jul 2013
Total Posts: 7826
18 Nov 2013 01:52 PM
@Script because, you're not ready to embrace the wisdom of said method.
Report Abuse
Scriptural is not online. Scriptural
Joined: 06 Sep 2013
Total Posts: 2979
18 Nov 2013 02:04 PM
How do you know? Theres not a set time someone is ready to learn
Report Abuse
flatline115 is not online. flatline115
Joined: 29 Jul 2013
Total Posts: 7826
18 Nov 2013 02:05 PM
How do you know? Theres not a set time someone is ready to learn
------
Yet there is.
Report Abuse
Scriptural is not online. Scriptural
Joined: 06 Sep 2013
Total Posts: 2979
18 Nov 2013 02:08 PM
No there isn't, anyone can learn anything at anytime if they understand it, and you don't know if you understand till you try
Report Abuse
flatline115 is not online. flatline115
Joined: 29 Jul 2013
Total Posts: 7826
18 Nov 2013 02:10 PM
No there isn't, anyone can learn anything at anytime if they understand it, and you don't know if you understand till you try
----
That explain's the U.S. public education system.
Report Abuse
Scriptural is not online. Scriptural
Joined: 06 Sep 2013
Total Posts: 2979
18 Nov 2013 02:15 PM
Yes it does, but that has nothing to do with anything.
Report Abuse
Ictis is not online. Ictis
Joined: 01 Sep 2011
Total Posts: 1216
18 Nov 2013 02:54 PM
It's on the wiki, if you have the ambition for something you can do find out there. If it's not on the wiki it's probably available elsewhere.
Report Abuse
DaMrNelson is not online. DaMrNelson
Joined: 27 Jul 2009
Total Posts: 4405
18 Nov 2013 07:48 PM
@Scriptural
Sorry this reply took so long. A Region3 is basically a storage Object for two Vector3s. It's most typical use is the method in Workspace called FindPartsInRegion3. Here's a quick example:

local pos1 = Vector3.new(-5, -5, -5)
local pos2 = Vector3.new(5, 5, 5)
local region3 = Region3.new(pos1, pos2)

local parts = game.Workspace:FindPartsInRegion3(region3, nil, 100) -- Region3 region, Instance ignoreDescendantsInstance, int MaxParts (max 100)
for i, part in pairs(parts) do
print(part:GetFullName(), "was in side of the specified area")
end

Wiki Profile: http://wiki.roblox.com/index.php/User:Nelson
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image