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: Ray alternative?

Previous Thread :: Next Thread 
blockoo is not online. blockoo
Joined: 08 Nov 2007
Total Posts: 17202
13 Oct 2011 04:10 PM
Is there a thing similar to a ray but has a finite length that I can use instead?

~Who's more ignorant? The troll or the one who follows him?
Report Abuse
mew903 is not online. mew903
Joined: 03 Aug 2008
Total Posts: 22071
13 Oct 2011 04:11 PM
Instance.mew=function(...)

return {...}

end
Report Abuse
blockoo is not online. blockoo
Joined: 08 Nov 2007
Total Posts: 17202
13 Oct 2011 04:22 PM
gobwey troll

~Who's more ignorant? The troll or the one who follows him?
Report Abuse
mew903 is not online. mew903
Joined: 03 Aug 2008
Total Posts: 22071
13 Oct 2011 06:37 PM
Error: Attempted to call 'gobwey', a Scripters Forum value.
Report Abuse
crazypotato4 is not online. crazypotato4
Joined: 22 Feb 2010
Total Posts: 20000
13 Oct 2011 06:37 PM
rays already have a finite length :l
Report Abuse
blockoo is not online. blockoo
Joined: 08 Nov 2007
Total Posts: 17202
13 Oct 2011 06:44 PM
@crazy
Um, no, a ray has a single endpoint and extends in one direction forever.

~Who's more ignorant? The troll or the one who follows him?
Report Abuse
ServerLabs is not online. ServerLabs
Joined: 29 Dec 2010
Total Posts: 2263
13 Oct 2011 07:05 PM
Unfortunately, you are wrong Blockoo. Raycasting on ROBLOX has a max distance of 1000 studs I believe. So it's really more line segmentcasting.
Report Abuse
blockoo is not online. blockoo
Joined: 08 Nov 2007
Total Posts: 17202
13 Oct 2011 07:30 PM
Doesn't matter, I need something where I can change that 1000 studs to 50, or 22, or whatever I want.

~Who's more ignorant? The troll or the one who follows him?
Report Abuse
crazypotato4 is not online. crazypotato4
Joined: 22 Feb 2010
Total Posts: 20000
13 Oct 2011 07:45 PM
you already can :l

where have you been

basically,

Ray.new(origin, unit direction * distance)

thats pretty much how it works

you can also look at it like this i guess

Ray.new(origin, end - origin)
Report Abuse
blockoo is not online. blockoo
Joined: 08 Nov 2007
Total Posts: 17202
13 Oct 2011 07:56 PM
The second argument in Ray.new() is the point the ray goes through and continues on past it, apparently for 1000 studs.

~Who's more ignorant? The troll or the one who follows him?
Report Abuse
crazypotato4 is not online. crazypotato4
Joined: 22 Feb 2010
Total Posts: 20000
13 Oct 2011 07:58 PM
according to the noob who wrote the wiki article

i'd fix it, but the wiki is screwed up for writers and editors

plus, i dont like making major edits on articles in the mainspace, people might get mad D: (but i'll do it anyways once the wiki is working)
Report Abuse
blockoo is not online. blockoo
Joined: 08 Nov 2007
Total Posts: 17202
13 Oct 2011 08:03 PM
Oh, lol. Stupid writer xD

So, why are they even called rays if they're really segments? Ray just sounds cooler?

~Who's more ignorant? The troll or the one who follows him?
Report Abuse
crazypotato4 is not online. crazypotato4
Joined: 22 Feb 2010
Total Posts: 20000
13 Oct 2011 08:05 PM
because theyre supposed to be rays, but if they were infinite then they would obviously take up an infinite amount of memory, and raycasting with them would crash something if the ray didnt hit anything.

plus, it has a direction, which line segments dont have. i think. idk.
Report Abuse
blockoo is not online. blockoo
Joined: 08 Nov 2007
Total Posts: 17202
13 Oct 2011 08:07 PM
Erm, line segments do have direction? Take a ray, and cut the infinite end off. A segment with direction.

~Who's more ignorant? The troll or the one who follows him?
Report Abuse
crazypotato4 is not online. crazypotato4
Joined: 22 Feb 2010
Total Posts: 20000
13 Oct 2011 08:08 PM
...

D:

meanie
Report Abuse
blockoo is not online. blockoo
Joined: 08 Nov 2007
Total Posts: 17202
13 Oct 2011 08:09 PM
Oh well, ROBLOX does dumb things

Like making math.pow

~Who's more ignorant? The troll or the one who follows him?
Report Abuse
crazypotato4 is not online. crazypotato4
Joined: 22 Feb 2010
Total Posts: 20000
13 Oct 2011 08:10 PM
math is a standard lua library, blame the guy who made lua.
Report Abuse
moustachauve is not online. moustachauve
Joined: 29 Jul 2009
Total Posts: 668
13 Oct 2011 08:11 PM
its not a lua thingy?
Report Abuse
ElectricBlaze is not online. ElectricBlaze
Joined: 18 Jul 2011
Total Posts: 22930
13 Oct 2011 08:11 PM
^

do you want some jelly with that toast?


-Like an __AWESOME__ boss
Report Abuse
blockoo is not online. blockoo
Joined: 08 Nov 2007
Total Posts: 17202
13 Oct 2011 08:11 PM
True dat...lets think of something that was ROBLOX's fault.

~Who's more ignorant? The troll or the one who follows him?
Report Abuse
crazypotato4 is not online. crazypotato4
Joined: 22 Feb 2010
Total Posts: 20000
13 Oct 2011 08:13 PM
everything is roblox's fault
Report Abuse
ElectricBlaze is not online. ElectricBlaze
Joined: 18 Jul 2011
Total Posts: 22930
13 Oct 2011 08:13 PM
^


-Like an __AWESOME__ boss
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