POC0bob
|
  |
| Joined: 20 Feb 2010 |
| Total Posts: 549 |
|
|
| 13 Jul 2011 09:10 PM |
| Hiya, so. How exactly would you create a block maker that creates blocks on a 7x7x7 grid, like in roblox's welcome to roblox game, the stamp tool it makes blocks only on an invisible grid... i understand no requests, this isnt a request, its asking for help... how could i do this? D: |
|
|
| Report Abuse |
|
|
Jinxy
|
  |
| Joined: 04 Aug 2007 |
| Total Posts: 18317 |
|
|
| 13 Jul 2011 09:11 PM |
| instance.new("Part") there might be more to this.... |
|
|
| Report Abuse |
|
|
POC0bob
|
  |
| Joined: 20 Feb 2010 |
| Total Posts: 549 |
|
|
| 13 Jul 2011 09:12 PM |
| haha that helped me none :P i know how to script really well, i am just stuck on this... not sure how i can do this.. |
|
|
| Report Abuse |
|
|
Jinxy
|
  |
| Joined: 04 Aug 2007 |
| Total Posts: 18317 |
|
|
| 13 Jul 2011 09:14 PM |
well You could try
setting the new part's properties of the x, y, and z to 7. I don't know the exact code. |
|
|
| Report Abuse |
|
|
POC0bob
|
  |
| Joined: 20 Feb 2010 |
| Total Posts: 549 |
|
|
| 13 Jul 2011 09:18 PM |
| just changing the position wouldnt help... its a tool, that when you click... it copys an object from the lighting, i already have the whole script but it doesnt create blocks on a grid of 7x7x7... |
|
|
| Report Abuse |
|
|
Jinxy
|
  |
| Joined: 04 Aug 2007 |
| Total Posts: 18317 |
|
|
| 13 Jul 2011 09:19 PM |
| Oh .-. I don't know how to help. You'd need a more advanced scripter than I. |
|
|
| Report Abuse |
|
|
POC0bob
|
  |
| Joined: 20 Feb 2010 |
| Total Posts: 549 |
|
|
| 13 Jul 2011 09:21 PM |
| haha :) thanks for replying though. |
|
|
| Report Abuse |
|
|
|
| 13 Jul 2011 09:47 PM |
Smallest divider(or PPCD in french)
|
|
|
| Report Abuse |
|
|
|
| 13 Jul 2011 09:50 PM |
oops i meant, you divide the number by 7, then you remove the decimals,and you multiplie back 15/7 = 2.14285 using math function = 2 * 7 = 14
you also look if it stay in the grid |
|
|
| Report Abuse |
|
|
POC0bob
|
  |
| Joined: 20 Feb 2010 |
| Total Posts: 549 |
|
|
| 13 Jul 2011 09:54 PM |
| you mean like math.Ceil? rounds the number up? |
|
|
| Report Abuse |
|
|
| |
|
POC0bob
|
  |
| Joined: 20 Feb 2010 |
| Total Posts: 549 |
|
|
| 13 Jul 2011 10:04 PM |
So, to lock objects to a grid, you would use this math equasion: Part being the object i want to use on a grid:
yg = Part.Position.Y/7 yg = yg* 7
Part.Position.Y = yg |
|
|
| Report Abuse |
|
|
|
| 13 Jul 2011 10:07 PM |
yg = Part.Position.Y/7 yg = math.ceil(yg) yg = yg*2 if part.Position.Y > 0 and part.Position.Y < 21 then
end |
|
|
| Report Abuse |
|
|
|
| 13 Jul 2011 10:08 PM |
| Change the condition statement if it is'nt your requirements |
|
|
| Report Abuse |
|
|
POC0bob
|
  |
| Joined: 20 Feb 2010 |
| Total Posts: 549 |
|
|
| 13 Jul 2011 10:12 PM |
| why did you multiply by 2, and not 7? |
|
|
| Report Abuse |
|
|
|
| 13 Jul 2011 10:16 PM |
| Lol sorry i did an error,7 not 2 XD |
|
|
| Report Abuse |
|
|