Ask a Question related to Macromedia Director 3D, Design and Development.
-
hondo3000 #1
using more then 126 chars for naming models...
Today i noticed that models in Shockwave3D can have a maximum number of 126
characters. I needed to know that because i have to store some Informations in
the names of the models when i export them (i have not option to use the
"userdate" when exporting the models).
But now something interesting happend when i tried to create long names in
director via lingo. If the names are longer then 126 charakters they are
limited to the first 126.
if you use for example this code to generate a new group:
member("world").newgroup("Lorem ipsum dolor sit amet, consectetuer adipiscing
elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliq")
this are 126 chars, you get a group with exact this name.
if you now add more charakters at the end it will produce another group with
the same name as the group above. You can check this in the Objectinspector.
use now this code:
member("world").newgroup("Lorem ipsum dolor sit amet, consectetuer adipiscing
elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliqLorem
ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh
euismod tincidunt ut laoreet dolore magna aliq")
It will produce a second Group with exact the same name. The good thing is,
that you can still reference to the model with that long name, the bad thing
is, you can't read the full name of the model anymore.
What does this mean in the end?
There is a visible name of the model that can be read by lingo, but there is
the "real" name of the model that can be used to reference to models. If the
names have more then 126 chars you can only see the shortend name but its still
nessesary to reference to the longer name.
if you try this in the message window (this are 127 chars, i added a "2" as
last character):
member("world").newgroup("Lorem ipsum dolor sit amet, consectetuer adipiscing
elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliq2")
put member("world").group("Lorem ipsum dolor sit amet, consectetuer adipiscing
elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna
aliq2").name
-- "Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy
nibh euismod tincidunt ut laoreet dolore magna aliq"
but
put member("world").group("Lorem ipsum dolor sit amet, consectetuer adipiscing
elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna
aliq").name
will give you an error!
Conclusion:
It's better not to use more then 126 characters for naming models.
But if you want to prevent your 3D models from being used by other people,
then you can use longer names and add for example a serialnumber to the models,
behind char 126. So you can generate shockwave apps that need to know the
correct name of the model.
if you give your models in your 3D app names like this:
"Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy
nibh euismod tincidunt ut laoreet dolore magna aliq_12345"
(132 chars)
the last part is in this example the serialnumber "_12345"
you can only reference to the models with
serialnum="_12345"
rightname=member("world").model[1].name & serialnum
put rightname.position
Maybe interesting to some people that want to make external w3D files
unconfortable to handle for other people, you still can reference to the models
by their numbers. I think it will only prevent models form the
"CloneModelFromCastmember" command, not much... in the end there is no real
protection when external *.w3d files are used...
regards!
hondo3000 Guest
-
receiving ??? chars instead of "special" chars
Hello i have a strange problem i made a online catalogue and must submit orders to a remote server I need to connect to a remote webservice on ... -
Naming container
I'm having a problem with a linkbutton which is not assigned a UniqueID with all the prefixes for some reason. The linkbutton resides in a... -
Var naming S.O.S
Hi, I am desperatly trying ton use concatenation in variables naming. Say i have : var nb = 5; I would like to use the value of nb in a... -
Naming Pages
All of my pages are named page 0001, 0002, 0003, etc. They aren't named, for example, my subscription form page is not: ... -
naming models / rotation / tweening
Hi, The 'Clone Model' behavior in the Chrome Lib gives each new model instance a unique name: the name of the source model plus an instance... -
a?ex #2
Re: using more then 126 chars for naming models...
<blockquote>quote:<br><hr><i>Originally posted by:
<b><b>hondo3000</b></b></i>you can only reference to the models with
serialnum="_12345"
rightname=member("world").model[1].name & serialnum<hr></blockquote>
you can still reference the nodes by index.
clone the nodes in a repeat loop and you're done.
a?ex Guest
-
hondo3000 #3
Re: using more then 126 chars for naming models...
I know that this is not more then a gesture. but if people try to use "3DPI"
for example and push the "CloneModelsFromCastmember" button it will not work.
CloneModelFromCastmember needs to know the model by name.
Using the "clone" comand like this:
member("world").model[1].clone("clone001")
will produce a errormessage and a model that is named like the original one.
But you are right, this is absolute useless at all. if you know a little lingo
its possible to copy models in different ways.... So sorry for posting this
here, it was just little bit late and i was not thinking long enough about
it...
cheers!
hondo3000 Guest
-
Agustín María Rodríguez #4
Re: using more then 126 chars for naming models...
hondo3000 wrote:
hehe Don´t worry! It´s good to post here things like these. I already> I know that this is not more then a gesture. but if people try to use "3DPI"
> for example and push the "CloneModelsFromCastmember" button it will not work.
> CloneModelFromCastmember needs to know the model by name.
>
> Using the "clone" comand like this:
> member("world").model[1].clone("clone001")
>
> will produce a errormessage and a model that is named like the original one.
>
> But you are right, this is absolute useless at all. if you know a little lingo
> its possible to copy models in different ways.... So sorry for posting this
> here, it was just little bit late and i was not thinking long enough about
> it...
faced the character limitation and couldn´t use userData either because
the modeler needed to use Maya. Can´t recall how did I solve it... I
think that using a database. Anyway, now we know that we won´t be able
of stealing your models with 3DPI ;)
Regards,
--
Agustín María Rodríguez
[url]www.onwine.com.ar[/url] > Macromedia Director demos & code
Agustín María Rodríguez Guest



Reply With Quote

