<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Object with Random Dimensions - Works only parameter zzy in Libraries &amp; objects</title>
    <link>https://community.graphisoft.com/t5/Libraries-objects/Object-with-Random-Dimensions-Works-only-parameter-zzyzx/m-p/120363#M24630</link>
    <description>yes, you need to force it to start from a random position within the number generator's sequence. Try multiplying it by SYMB_POS_X or SYMB_POS_Y, that will force it to generate a random number as they are always different for each object.</description>
    <pubDate>Mon, 20 Apr 2009 01:31:09 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2009-04-20T01:31:09Z</dc:date>
    <item>
      <title>Object with Random Dimensions - Works only parameter zzyzx</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/Object-with-Random-Dimensions-Works-only-parameter-zzyzx/m-p/120359#M24626</link>
      <description>&lt;DIV class="actalk-migrated-content"&gt;&lt;T&gt;I have created this object to have the possibility to create random dimensions for the same object. (ver. 11) &lt;BR /&gt;
 &lt;BR /&gt;
It's simple: &lt;BR /&gt;
you position the object on the plan, duplicate it n. times, then open the object and click on the "Create Random Dimensions", OK. The object would have to create random object dimensions, but not completely. &lt;BR /&gt;
 &lt;BR /&gt;
The problem is that it works very well only for ZZYZX Parameter, but it doesn't work for A and B. I don't Know why. &lt;BR /&gt;
Can somebody help me? &lt;BR /&gt;
Mario&lt;/T&gt;&lt;/DIV&gt;</description>
      <pubDate>Sun, 19 Apr 2009 09:10:41 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/Object-with-Random-Dimensions-Works-only-parameter-zzyzx/m-p/120359#M24626</guid>
      <dc:creator>Mario Sacco</dc:creator>
      <dc:date>2009-04-19T09:10:41Z</dc:date>
    </item>
    <item>
      <title>Re: Object with Random Dimensions - Works only parameter zzy</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/Object-with-Random-Dimensions-Works-only-parameter-zzyzx/m-p/120360#M24627</link>
      <description>Mario,&lt;BR /&gt;
&lt;BR /&gt;
I couldn't figure out why this wouldn't work properly by defining the A and B parameters the way you did. I did however make a couple of changes to the script and got it to work. Also if you turn on the "calrnd" parameter, save and close the script, each time you place a new instance of it, it will have a random size. Not sure what I'd ever use it for but it's still a neat object.&lt;BR /&gt;
&lt;BR /&gt;
Doug&lt;BR /&gt;
&lt;BR /&gt;
!!!!!MASTER SCRIPT&lt;BR /&gt;
&lt;BR /&gt;
arnd = RND(1)&lt;BR /&gt;
&lt;BR /&gt;
IF (GLOB_CONTEXT = 2 OR  GLOB_CONTEXT = 3  OR GLOB_CONTEXT  4) AND calrnd = 1 THEN&lt;BR /&gt;
	parameters a = arnd&lt;BR /&gt;
	parameters b = arnd&lt;BR /&gt;
	parameters zzyzx = arnd&lt;BR /&gt;
	PARAMETERS arnd = arnd&lt;BR /&gt;
ENDIF&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
!!!!!2D SCRIPT&lt;BR /&gt;
&lt;BR /&gt;
RECT2 0,0,arnd,arnd&lt;BR /&gt;
&lt;BR /&gt;
!!!!!3D SCRIPT&lt;BR /&gt;
&lt;BR /&gt;
BLOCK arnd, arnd, arnd</description>
      <pubDate>Sun, 19 Apr 2009 14:48:03 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/Object-with-Random-Dimensions-Works-only-parameter-zzyzx/m-p/120360#M24627</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2009-04-19T14:48:03Z</dc:date>
    </item>
    <item>
      <title>Re: Object with Random Dimensions - Works only parameter zzy</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/Object-with-Random-Dimensions-Works-only-parameter-zzyzx/m-p/120361#M24628</link>
      <description>&lt;BLOCKQUOTE&gt;4thorns wrote:&lt;BR /&gt;Mario,  &lt;BR /&gt;
  &lt;BR /&gt;
I couldn't figure out why this wo.................&lt;/BLOCKQUOTE&gt;  &lt;BR /&gt;
Thank you!  &lt;BR /&gt;
I have tried your script. The problem is similar. Randon objects were been 2d and 3d correctly created, but when I turn off "calrnd", in the parameter setting A and B aren't correct, only ZZYZX is correct. I have done many other tries without results.  &lt;BR /&gt;
I continue to try.  &lt;BR /&gt;
Thank you  &lt;BR /&gt;
Mario</description>
      <pubDate>Sun, 19 Apr 2009 16:02:55 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/Object-with-Random-Dimensions-Works-only-parameter-zzyzx/m-p/120361#M24628</guid>
      <dc:creator>Mario Sacco</dc:creator>
      <dc:date>2009-04-19T16:02:55Z</dc:date>
    </item>
    <item>
      <title>Re: Object with Random Dimensions - Works only parameter zzy</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/Object-with-Random-Dimensions-Works-only-parameter-zzyzx/m-p/120362#M24629</link>
      <description>The problem is in GS implementation of RND function. It is not true random generator but only picker of predefined values 13,36,53,86,48 etc. Try this&lt;BR /&gt;
!!! MASTER SCRIPT or PARAMETER SCRIPT&lt;BR /&gt;
&lt;BR /&gt;
IF calrnd = 1 AND (GLOB_CONTEXT = 1 OR GLOB_CONTEXT = 5) THEN&lt;BR /&gt;
	arnd = RND(1)&lt;BR /&gt;
	PARAMETERS arnd = arnd&lt;BR /&gt;
	PARAMETERS A = .1*arnd, B = .1*arnd, zzyzx = .1*arnd&lt;BR /&gt;
	PARAMETERS calrnd = 0	! optional&lt;BR /&gt;
ENDIF&lt;BR /&gt;
&lt;BR /&gt;
If you try it in Libary part editor it will show and behave normal until saving when start from begining of sequence. If you save it with start values of A,B,ZZYZX of 1000 and put it on plan it will only allowed first number of sequence because AC saves the object after every property change and therefore reset RND function.&lt;BR /&gt;
The only way is to think about your own true RND function.</description>
      <pubDate>Sun, 19 Apr 2009 23:10:49 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/Object-with-Random-Dimensions-Works-only-parameter-zzyzx/m-p/120362#M24629</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2009-04-19T23:10:49Z</dc:date>
    </item>
    <item>
      <title>Re: Object with Random Dimensions - Works only parameter zzy</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/Object-with-Random-Dimensions-Works-only-parameter-zzyzx/m-p/120363#M24630</link>
      <description>yes, you need to force it to start from a random position within the number generator's sequence. Try multiplying it by SYMB_POS_X or SYMB_POS_Y, that will force it to generate a random number as they are always different for each object.</description>
      <pubDate>Mon, 20 Apr 2009 01:31:09 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/Object-with-Random-Dimensions-Works-only-parameter-zzyzx/m-p/120363#M24630</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2009-04-20T01:31:09Z</dc:date>
    </item>
    <item>
      <title>Re: Object with Random Dimensions - Works only parameter zzy</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/Object-with-Random-Dimensions-Works-only-parameter-zzyzx/m-p/120364#M24631</link>
      <description>&lt;BLOCKQUOTE&gt;Dragan wrote:&lt;BR /&gt;The problem is in GS implementation of RND function. It is not true random generator but only picker of predefined values 13,36,53,86,48 etc. ....&lt;/BLOCKQUOTE&gt; &lt;BR /&gt;
 &lt;BR /&gt;
Now I understand many behaviors of the results of random. &lt;BR /&gt;
 
&lt;BLOCKQUOTE&gt;sdb wrote:&lt;BR /&gt;yes, you need to force it to start from a random position within the number generator's sequence. Try multiplying it by SYMB_POS_X or SYMB_POS_Y, that will force it to generate a random number as they are always different for each object.&lt;/BLOCKQUOTE&gt; &lt;BR /&gt;
 &lt;BR /&gt;
I started exactly with this method. I'll try again.&lt;BR /&gt;
Thank you very much! &lt;BR /&gt;
Mario</description>
      <pubDate>Mon, 20 Apr 2009 08:27:23 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/Object-with-Random-Dimensions-Works-only-parameter-zzyzx/m-p/120364#M24631</guid>
      <dc:creator>Mario Sacco</dc:creator>
      <dc:date>2009-04-20T08:27:23Z</dc:date>
    </item>
  </channel>
</rss>

