rastamann
|
  |
| Joined: 27 May 2008 |
| Total Posts: 539 |
|
|
| 02 Jan 2012 04:29 PM |
| My Question is, how i can get a bricks parameters or something in it by hovering over with mouse, whats the command ? |
|
|
| Report Abuse |
|
|
|
| 02 Jan 2012 04:32 PM |
| Well, you'd find the brick the mouse is pointing at, then use magnitude to find the distance between the brick and the player, then write the magnitude. |
|
|
| Report Abuse |
|
|
rastamann
|
  |
| Joined: 27 May 2008 |
| Total Posts: 539 |
|
|
| 02 Jan 2012 04:35 PM |
| And whats the command for the pointing ? |
|
|
| Report Abuse |
|
|
rastamann
|
  |
| Joined: 27 May 2008 |
| Total Posts: 539 |
|
|
| 02 Jan 2012 04:35 PM |
| Or better, could you give me an exemple so i can understand it better ! |
|
|
| Report Abuse |
|
|
|
| 02 Jan 2012 04:37 PM |
| Well, you gotta get to the mouse first... But once you're there it's Mouse.Hit |
|
|
| Report Abuse |
|
|
rastamann
|
  |
| Joined: 27 May 2008 |
| Total Posts: 539 |
|
|
| 02 Jan 2012 04:42 PM |
| i dont understand it sry. couldn't you give me an exemple ? Let's say, in that brick is a Valuable. And if i point on it, the script should print the valuable. Got it ? |
|
|
| Report Abuse |
|
|
|
| 02 Jan 2012 04:44 PM |
To be able to use Mouse.Hit, you need to use a Hopperbin, or the Equipped event of Tools.
Anywhere in the script (localscript, preferably, to work correctly in Online) of the tool, you may refer to "Mouse". Then you can do:
local target = Mouse.Hit local tarPos = target.Position local dist = (player.Character.Torso.Position.magnitude - target.Position.magnitude)
Well, you get the point. |
|
|
| Report Abuse |
|
|
|
| 02 Jan 2012 04:44 PM |
I can try... This isn't tested or anything and will most likely be aweful but I'll try
local function test(m) while true do local mag = (m.Hit - script.Parent.Parent.Parent.Character).magnitude h = game.Workspace.Hint.Text h= (mag) end tool.Equipped:connect(onEquipped)
I might have messed up, wouldn't be surprised if I did... I'm not sure that mag should be in parenthasees but the rest should work. I think...
|
|
|
| Report Abuse |
|
|
|
| 02 Jan 2012 04:45 PM |
| Yea, forgot to add that part... |
|
|
| Report Abuse |
|
|
rastamann
|
  |
| Joined: 27 May 2008 |
| Total Posts: 539 |
|
|
| 02 Jan 2012 04:49 PM |
@Ravenshield
Why do i need the magnitude ? |
|
|
| Report Abuse |
|
|
|
| 02 Jan 2012 04:53 PM |
You wanted to find the distance between the player and the brick?
And also, I'm not sure if I used magnitude right. I'm not too experienced with it. ;) |
|
|
| Report Abuse |
|
|
rastamann
|
  |
| Joined: 27 May 2008 |
| Total Posts: 539 |
|
|
| 02 Jan 2012 04:56 PM |
| Nooo i want the parameters. Like Name or ClassName or something like that. Or that i can get a Value thats in that brick you understand ? And could you please give me an exemple i wana learn it, but like that its too difficult. And Sry for my english im swiss xD |
|
|
| Report Abuse |
|
|
Raven5887
|
  |
| Joined: 08 Dec 2008 |
| Total Posts: 3184 |
|
|
| 02 Jan 2012 04:58 PM |
| Did any of you ever heard of the mouse.Move event? -,- |
|
|
| Report Abuse |
|
|
rastamann
|
  |
| Joined: 27 May 2008 |
| Total Posts: 539 |
|
|
| 02 Jan 2012 04:59 PM |
| nooo so please explain it too me or give me an exemple that would be great :D |
|
|
| Report Abuse |
|
|
|
| 02 Jan 2012 05:00 PM |
| Obviously, Raven.. I just wasn't thinking about it being hovering over - not clicking. My bad.. |
|
|
| Report Abuse |
|
|
rastamann
|
  |
| Joined: 27 May 2008 |
| Total Posts: 539 |
|
| |
|
rastamann
|
  |
| Joined: 27 May 2008 |
| Total Posts: 539 |
|
| |
|
rastamann
|
  |
| Joined: 27 May 2008 |
| Total Posts: 539 |
|
| |
|
Robain
|
  |
| Joined: 10 Oct 2008 |
| Total Posts: 349 |
|
|
| 03 Jan 2012 07:35 AM |
mouse.Hit or mouse.Target or something? It was something like that.
~~http://www.roblox.com/Forum/ShowPost.aspx?PostID=57823962~~ ~~Another post for me. Umadbro?~~ |
|
|
| Report Abuse |
|
|