RingMaker - make big cylinders - open source
|
Cadroe Murphy
Assistant to Mr. Shatner
Join date: 31 Jul 2003
Posts: 689
|
01-08-2005 10:06
Ive made an object named RingMaker that will makes cylinders with any number of sides out of box prims. To save time, I'm just going to copy its README below. People are free to use it, change it, steal from it, or sell it. The object and its script are modifiable, as is the RingBlock object in its inventory. You can currently find it on my property at Ohno (78, 97, 94) for $1. Occasionally some blocks will stop listening, but I don't know if that's my fault yet.
************README**********
RingMaker automatically shapes and combines a number of box prims to form rings (cylinders) with any number of sides. This allows you to make cylinders larger than 10 meters, or smaller cylinders with flat sides. You tell RingMaker how many sides you want the ring to have, the radius of the ring, and how hollow you want it to be. It computes the rest for you. The radus is the distance from the center to a side (not a corner). The hollow value is a fraction of the radius, from 0 to 1 as with SL prims. The RingMaker uses itself as the center of the ring, but you can have it position the blocks above or below RingMaker through a Z offset. RingMaker listens to its owner on channel 11 (can't change channel in this version).
Commands:
sides x ( Set the number of sides to x ) radius x ( Set the radius to x ) height x ( Set the height of the blocks to x ) hollow x ( Set the hollow fraction to x - between 0 and 1) zoffset x (Set the z offset to x - places blocks z meters above or below RingMaker rez ( Rez the building blocks ) place ( Move the pieces into position ) freeze ( Tell all the building blocks to stop listening - this is their final position) delete ( Delete all the building blocks ) color x y z (Set all the building block colors to <x, y, z> name x ( Set all the building block names to x - no spaces or underscores in name) report ( Report the parameters ) reset ( Resets to default values )
Example:
Create a 12 sided ring 4 meters high and 14 meters wide with a 1.4 meter hole in the middle
/11 sides 12 /11 rez /11 radius 14 /11 hollow .1 /11 height 4 /11 freeze
Notes:
RingMaker doesn't know whether you've rezzed the blocks. RingMaker communicates with each set of rezzed blocks on a new randmonly selected channel. You can't change the number of sides after you've rezzed the blocks. Don't forget to call "freeze" when you're done positioning the ring; this disables the listens in the blocks. Be aware there are limitations because the individual blocks can't get bigger than 10 meters. RingMaker communicates with the blocks through shout so it can't form a ring with a radius more than about 100 (less if z offset is not 0). After freezing, each block will have a running script in it with no listens. I don't know what this means in terms of resources, but the blocks are mod so you can delete the scripts.
_____________________
ShapeGen 1.12 and Cadroe Lathe 1.32 now available through SLExchange.
|
Juro Kothari
Like a dog on a bone
Join date: 4 Sep 2003
Posts: 4,418
|
01-08-2005 11:04
Great stuff Cadroe! I'll be picking one up today.
|
Unhygienix Gullwing
I banged Pandastrong
Join date: 26 Jun 2004
Posts: 728
|
01-08-2005 11:47
I can't wait to play with this! Thanks, Cadroe!
Is it possible to also do similiar scripts for other oversized shapes, particularly curved ones? Spheres particularly would interest me.
Neat stuff!
|
Merwan Marker
Booring...
Join date: 28 Jan 2004
Posts: 4,706
|
01-08-2005 11:58
Excellent! Very 
_____________________
Don't Worry, Be Happy - Meher Baba
|
Cadroe Murphy
Assistant to Mr. Shatner
Join date: 31 Jul 2003
Posts: 689
|
01-08-2005 14:54
Thanks, I hope it's helpful  Unhygienix - yes, with enough prims you could model any of the primitives at any scale. Someone made something called XyObject which does this (basically by modeling polygons as prims, AFAIK), but I haven't seen it. I've seen a couple of different giant spheres around. I made RingMaker cause it seems like a specific task that comes up a lot (circular rooms and floors). It's certainly something I do a lot, cause I enjoy radial structures. I might work on some other tools. It does seem kind of dumb that RingMaker only does circles and not all ellipses. If no one else does it first, I might try to fix that.
_____________________
ShapeGen 1.12 and Cadroe Lathe 1.32 now available through SLExchange.
|
Ale Bukowski
Gnomes Landscapers Master
Join date: 2 Apr 2004
Posts: 129
|
01-08-2005 16:39
Very, very cool. Thank you Cadroe!
|
Olympia Rebus
Muse of Chaos
Join date: 22 Feb 2004
Posts: 1,831
|
01-08-2005 18:26
You rule, Cadroe! I'm looking forward to playing with this new toy 
|
Derek Tesla
Nerf herder
Join date: 12 Aug 2003
Posts: 19
|
01-08-2005 19:43
I'm having a problem where the RingBlock is set as no copy, so it'll create one ring block and delete it from the RingMakers inventory.
I bought 3 (meh, it was only 3 Lindens) and they all do the same thing to me. It comes as non-modifiable (even though the modify permission is set) and no copy.
|
Dallas Moreau
Registered User
Join date: 7 Dec 2004
Posts: 146
|
01-08-2005 23:04
Fantastic! Thanks!
|
Cadroe Murphy
Assistant to Mr. Shatner
Join date: 31 Jul 2003
Posts: 689
|
01-09-2005 05:07
From: Derek Tesla I'm having a problem where the RingBlock is set as no copy, so it'll create one ring block and delete it from the RingMakers inventory.
I bought 3 (meh, it was only 3 Lindens) and they all do the same thing to me. It comes as non-modifiable (even though the modify permission is set) and no copy. Sorry about that, Derek. I checked and the only thing that was (accidentally) no-copy was the script inside the RingBlock, so I changed that. I dropped the new version on your inventory. I hope it works. I apologize to anyone who came out to my property and got one only to have it not work for them. The thing does work, it's just the permissions. When I get a working version, I'll drop it on the inventory of anyone who's already gotten one. EDIT - OK, I went ahead and created my first alt to test it, which I should have done in the first place. It worked for the alt, so hopefully it will work for others.
_____________________
ShapeGen 1.12 and Cadroe Lathe 1.32 now available through SLExchange.
|
Cadroe Murphy
Assistant to Mr. Shatner
Join date: 31 Jul 2003
Posts: 689
|
01-09-2005 07:22
It's fixed. Thanks to Buck Weaver and others for being guinea pigs. I dropped the new version on everyone who got the old one.
_____________________
ShapeGen 1.12 and Cadroe Lathe 1.32 now available through SLExchange.
|
Milo Bukowski
Lag-induced oversteer
Join date: 23 Dec 2003
Posts: 305
|
01-10-2005 06:02
Thanks Cadroe for releasing this as free and open.
I tried it out and had some of the prims stop listening to me. Should I wait until all the settings are in before rezzing? For example, I'd say "/11 sides 18" then "/11 rez" then if I change the radius, maybe 3 or 4 of the prims (always the last ones to change) don't do anything, then they're stuck for any additional changes.
|
Cadroe Murphy
Assistant to Mr. Shatner
Join date: 31 Jul 2003
Posts: 689
|
01-10-2005 09:23
Milo - Yeah, I'd suggest letting one operation finish completely before sending the next command. I don't understand why a block would end up not listening altogether, as opposed to just missing a command, but it does seem to happen sometimes. Especially when there's a lot of lag. It practically never happens to me in Ohno when there's not a lot of lag, but it happened to me several times in Cordova when people were conducting physics experiments. I guess a guru in object communication might have an idea what the problem is. I'll look at the wiki for some clues.
It looks like one tricky aspect of ellipses might be getting the shear right. The wedges would not all be oriented toward a common center, so I think they'd have to be sheared to lie next to each other properly.
_____________________
ShapeGen 1.12 and Cadroe Lathe 1.32 now available through SLExchange.
|
Planet Mars
Registered User
Join date: 10 Feb 2004
Posts: 159
|
01-11-2005 10:31
Great work Cadroe, this is so much easier than doing this manually (which i *have* done in the past, Cerulean Shores Mall in LaLa land is almost 90m in diameter). I tried this out today, made a quick sky-platform thing out of 5 octagons using ring maker and stuck a base on it, messed with some alpha textures and came up with a spider web thing. Kinda interesting and would have been much more difficult and time-consuming manually. Here's a pic... obviously it could have been closer to round if I'd gone to more than 8 sides, but I was watching the prim count (for a change  )
_____________________
Planet Mars
|
Cadroe Murphy
Assistant to Mr. Shatner
Join date: 31 Jul 2003
Posts: 689
|
01-11-2005 12:40
Very cool, Planet Mars, I'm glad it's useful. 90 meters, yikes 
_____________________
ShapeGen 1.12 and Cadroe Lathe 1.32 now available through SLExchange.
|
Tiger Crossing
The Prim Maker
Join date: 18 Aug 2003
Posts: 1,560
|
01-11-2005 14:05
In the freeze function in the block prims, they could delete their own script from inventory to go TOTALY frozen. That was something I added to Xylor's original ring rezer, which can do elipses. He also made a sphere rezer and later made the XyObject system that can make all sorts of shapes. It basicly starts with a prim you've sculpted, then blows it up to whatever size you want. Works very well if you don't give it bad numbers... Which is very easy to do. It's also a big prim hog. 
_____________________
~ Tiger Crossing ~ (Nonsanity)
|
Cadroe Murphy
Assistant to Mr. Shatner
Join date: 31 Jul 2003
Posts: 689
|
01-11-2005 14:18
Thanks, Tiger, I didn't realize scripts could delete themselves. After a peek at the wiki, I see I can do it with llRemoveInventory(), so I'll definitely be changing that. But at the moment everything on my land and on land near me has become phantom to me  so there will be a slight delay  Xylor's stuff sounds pretty cool alright.
_____________________
ShapeGen 1.12 and Cadroe Lathe 1.32 now available through SLExchange.
|
Vicious Volos
Hi..I Don't Care, Thanks.
Join date: 11 Sep 2004
Posts: 264
|
01-11-2005 16:24
i cant find it in world
|
Cutter Rubio
Hopeless Romantic
Join date: 7 Feb 2004
Posts: 264
|
01-11-2005 17:03
OK, this thng is cool, but I'm stumped by one thing. Is there a command setting that allows it to make a solid disk? All I can seem to get out of it is a ring with a hole in the center, and the triangle points sticking out, regardless of the hollow settings I use.
Feel free to IM me in game if you wish, or reply here. Thanks!
_____________________
The early bird may get the worm, but the second mouse gets the cheese.
|
DoteDote Edison
Thinks Too Much
Join date: 6 Jun 2004
Posts: 790
|
01-11-2005 18:07
The hole may be a limit, but easily solveable. If it's less than 10-meters, fill it with a cylinder <= 10m. If it's larger than 10, fill it with a sub-ring that matches the radius of the hole.... then fill the hole in the sub-ring with a cylinder <= 10m.
|
Planet Mars
Registered User
Join date: 10 Feb 2004
Posts: 159
|
01-12-2005 09:29
From: Cutter Rubio OK, this thng is cool, but I'm stumped by one thing. Is there a command setting that allows it to make a solid disk? All I can seem to get out of it is a ring with a hole in the center, and the triangle points sticking out, regardless of the hollow settings I use.
Feel free to IM me in game if you wish, or reply here. Thanks! Each block obviously still is limited to 10m in any one direction, so if (for example) your ring had a radius of 25m, since the ring can extend 10m into this 25m, then the centre 15m MUST be hollow. This means that the 'hollow' value you set must be at least 0.6 (i.e. 15/25), if you set a value of less than this then ringmaker cannot extend the blocks far enough towards the centre, and results in the triangles issue you mention. To make a 25m radius circle you would do a 25m radius ring with hollow 0.6 (15/25), then a 15m radius ring with hollow 0.333 (5/15), then fill the final 5m radius space with a cylinder (diameter 10m) or another ring with radius 5 and hollow 0. Hope that makes sense, also I've written it from memory of my experiments yesterday, so apologies for any errors. Edited to add: since this is open source, presumably somebody could add the function to make a solid disk from multiple rings with one command. Although my scripting knowledge of 0 (in the SL Players Top Trumps set, scripting would probably be my lowest attribute, unless AV sex experience was on there...) means the 'somebody' will not be me 
_____________________
Planet Mars
|
Cadroe Murphy
Assistant to Mr. Shatner
Join date: 31 Jul 2003
Posts: 689
|
01-12-2005 09:44
Yes, that's it, Planet  I could have forced the hollow value for rings with radius > 10 but I thought people might want to use star centers too. Which gives me an idea, I should add a switch to flip the pieces, which would generate star shapes rather than rings. Not sure how much use that would get, but it's very easy to do. I was actually thinking of adding the option to have RingMaker fill in the centers of big rings with smaller concentric rings (as you described). I'll have to think about the interface though.
_____________________
ShapeGen 1.12 and Cadroe Lathe 1.32 now available through SLExchange.
|
Cadroe Murphy
Assistant to Mr. Shatner
Join date: 31 Jul 2003
Posts: 689
|
01-12-2005 14:08
OK, I changed it so the scripts are deleted from the blocks automatically when they're frozen in place. I also added a star mode which basically flips the blocks pointy side out. I attached a pic in case that's not clear. If you want a new version you can IM me and I'll drop it on you.
_____________________
ShapeGen 1.12 and Cadroe Lathe 1.32 now available through SLExchange.
|
Cutter Rubio
Hopeless Romantic
Join date: 7 Feb 2004
Posts: 264
|
01-12-2005 16:55
Thanks Planet for that nice clear explanation. I understand now - I need to force the hollow out to essentially mask the tips of the triangles. Piece of cake! And kudos to Cadroe for this awesome tool. I have Xylor's XYObject, and it is equally cool, though as one person noted, it eats prims for breakfast - fortunately the island allows 15,000 of them 
_____________________
The early bird may get the worm, but the second mouse gets the cheese.
|
Synergy Belvedere
Prim Reaper
Join date: 7 Jul 2004
Posts: 253
|
01-13-2005 09:15
Cadroe, I havent played with this tool long enough to know if what i'm about to ask is a dumb question or not (although from what i've seen this is very cool). I made a ring last night, with 12 sides and a radius of 20m. Hollow value was .01. I noticed it leaves alot of pointy ends in the center. The folks here talked about using another cylinder to fill that hole, or mask it, but does that not mean that you'll have all those points sharing the same space as the cylinder in the middle, thus causing those nasty flashing textures? If I'm off base I apologize, but was curious 
|